TalentAppointmentModel.php 988 B

123456789101112131415161718192021222324252627
  1. <?php
  2. // +----------------------------------------------------------------------
  3. // | ThinkCMF [ WE CAN DO IT MORE SIMPLE ]
  4. // +----------------------------------------------------------------------
  5. // | Copyright (c) 2013-2019 http://www.thinkcmf.com All rights reserved.
  6. // +----------------------------------------------------------------------
  7. // | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
  8. // +----------------------------------------------------------------------
  9. // | Author:kane < chengjin005@163.com>
  10. // +----------------------------------------------------------------------
  11. namespace app\talent\model;
  12. use think\Model;
  13. class TalentAppointmentModel extends Model
  14. {
  15. public function getStatusTextAttr($value, $data)
  16. {
  17. $status = [1=>'待确认',2=>'待接站',3=>'待评价',4=>'已完成'];
  18. return $status[$data['status']];
  19. }
  20. public function talent()
  21. {
  22. return $this->hasOne(TalentModel::class,'id','talent_id');
  23. }
  24. }