diff --git a/src/components/dashboard/CompanyApplicationsPage.tsx b/src/components/dashboard/CompanyApplicationsPage.tsx index 8a10678..478525e 100644 --- a/src/components/dashboard/CompanyApplicationsPage.tsx +++ b/src/components/dashboard/CompanyApplicationsPage.tsx @@ -25,6 +25,7 @@ interface ApplicationItem { cover_note?: string | null; resume_url?: string | null; applied_at?: string; + reference_number: string; // Profile snapshot — contact fields excluded by backend applicant_name?: string | null; avatar_url?: string | null; @@ -304,7 +305,7 @@ export default function CompanyApplicationsPage() {
- {app.applicant_name || `Applicant #${app.id.slice(0, 8)}`} + {app.applicant_name || app.reference_number}
{app.headline}
diff --git a/src/components/dashboard/CompanyShortlistedCandidatesPage.tsx b/src/components/dashboard/CompanyShortlistedCandidatesPage.tsx index 92e78c1..e8f978f 100644 --- a/src/components/dashboard/CompanyShortlistedCandidatesPage.tsx +++ b/src/components/dashboard/CompanyShortlistedCandidatesPage.tsx @@ -93,6 +93,10 @@ export default function CompanyShortlistedCandidatesPage() {Candidate #{row.job_seeker_id?.slice(0, 8) || row.id.slice(0, 8)}
diff --git a/src/components/dashboard/JobSeekerApplicationsPage.tsx b/src/components/dashboard/JobSeekerApplicationsPage.tsx index 09a4d3a..7dfc43c 100644 --- a/src/components/dashboard/JobSeekerApplicationsPage.tsx +++ b/src/components/dashboard/JobSeekerApplicationsPage.tsx @@ -10,6 +10,7 @@ type ApplicationItem = { applied_at?: string; resume_url?: string | null; cover_letter?: string | null; + reference_number: string; }; async function apiFetch(path: string, opts?: RequestInit) { @@ -138,7 +139,7 @@ export default function JobSeekerApplicationsPage() {Application #{row.id.slice(0, 8)}
+{row.reference_number}
Job: {row.job_id?.slice(0, 8) || '—'} {row.applied_at ? `• ${new Date(row.applied_at).toLocaleString('en-IN')}` : ''}
diff --git a/src/components/dashboard/ProfessionalResponsesPage.tsx b/src/components/dashboard/ProfessionalResponsesPage.tsx index 450a148..9149a44 100644 --- a/src/components/dashboard/ProfessionalResponsesPage.tsx +++ b/src/components/dashboard/ProfessionalResponsesPage.tsx @@ -13,6 +13,7 @@ type LeadRequestItem = { requested_at?: string; expires_at?: string; decision_at?: string; + reference_number: string; }; async function apiFetch(path: string, opts?: RequestInit) { @@ -91,7 +92,7 @@ export default function ProfessionalResponsesPage(props: Props) {Lead Request #{row.id.slice(0, 8)}
+{row.reference_number}
Requirement: {row.requirement_id?.slice(0, 8) || '—'} {row.requested_at ? `• ${new Date(row.requested_at).toLocaleString('en-IN')}` : ''}
diff --git a/src/components/dashboard/VerificationStatusPage.tsx b/src/components/dashboard/VerificationStatusPage.tsx index 721fc69..c739c47 100644 --- a/src/components/dashboard/VerificationStatusPage.tsx +++ b/src/components/dashboard/VerificationStatusPage.tsx @@ -128,9 +128,37 @@ interface Props { onVerificationStatusChange?: (status: string) => void; } +interface VerificationDocument { + type: string; + value: any; + status: string; +} + +interface VerificationStatusResponse { + status: string; + reference_number: string; + document_request?: string | null; + rejection_reason?: string | null; + updated_at?: string | null; + activity_log?: Array<{ date: string; action: string; details: string }>; + documents: VerificationDocument[]; +} + +// Best-effort extraction of a viewable URL from a document's `value` payload, +// which may be a raw URL string or an upload-response object. +function docUrl(value: any): string | null { + if (!value) return null; + if (typeof value === 'string') return value; + if (typeof value === 'object') { + return value.url ?? value.file_url ?? value.fileUrl ?? value.path ?? null; + } + return null; +} + export default function VerificationStatusPage(props: Props) { const [activeTab, setActiveTab] = createSignalTrack verification progress, documents, and updates.
++ {referenceNumber()} +
+{doc.label}
-- {status() === 'APPROVED' ? '✓ Verified' : status() === 'REJECTED' ? '✕ Rejected' : '◌ Pending review'} -
-{fieldLabel()}
++ {doc.status === 'APPROVED' ? '✓ Verified' : doc.status === 'REJECTED' ? '✕ Rejected' : doc.status === 'SUBMITTED' ? '◌ Submitted' : '◌ Pending review'} +
+