mirror of
https://github.com/immich-app/immich.git
synced 2025-12-06 09:13:13 +03:00
26 lines
634 B
TypeScript
26 lines
634 B
TypeScript
import { ApiProperty } from '@nestjs/swagger';
|
|
import { Transform } from 'class-transformer';
|
|
import { IsBoolean } from 'class-validator';
|
|
import { Optional, ValidateUUID, toBoolean } from '../../domain.util';
|
|
|
|
export class GetAlbumsDto {
|
|
@Optional()
|
|
@IsBoolean()
|
|
@Transform(toBoolean)
|
|
@ApiProperty()
|
|
/**
|
|
* true: only shared albums
|
|
* false: only non-shared own albums
|
|
* undefined: shared and owned albums
|
|
*/
|
|
shared?: boolean;
|
|
|
|
/**
|
|
* Only returns albums that contain the asset
|
|
* Ignores the shared parameter
|
|
* undefined: get all albums
|
|
*/
|
|
@ValidateUUID({ optional: true })
|
|
assetId?: string;
|
|
}
|