Customer Management
Onboarding & Pre-Verification
Consultants or admins onboard new clients via a structured two-step workflow designed to prevent duplicate client profiles:
- Step 1: Mandatory Identity & Duplicate Check — Before remaining customer fields unlock, staff enter the customer’s NIC Number, Passport Number, and Primary Phone Number.
- The system performs a backend duplicate lookup matching against existing customer records (checking NIC, primary phone, primary passport number, and dual citizenship passport number).
- If a duplicate match is found, an inline warning displays the existing customer’s name and matched identity field, providing a direct 1-click navigation link to open their existing Dossier rather than creating a duplicate profile.
- When verified, all three identity fields (NIC, Passport Number, and Primary Phone) are securely locked and disabled (
disabled={true}) to preserve verification integrity.
- Step 2: Profile Completion & Automatic Pre-Filling — Once verified, the customer’s remaining details (Full Name, Date of Birth, Email, Nationality, Secondary Phone, Residential Address, Staff Assignment, Notes, and Initial Document Slots) unlock.
- The verified Passport Number is automatically carried over, pre-filled, and shown disabled in the customer form and any subsequent Passport Details filling modals.
- On submission, the customer profile is created and their passport number is automatically saved.
- On creation, the customer receives an automated, branded welcome email introducing their assigned consultant.
Assignment & transfers
Admins assign customers to specific staff at creation, or transfer them later — a transfer triggers an automated notification email to the customer.
Client directory
A paginated, searchable directory is available from the sidebar to every role, with staff-assignment tracking — but the rows shown differ by role: admins/owners see every client in the system, while other staff see only clients assigned to them. The scoping happens on the backend, so it’s the same page and list view for everyone, just different data underneath.
Client dossier
A dedicated view per client showing all their cases, documents, and preferences. Consultants manage their own clients; admins are restricted from editing another staff member’s client (add-service / edit-profile actions are disabled for anyone but the assigned consultant or an admin acting within their own scope).
Lifetime spend & past journeys
The dossier’s stat tiles show real, aggregated numbers — total paid-invoice amount and completed visa/flight case count for the customer — computed live rather than mocked.
Preferences
Dietary, aviation, and accommodation preferences are tracked per client and surface throughout the booking workflow.
Documents & File Vault
Customers have a dedicated Documents & Files tab in the client dossier providing a structured, high-performance file repository:
- Human-Readable Cloudflare R2 Hierarchy — Files are organized deterministically by client name and UUID (e.g.
customers/{name}_{id}/visas/{visaId}/issued_visa/,customers/{name}_{id}/tickets/{flightId}/issued_ticket/,customers/{name}_{id}/passports/,customers/{name}_{id}/documents/{type}/). - Deterministic File Annotation — Documents are automatically assigned standardized filenames based on context (e.g.
2026-08-23_eVisa_business_3M_SE_3fa85f64.pdf,2026-08-23_Ticket_EK_PNR-ABC123_3fa85f64.pdf,2026-08-23_passport_N8912345_3fa85f64.pdf), with custom descriptions and staff override support. - Secure On-Demand Downloads — Downloads use pre-signed Cloudflare R2 URLs configured with forced
Content-Disposition: attachmentheaders and RFC 6266 URL encoding, ensuring files are saved to client devices with clean annotated names while blocking header injection. - Strict Magic-Byte Validation — The backend enforces byte-level signature detection for PDF (
%PDF-), PNG, and JPEG formats, preventing MIME spoofing and disguised executables. - Category Filtering & Search — Filter instantly by Passports, Visas, Tickets, Bank Statements, or Employment Letters, and search by filename or notes.
Customer deletion & recovery
Deleting a customer is a soft delete, not a hard delete — nothing is actually destroyed. It also cascades: every related record (invoices, receipts, visa requests, flight requests, tickets, quotes, documents) is soft-deleted along with the customer, and all of it is transparently hidden from normal views and searches from that point on.
There is currently no in-app restore for a deleted customer. Recovery is technically possible — the data is still in the database — but only a developer can do it, by clearing the deletion marker directly at the database level. If you delete a customer by mistake, treat it as recoverable-but-not-self-service: contact whoever manages the database rather than assuming an undo button exists somewhere.