House.php 882 B

12345678910111213141516171819202122232425262728293031
  1. <?php
  2. namespace app\common\validate;
  3. use think\Validate;
  4. use think\Db;
  5. class House extends Validate{
  6. protected $rule = [
  7. 'floor_id' => 'require|gt:0',
  8. 'cate_id' => 'require|gt:0',
  9. 'company_id' => 'require|gt:0',
  10. 'right_id' => 'require|gt:0',
  11. 'level_id|承租方式' => 'require',
  12. ];
  13. protected $scene = [
  14. 'floor_id.require' => '未选择楼层',
  15. 'floor_id.gt' => '未选择楼层',
  16. 'cate_id.require' => '未选择类别',
  17. 'cate_id.gt' => '未选择类别',
  18. 'company_id.require' => '未选择物业管理单位',
  19. 'company_id.gt' => '未选择物业管理单位',
  20. 'right_id.require' => '未选择产权',
  21. 'right_id.gt' => '未选择产权',
  22. 'level_id.require' => '未选择承租方式',
  23. 'level_id.gt' => '未选择承租方式',
  24. ];
  25. }