123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960 |
- <?php
- namespace app\dao\article;
- use app\dao\BaseDao;
- use app\model\article\ArticleCategory;
- class ArticleCategoryDao extends BaseDao
- {
-
- protected function setModel(): string
- {
- return ArticleCategory::class;
- }
-
- public function getList(array $where, int $page, int $limit)
- {
- return $this->search($where)->page($page, $limit)->order('sort desc,id desc')->select()->toArray();
- }
-
- public function getArticleCategory()
- {
- return $this->search(['hidden'=>0,'is_del'=>0,'status'=>1])
- ->order('sort DESC')
- ->field('id,title')
- ->select()->toArray();
- }
- }
|