debug license

This commit is contained in:
2026-04-06 21:12:07 +03:30
parent af71fb441b
commit b8c5cb4c80
14 changed files with 299 additions and 366 deletions
@@ -1,5 +1,5 @@
import { LicenseStatus } from '@/generated/prisma/enums'
import { ApiProperty, OmitType, PartialType } from '@nestjs/swagger'
import { ApiProperty, PartialType } from '@nestjs/swagger'
import { IsDateString, IsEnum } from 'class-validator'
export class CreateLicenseDto {
@@ -21,16 +21,7 @@ export class CreateLicenseDto {
partner_id: string
}
export class UpdateLicenseDto extends OmitType(PartialType(CreateLicenseDto), [
'starts_at',
]) {
@ApiProperty({ required: true, default: new Date().toISOString() })
@IsDateString(
{ strict: true },
{ message: 'invoice_date must be a valid ISO-8601 string' },
)
starts_at: Date
export class UpdateLicenseDto extends PartialType(CreateLicenseDto) {
@ApiProperty({ enum: LicenseStatus })
@IsEnum(LicenseStatus)
status?: LicenseStatus