WIN-2308041133\Administrator 5 months ago
parent
commit
90ae16e337
1 changed files with 3 additions and 0 deletions
  1. 3 0
      app/common/dao/store/product/SpuDao.php

+ 3 - 0
app/common/dao/store/product/SpuDao.php

@@ -83,6 +83,9 @@ class SpuDao extends  BaseDao
             ->when(isset($where['product_ids']) && $where['product_ids'] !== '',function($query)use($where){
                 $query->whereIn('P.product_id',$where['product_ids']);
             })
+            ->when(isset($where['type']) && $where['type'] !== '',function($query)use($where){
+                $query->where('P.type',$where['type']);
+            })
             ->when(isset($where['keyword']) && $where['keyword'] !== '',function($query)use($where){
                 if (is_numeric($where['keyword'])) {
                     $query->whereLike("S.store_name|S.keyword|S.product_id", "%{$where['keyword']}%");