hedgedoc/backend/src/notes/alias.dto.ts
Erik Michelson c4a66ba671
do some backend stuff that needs to be touched later again!!
Signed-off-by: Erik Michelson <github@erik.michelson.eu>
2025-03-05 20:34:10 +01:00

32 lines
639 B
TypeScript

/*
* SPDX-FileCopyrightText: 2022 The HedgeDoc developers (see AUTHORS file)
*
* SPDX-License-Identifier: AGPL-3.0-only
*/
import { ApiProperty } from '@nestjs/swagger';
import { IsBoolean, IsString } from 'class-validator';
import { BaseDto } from '../utils/base.dto';
export class AliasDto extends BaseDto {
/**
* The name of the alias
*/
@IsString()
@ApiProperty()
name: string;
/**
* Is the alias the primary alias or not
*/
@IsBoolean()
@ApiProperty()
primaryAlias: boolean;
/**
* The public id of the note the alias is associated with
*/
@IsString()
@ApiProperty()
noteId: string;
}