mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-08-30 11:08:12 +00:00
71 lines
1.4 KiB
TypeScript
71 lines
1.4 KiB
TypeScript
import { ApiProperty, ApiPropertyOptional } from '@nestjs/swagger';
|
|
|
|
export class ContractSignatureDto {
|
|
@ApiProperty({ enum: ['CUSTOMER', 'STAFF'] })
|
|
role!: string;
|
|
|
|
@ApiProperty()
|
|
signerDisplayName!: string;
|
|
|
|
@ApiProperty()
|
|
signedAt!: string;
|
|
|
|
@ApiPropertyOptional()
|
|
signatureImageUrl?: string | null;
|
|
|
|
@ApiPropertyOptional({
|
|
description:
|
|
'Company seal beside the signature. Set for the EDR (STAFF) side from the single global company stamp; null for the client side.',
|
|
})
|
|
stampImageUrl?: string | null;
|
|
}
|
|
|
|
export class SavedSignatureViewDto {
|
|
@ApiProperty()
|
|
signerDisplayName!: string;
|
|
|
|
@ApiPropertyOptional()
|
|
signatureImageUrl?: string | null;
|
|
|
|
@ApiPropertyOptional()
|
|
stampImageUrl?: string | null;
|
|
}
|
|
|
|
export class ContractViewDto {
|
|
@ApiProperty()
|
|
bookingId!: string;
|
|
|
|
@ApiProperty()
|
|
reference!: string;
|
|
|
|
@ApiProperty()
|
|
status!: string;
|
|
|
|
@ApiProperty()
|
|
templateKey!: string;
|
|
|
|
@ApiProperty()
|
|
title!: string;
|
|
|
|
@ApiProperty({ description: 'Full HTML document for in-browser display' })
|
|
html!: string;
|
|
|
|
@ApiProperty()
|
|
canSignCustomer!: boolean;
|
|
|
|
@ApiProperty()
|
|
canSignStaff!: boolean;
|
|
|
|
@ApiProperty()
|
|
hasContractDocument!: boolean;
|
|
|
|
@ApiProperty({ type: [ContractSignatureDto] })
|
|
signatures!: ContractSignatureDto[];
|
|
|
|
@ApiPropertyOptional({ type: SavedSignatureViewDto })
|
|
savedSignature?: SavedSignatureViewDto;
|
|
|
|
@ApiPropertyOptional()
|
|
pricingSchedule?: Record<string, unknown>;
|
|
}
|