67 lines
1.3 KiB
TypeScript

import { ApiProperty } from '@nestjs/swagger';
import { IncomeItem, IncomeList } from '@prisma/client';
export class IncomeListItemDto {
@ApiProperty({
description: 'ID',
type: String,
})
id: IncomeItem['id'];
@ApiProperty({
description: 'ID списка',
type: String,
})
incomeListId: IncomeList['id'];
@ApiProperty({
description: 'Заголовок дохода',
example: 'Кофе',
type: String,
})
title: IncomeItem['title'];
@ApiProperty({
description: 'Описание',
example: 'Перед работой',
type: String,
nullable: true,
})
description: IncomeItem['description'];
@ApiProperty({
description: 'Дата',
example: '2025-08-22T04:12:03.726Z',
type: Date,
})
date: IncomeItem['date'];
@ApiProperty({
description: 'Сумма дохода',
example: 175.50,
type: Number,
})
amount: IncomeItem['amount'];
@ApiProperty({
description: 'Валюта дохода',
example: 'RUB',
type: String,
default: 'RUB',
nullable: true,
})
currency: IncomeItem['currency'];
@ApiProperty({
description: 'Дата создания',
type: Date,
})
createdAt: Date;
@ApiProperty({
description: 'Дата обновления',
type: Date,
})
updatedAt: Date;
}