mirror of
https://gitee.com/ulthon/ulthon_information.git
synced 2026-03-03 16:24:28 +08:00
28 lines
392 B
PHP
28 lines
392 B
PHP
<?php
|
|
|
|
namespace app\model;
|
|
|
|
use think\Model;
|
|
use think\model\concern\SoftDelete;
|
|
|
|
/**
|
|
* @mixin think\Model
|
|
*/
|
|
class User extends Model
|
|
{
|
|
//
|
|
|
|
use SoftDelete;
|
|
|
|
protected $defaultSoftDelete = 0;
|
|
|
|
public function getAvatarAttr($value)
|
|
{
|
|
if(empty($value)){
|
|
return '/static/images/avatar.jpeg';
|
|
}
|
|
|
|
return \get_source_link($value);
|
|
}
|
|
}
|