Преглед изворни кода

[智价云] 多账号采集数据校验更新

tangyuanwang пре 4 дана
родитељ
комит
de9e36a61a

+ 1 - 0
app/Models/Manager/Process/LowPriceGoods.php

@@ -123,6 +123,7 @@ class LowPriceGoods extends Model
             $source_where[] = ['product_brand', '=', $data['product_brand']]; //品牌名称
             $source_where[] = ['product_name', '=', $data['product_name']]; //商品名称
             $source_where[] = ['product_specs', '=', $data['product_specs']]; //规格
+            $source_where[] = ['scrape_date', '=', $data['scrape_date']]; //采集日期
             $source_id_log = $this->where($source_where)->select(['id', 'online_posting_price'])->first();
             if (!empty($source_id_log)) {
                 if ($source_id_log->online_posting_price > $data['online_posting_price']) {

+ 1 - 0
app/Models/Manager/Process/ViolationProduct.php

@@ -117,6 +117,7 @@ class ViolationProduct extends Model
             $source_where[] = ['product_brand', '=', $data['product_brand']]; //品牌名称
             $source_where[] = ['product_name', '=', $data['product_name']]; //商品名称
             $source_where[] = ['product_specs', '=', $data['product_specs']]; //规格
+            $source_where[] = ['scrape_date', '=', $data['scrape_date']]; //采集日期
             $source_id_log = $this->where($source_where)->count();
             if ($source_id_log > 0) {
                 return true;