返回 AiToEarn
userConfig.dto.ts
根目录 / project / aitoearn-electron / server / src / user / dto / userConfig.dto.ts
1 /*
2 * @Author: nevin
3 * @Date: 2024-06-17 20:12:31
4 * @LastEditTime: 2025-05-06 15:49:03
5 * @LastEditors: nevin
6 * @Description: 用户
7 */
8 import { ApiProperty } from '@nestjs/swagger';
9 import { Expose, Type } from 'class-transformer';
10 import { IsNumber, IsEnum } from 'class-validator';
11 import { EarnInfoStatus } from 'src/db/schema/user.schema';
12
13 export class SetUserEarnDto {
14 @ApiProperty({ required: true })
15 @IsEnum(EarnInfoStatus, { message: '状态' })
16 @Type(() => Number)
17 @Expose()
18 readonly status: EarnInfoStatus;
19
20 @ApiProperty({ title: '循环时间', required: true })
21 @IsNumber({}, { message: '循环时间' })
22 @Type(() => Number)
23 @Expose()
24 readonly cycleInterval: number;
25 }
26
26 lines TYPESCRIPT