'create_time', 'id' => 'id']; } /** * @notes 设置默认排序 * @return array * @author heshihu * @date 2022/2/9 15:08 */ public function setDefaultOrder(): array { return ['sort' => 'desc','id' => 'desc']; } /** * @notes 获取管理列表 * @return array * @author heshihu * @date 2022/2/21 17:11 */ public function lists(): array { $ArticleCateLists = ArticleCate::where($this->searchWhere) ->append(['is_show_desc']) ->limit($this->limitOffset, $this->limitLength) ->order($this->sortOrder) ->append(['article_count']) ->select() ->toArray(); return $ArticleCateLists; } /** * @notes 获取数量 * @return int * @author heshihu * @date 2022/2/9 15:12 */ public function count(): int { return ArticleCate::where($this->searchWhere)->count(); } public function extend() { return []; } }