lqmac 3 months ago
parent fafe9e7046
commit 422558d8dc
  1. 2
      app/common/model/Goods.php

@ -330,7 +330,7 @@ class Goods extends BaseModel
}
$str = trim($str, "or ");
//筛选的分类不在当前筛选条件里面就无需带上过滤条件
if (in_array($param['categoryId'], $categorys)) {
if (!$param['categoryId'] || in_array($param['categoryId'], $categorys)) {
// 执行查询
$list = $query->with(['images.file'])
->alias($this->name)

Loading…
Cancel
Save