mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2024-11-26 19:53:59 -05:00
18 lines
391 B
TypeScript
18 lines
391 B
TypeScript
|
import { IsArray, IsBoolean, ValidateNested } from 'class-validator';
|
||
|
import { UserInfoDto } from '../users/user-info.dto';
|
||
|
|
||
|
export class NotePermissionEntryDto {
|
||
|
@ValidateNested()
|
||
|
user: UserInfoDto;
|
||
|
@IsBoolean()
|
||
|
canEdit: boolean;
|
||
|
}
|
||
|
|
||
|
export class NotePermissionsDto {
|
||
|
@ValidateNested()
|
||
|
owner: UserInfoDto;
|
||
|
@ValidateNested()
|
||
|
@IsArray()
|
||
|
sharedTo: NotePermissionEntryDto[];
|
||
|
}
|