增加自动清除缓存特性;

This commit is contained in:
2022-02-12 17:02:45 +08:00
parent 90bbf61b6a
commit 7d8b948543
7 changed files with 260 additions and 154 deletions

View File

@@ -4,26 +4,33 @@ declare(strict_types=1);
namespace app\model;
use think\Model;
use app\common\model\Base;
/**
* @mixin think\Model
*/
class Nav extends Model
class Nav extends Base
{
public static $statusName = [
0=>'不显示',
1=>'显示'
];
//
public function getImgAttr($value)
{
return get_source_link($value);
}
public static $autoClearCache = [
[
'name' => 'type_3_list'
]
];
public function getStatusNameAttr()
{
return self::$statusName[$this->getData('status')];
}
public static $statusName = [
0 => '不显示',
1 => '显示'
];
//
public function getImgAttr($value)
{
return get_source_link($value);
}
public function getStatusNameAttr()
{
return self::$statusName[$this->getData('status')];
}
}