<?php
/**
 *
 *User:Administrator
 *Date:2021/10/22
 */

namespace app\api\validate;

use think\Validate;

class UserValidate extends Validate
{

    protected $rule = [
        'username' => 'require',
        'password' => 'require',

    ];

    protected $message = [
        'username.require' =>  ['0' => 10001, '1' => '名称必须'],
        'password.require' => ['0' => 10002, '1' => '密码必须'],
    ];

    protected $scene =[
        'login' => ['username','password'],

    ];
}