From 1391cf16af18ff9f0750624a1f1328ca15bf1b73 Mon Sep 17 00:00:00 2001 From: mkm <727897186@qq.com> Date: Wed, 17 May 2023 16:11:36 +0800 Subject: [PATCH] =?UTF-8?q?=E9=9A=8F=E6=9C=BA=E6=95=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/common/repositories/store/product/SpuRepository.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/common/repositories/store/product/SpuRepository.php b/app/common/repositories/store/product/SpuRepository.php index 1d434d6f..83951b66 100644 --- a/app/common/repositories/store/product/SpuRepository.php +++ b/app/common/repositories/store/product/SpuRepository.php @@ -171,7 +171,7 @@ class SpuRepository extends BaseRepository }, 'issetCoupon', ]); - $list = $query->page($page, $limit)->setOption('field', [])->field($this->productFiled)->select(); + $list = $query->page($page, $limit)->setOption('field', [])->field($this->productFiled)->orderRaw('rand()')->select(); $append = ['stop_time','svip_price','show_svip_info','is_svip_price']; $list->append($append);