|
@@ -20,6 +20,9 @@ class Hospital extends Validate {
|
|
|
'province' => 'require',
|
|
|
'city' => 'require',
|
|
|
'address' => 'require',
|
|
|
+ 'bankCard' => 'require',
|
|
|
+ 'bank' => 'require|regex:/^[\x{4e00}-\x{9fa5}\(\)()\da-zA-Z&]{2,50}$/u',
|
|
|
+ 'bankNetwork' => 'require|regex:/^[\x{4e00}-\x{9fa5}\(\)()\da-zA-Z&]{2,50}$/u',
|
|
|
'agentName' => 'require|regex:/^[\x{4e00}-\x{9fa5}]+$/u|max:30',
|
|
|
'agentPhone' => 'require|mobile',
|
|
|
'verificationCode' => 'require',
|
|
@@ -44,6 +47,11 @@ class Hospital extends Validate {
|
|
|
'province.require' => '请选择医院所在省份',
|
|
|
'city.require' => '请选择医院所在市',
|
|
|
'address.require' => '请输入医院地址',
|
|
|
+ 'bankCard.require' => '请输入银行账号',
|
|
|
+ 'bank.require' => '请输入开户银行',
|
|
|
+ 'bankNetwork.require' => '请输入开户银行网点',
|
|
|
+ 'bank.regex' => '开户银行不正确,请检查',
|
|
|
+ 'bankNetwork.regex' => '开户银行网点不正确,请检查',
|
|
|
'agentName.require' => '请填写人才联络员',
|
|
|
'agentName.max' => '人才联络员最多30个字符',
|
|
|
'agentName.regex' => '人才联络员姓名只能是中文',
|
|
@@ -54,8 +62,8 @@ class Hospital extends Validate {
|
|
|
'agentEmail.email' => '邮箱格式错误'
|
|
|
];
|
|
|
protected $scene = [
|
|
|
- 'add' => ['username', 'password', 're_password', 'name', 'idCard', 'legal', 'ephone', 'medicalCommunityId', 'isGeneral', 'province', 'city', 'address', 'agentName', 'agentPhone', 'verificationCode', 'agentEmail'],
|
|
|
- 'change' => ['name', 'idCard', 'legal', 'ephone', 'medicalCommunityId', 'isGeneral', 'province', 'city', 'address', 'agentName', 'agentPhone', 'agentEmail'],
|
|
|
+ 'add' => ['username', 'password', 're_password', 'name', 'idCard', 'legal', 'ephone', 'medicalCommunityId', 'isGeneral', 'province', 'city', 'address', 'bankCard', 'bank', 'bankNetwork', 'agentName', 'agentPhone', 'verificationCode', 'agentEmail'],
|
|
|
+ 'change' => ['name', 'idCard', 'legal', 'ephone', 'medicalCommunityId', 'isGeneral', 'province', 'city', 'address', 'bankCard', 'bank', 'bankNetwork', 'agentName', 'agentPhone', 'agentEmail'],
|
|
|
'changePwd' => ['password']
|
|
|
];
|
|
|
|