|
|
@@ -18,6 +18,7 @@ use app\common\dao\user\AwardIntegralPriceDao;
|
|
|
use app\common\dao\user\AwardLakeDao;
|
|
|
use app\common\model\store\order\StoreOrder;
|
|
|
use app\common\model\user\AwardIntegralPrice;
|
|
|
+use app\common\model\user\AwardLakeLog;
|
|
|
use app\common\model\user\UserExtract;
|
|
|
use app\common\repositories\BaseRepository;
|
|
|
|
|
|
@@ -139,6 +140,30 @@ class AwardIntegralPriceRepository extends BaseRepository
|
|
|
// 统计满足条件的数据总数
|
|
|
$count = $query->count();
|
|
|
|
|
|
+ // 查询满足条件的数据列表,带有 'label' 关联数据,按 'label_rule_id' 倒序排列
|
|
|
+ // 分页查询,返回当前页码的 $limit 条数据,并将结果转换为数组形式
|
|
|
+ $list = $query->page($page, $limit)->select()->toArray();
|
|
|
+ // 返回包含数据总数和数据列表的数组
|
|
|
+ return compact('count', 'list');
|
|
|
+ }
|
|
|
+ /**
|
|
|
+ * 根据条件获取列表数据
|
|
|
+ *
|
|
|
+ * 每日奖池列表
|
|
|
+ * @param array $where 查询条件数组,用于指定数据库查询的条件。
|
|
|
+ * @param int $page 当前页码,用于指定要返回的页码。
|
|
|
+ * @param int $limit 每页的数据数量,用于指定每页返回的数据条数。
|
|
|
+ * @return array 返回包含 'count' 和 'list' 两个元素的数组,'count' 为数据总数,'list' 为数据列表。
|
|
|
+ */
|
|
|
+ public function getLakeLogList(array $where, $page, $limit)
|
|
|
+ {
|
|
|
+ // 根据条件查询数据,$where 为查询条件数组
|
|
|
+ $mark = app()->make(AwardLakeLogDao::class);
|
|
|
+ $query = $mark->search($where);
|
|
|
+
|
|
|
+ // 统计满足条件的数据总数
|
|
|
+ $count = $query->count();
|
|
|
+
|
|
|
// 查询满足条件的数据列表,带有 'label' 关联数据,按 'label_rule_id' 倒序排列
|
|
|
// 分页查询,返回当前页码的 $limit 条数据,并将结果转换为数组形式
|
|
|
$list = $query->page($page, $limit)->select()->toArray();
|