['name'], '=' => ['status', 'type_id', 'type_value'] ]; } /** * @notes 获取列表 * @return array * @throws \think\db\exception\DataNotFoundException * @throws \think\db\exception\DbException * @throws \think\db\exception\ModelNotFoundException * @author 段誉 * @date 2022/6/20 16:35 */ public function lists(): array { return DictData::where($this->searchWhere) ->append(['status_desc']) ->limit($this->limitOffset, $this->limitLength) ->order(['sort' => 'desc', 'id' => 'desc']) ->select() ->toArray(); } /** * @notes 获取数量 * @return int * @author 段誉 * @date 2022/6/20 16:35 */ public function count(): int { return DictData::where($this->searchWhere)->count(); } }