Developers.php 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. <?php
  2. // +----------------------------------------------------------------------
  3. // | CatchAdmin [Just Like ~ ]
  4. // +----------------------------------------------------------------------
  5. // | Copyright (c) 2017~2020 http://catchadmin.com All rights reserved.
  6. // +----------------------------------------------------------------------
  7. // | Licensed ( https://github.com/yanwenwu/catch-admin/blob/master/LICENSE.txt )
  8. // +----------------------------------------------------------------------
  9. // | Author: JaguarJack [ njphper@gmail.com ]
  10. // +----------------------------------------------------------------------
  11. namespace catchAdmin\system\model;
  12. use catchAdmin\system\model\search\DeveloperSearch;
  13. use catcher\base\CatchModel as Model;
  14. class Developers extends Model
  15. {
  16. use DeveloperSearch;
  17. protected $name = 'developers';
  18. protected $field = [
  19. 'id', //
  20. 'username', // 用户名
  21. 'password', // 密码
  22. 'mobile', // 手机号
  23. 'id_card', // 身份证
  24. 'alipay_account', // 支付宝账户
  25. 'status', // 1 待认证 1 已认证
  26. 'created_at', // 创建时间
  27. 'updated_at', // 更新时间
  28. 'deleted_at', // 软删除
  29. ];
  30. public function setPasswordAttr($value)
  31. {
  32. return password_hash($value, PASSWORD_DEFAULT);
  33. }
  34. }