作者 SHW\戥岁。。

分页不生效

... ... @@ -401,7 +401,7 @@ class Classification extends Api
->where('category_id', $sort_id)
->where('goods_status', '10')
->field('goods_id,spec_type,goods_name,image')
->paginate(10, false, ['page' => $page])
->paginate(10)
->each(function (&$item) {
if ($this->auth->isLogin()) {
$item['cart_number'] = Db::name('cart')
... ... @@ -472,7 +472,7 @@ class Classification extends Api
->where('is_delete', '0')
->where('goods_status', '10')
->field('goods_id,goods_name,spec_type,image')
->paginate(10, false, ['page' => $page])
->paginate(10)
->each(function (&$item) {
if ($this->auth->isLogin()) {
$item['cart_number'] = Db::name('cart')
... ...