正在显示
1 个修改的文件
包含
1 行增加
和
1 行删除
| @@ -179,7 +179,7 @@ class VideoTask extends Command | @@ -179,7 +179,7 @@ class VideoTask extends Command | ||
| 179 | $productModel = new Product(); | 179 | $productModel = new Product(); |
| 180 | $productList = $productModel->list(['keyword_id'=>['like','%,'.$keywordInfo['id'].',%']],['thumb','title']); | 180 | $productList = $productModel->list(['keyword_id'=>['like','%,'.$keywordInfo['id'].',%']],['thumb','title']); |
| 181 | if(count($productList) < 5){ | 181 | if(count($productList) < 5){ |
| 182 | - $productList = $productModel->list([],'sort',['thumb','title']); | 182 | + $productList = $productModel->inRandomOrder()->take(100)->get()->toArray(); |
| 183 | //获取7个产品主图 | 183 | //获取7个产品主图 |
| 184 | } | 184 | } |
| 185 | $product_image = []; | 185 | $product_image = []; |
-
请 注册 或 登录 后发表评论