feat: 后台管理 产品列表添加按添加时间倒序

This commit is contained in:
2025-07-16 18:12:05 +08:00
parent 877c8835d9
commit 7651b056b6

View File

@@ -57,7 +57,7 @@ class Product
]) ])
->categoryNullable($param['category_id']??null) ->categoryNullable($param['category_id']??null)
->isShowNullable(isset($param['is_show']) ? (bool)$param['is_show'] : null) ->isShowNullable(isset($param['is_show']) ? (bool)$param['is_show'] : null)
->order(['sort' => 'asc', 'id' => 'desc']) ->order(['sort' => 'asc', 'created_at' => 'desc', 'id' => 'desc'])
->paginate([ ->paginate([
'list_rows' => $param['size'], 'list_rows' => $param['size'],
'page' => $param['page'], 'page' => $param['page'],