浏览代码

一些功能

Kirin 4 年之前
父节点
当前提交
fa64c0a9a3
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      app/models/store/StoreProductAttr.php

+ 1 - 1
app/models/store/StoreProductAttr.php

@@ -59,7 +59,7 @@ class StoreProductAttr extends BaseModel
             }
             if ($store_id && $type_id == 0) {
                 $stockinfo = SystemStoreProductStock::where('unique', $value['unique'])->where('store_id', $store_id)->find();
-                $value['price'] = $stockinfo ? $stockinfo['price'] : $value['price'];
+                $value['price'] = ($stockinfo && $stockinfo['price'] > 0) ? $stockinfo['price'] : $value['price'];
             }
             $values[$value['suk']] = $value;
         }