| 1234567891011121314151617181920212223242526272829303132333435363738394041 |
- <?php
- namespace app\common\dao\user;
- use app\common\dao\BaseDao;
- use app\common\model\user\UserSignJingdou;
- use app\entity\CommonEntity;
- use app\entity\data\user\UserSignJingdouEntity;
- class UserSignJingdouDao extends BaseDao
- {
- protected function getModel(): string
- {
- return UserSignJingdou::class;
- }
- /**
- * @param array $idList
- * @return CommonEntity[]
- */
- public function getStoreSignJingdouEntityListByIdList(array $idList): array
- {
- $entityList = [];
- try {
- /** @var UserSignJingdou $model */
- $model = $this->getModel();
- $dataRes = $model::getDB()
- ->whereIn('id', $idList)
- ->select()
- ->toArray();
- if (!empty($dataRes)) {
- $entityList = array_map(function ($data) {
- return UserSignJingdouEntity::newInstance($data);
- }, $dataRes);
- }
- } catch (\Exception $e) {
- }
- return $entityList;
- }
- }
|