import { Rule, RuleType } from '@midwayjs/validate';
import { ApiProperty } from '@midwayjs/swagger';
/**
 * 登录参数校验
 */
export class LoginDTO {
  // 用户名
  @Rule(RuleType.string().required())
  @ApiProperty({ example: 'admin', description: 'The name of the username' })
  username: string;

  // 密码
  @Rule(RuleType.string().required())
  @ApiProperty({ example: '123456', description: 'The name of the password' })
  password: string;
}
