更新接口

This commit is contained in:
mkm 2023-04-23 19:27:52 +08:00
parent 8520003374
commit 087b01c74a

View File

@ -48,7 +48,7 @@ class SpuDao extends BaseDao
if(isset($where['order']) && $where['order'] === 'none'){
$order = '';
}
$query = Spu::getDB()->alias('S')->join('StoreProduct P','S.product_id = P.product_id', 'left')->where('P.product_type',0);
$query = Spu::getDB()->alias('S')->join('StoreProduct P','S.product_id = P.product_id', 'left')->where('P.product_type',$where['product_type']);
$query->when(isset($where['is_del']) && $where['is_del'] !== '',function($query)use($where){
$query->where('P.is_del',$where['is_del']);
})