mirror of
https://github.com/xiaoyiweb/YiAi.git
synced 2025-11-16 06:03:43 +08:00
初始化
This commit is contained in:
16
service/src/modules/auth/dto/updatePassword.dto.ts
Normal file
16
service/src/modules/auth/dto/updatePassword.dto.ts
Normal file
@@ -0,0 +1,16 @@
|
||||
import { IsNotEmpty, MinLength, MaxLength } from 'class-validator';
|
||||
import { ApiProperty } from '@nestjs/swagger';
|
||||
|
||||
export class UpdatePasswordDto {
|
||||
@ApiProperty({ example: '123456', description: '用户旧密码' })
|
||||
@IsNotEmpty({ message: '用户密码不能为空!' })
|
||||
@MinLength(6, { message: '用户密码最低需要大于6位数!' })
|
||||
@MaxLength(30, { message: '用户密码最长不能超过30位数!' })
|
||||
oldPassword: string;
|
||||
|
||||
@ApiProperty({ example: '666666', description: '用户更新新密码' })
|
||||
@IsNotEmpty({ message: '用户密码不能为空!' })
|
||||
@MinLength(6, { message: '用户密码最低需要大于6位数!' })
|
||||
@MaxLength(30, { message: '用户密码最长不能超过30位数!' })
|
||||
password: string;
|
||||
}
|
||||
Reference in New Issue
Block a user