260326:1726 Fixing Refactor ADR-019 Naming convention uuid #06
This commit is contained in:
@@ -17,7 +17,7 @@ import { useProjects, useCorrespondenceTypes, useContracts, useDisciplines } fro
|
||||
|
||||
interface ProjectItem {
|
||||
id: number | string;
|
||||
uuid?: string;
|
||||
publicId?: string; // ADR-019: exposed as 'id' in API responses
|
||||
projectName: string;
|
||||
projectCode: string;
|
||||
}
|
||||
@@ -54,7 +54,7 @@ export default function NumberingPage() {
|
||||
// Master Data
|
||||
const { data: correspondenceTypes = [] } = useCorrespondenceTypes();
|
||||
const { data: contracts = [] } = useContracts(selectedProjectId);
|
||||
const firstContract = contracts[0] as { id?: number; uuid?: string } | undefined;
|
||||
const firstContract = contracts[0] as { id?: number; publicId?: string } | undefined;
|
||||
const contractId = firstContract?.publicId ?? firstContract?.id;
|
||||
const { data: disciplines = [] } = useDisciplines(contractId);
|
||||
|
||||
|
||||
@@ -143,7 +143,7 @@ export default function CirculationDetailPage() {
|
||||
<div>
|
||||
<p className="text-sm text-muted-foreground">Linked Document</p>
|
||||
<Link
|
||||
href={`/correspondences/${circulation.correspondence.uuid}`}
|
||||
href={`/correspondences/${circulation.correspondence.publicId}`}
|
||||
className="font-medium text-primary hover:underline"
|
||||
>
|
||||
{circulation.correspondence.correspondenceNumber}
|
||||
|
||||
@@ -23,7 +23,7 @@ type DrawingType = 'CONTRACT' | 'SHOP' | 'AS_BUILT';
|
||||
|
||||
interface FetchedDrawing {
|
||||
_type: DrawingType;
|
||||
uuid: string;
|
||||
publicId: string;
|
||||
contractDrawingNo?: string;
|
||||
drawingNumber?: string;
|
||||
title?: string;
|
||||
@@ -33,7 +33,7 @@ interface FetchedDrawing {
|
||||
currentRevision?: { title?: string; revisionNumber?: string; legacyDrawingNumber?: string };
|
||||
revisions?: {
|
||||
revisionId?: number;
|
||||
uuid: string;
|
||||
publicId: string;
|
||||
revisionNumber: string;
|
||||
title?: string;
|
||||
legacyDrawingNumber?: string;
|
||||
@@ -109,7 +109,7 @@ export default function DrawingDetailPage({ params }: { params: Promise<{ uuid:
|
||||
<h1 className="text-2xl font-bold">Drawing Not Found</h1>
|
||||
</div>
|
||||
<p className="text-muted-foreground">
|
||||
The drawing with UUID <code>{uuid}</code> could not be found.
|
||||
The drawing with ID <code>{uuid}</code> could not be found.
|
||||
</p>
|
||||
</div>
|
||||
);
|
||||
|
||||
@@ -101,7 +101,7 @@ export default function TransmittalDetailPage() {
|
||||
<p className="text-sm text-muted-foreground">Generated From</p>
|
||||
{transmittal.correspondence ? (
|
||||
<Link
|
||||
href={`/correspondences/${transmittal.correspondence.uuid}`}
|
||||
href={`/correspondences/${transmittal.correspondence.publicId}`}
|
||||
className="font-medium text-primary hover:underline"
|
||||
>
|
||||
{transmittal.correspondence.correspondenceNumber}
|
||||
|
||||
Reference in New Issue
Block a user