chore(server): move dtos (#8131)

move dtos
This commit is contained in:
Daniel Dietzler
2024-03-20 23:53:07 +01:00
committed by GitHub
parent 0c13c63bb6
commit 6d9e7694b1
145 changed files with 917 additions and 964 deletions
+32
View File
@@ -0,0 +1,32 @@
import { ApiProperty } from '@nestjs/swagger';
import { IsInt, IsPositive } from 'class-validator';
import { Optional, ValidateUUID } from 'src/validation';
export class DownloadInfoDto {
@ValidateUUID({ each: true, optional: true })
assetIds?: string[];
@ValidateUUID({ optional: true })
albumId?: string;
@ValidateUUID({ optional: true })
userId?: string;
@IsInt()
@IsPositive()
@Optional()
@ApiProperty({ type: 'integer' })
archiveSize?: number;
}
export class DownloadResponseDto {
@ApiProperty({ type: 'integer' })
totalSize!: number;
archives!: DownloadArchiveInfo[];
}
export class DownloadArchiveInfo {
@ApiProperty({ type: 'integer' })
size!: number;
assetIds!: string[];
}