Memberconnect.php 1016 B

12345678910111213141516171819202122232425262728293031323334
  1. <?php
  2. namespace app\common\validate;
  3. use think\Validate;
  4. /**
  5. *
  6. *
  7. * ----------------------------------------------------------------------------
  8. *
  9. * 验证器
  10. */
  11. class Memberconnect extends Validate
  12. {
  13. protected $rule = [
  14. 'new_password' => 'require|length:6,20',
  15. 'confirm_password' => 'require|confirm:new_password',
  16. ];
  17. protected $message = [
  18. 'new_password.require' => '新密码为必填|密码长度必须为6-20之间',
  19. 'new_password.length' => '新密码为必填|密码长度必须为6-20之间',
  20. 'confirm_password.require' => '新密码与确认密码不相同,请从重新输入',
  21. 'confirm_password.confirm' => '新密码与确认密码不相同,请从重新输入',
  22. ];
  23. protected $scene = [
  24. 'qqunbind' => ['new_password', 'confirm_password'],
  25. 'sinaunbind' => ['new_password', 'confirm_password'],
  26. 'weixinunbind' => ['new_password', 'confirm_password'],
  27. ];
  28. }