refactor: 修改系统页面链接接口

This commit is contained in:
2025-03-15 15:33:28 +08:00
parent 5430c61759
commit 09c9fd725b
2 changed files with 7 additions and 0 deletions

View File

@@ -213,6 +213,7 @@ class System
]) ])
->language($lang_id) ->language($lang_id)
->category($category_id) ->category($category_id)
->enabled()
->isShow(true) ->isShow(true)
->select(); ->select();

View File

@@ -72,6 +72,12 @@ class ProductModel extends ProductBaseModel
$query->where('category_id', '=', $value); $query->where('category_id', '=', $value);
} }
// 启用状态查询
public function scopeEnabled($query)
{
$query->where('status', '=', 1);
}
// 上架状态查询 // 上架状态查询
public function scopeIsShowNullable($query, bool|null $value) public function scopeIsShowNullable($query, bool|null $value)
{ {