Explorar o código

[智价云] 采集日期时间校验更新

tangyuanwang hai 10 horas
pai
achega
8825b72c39

+ 1 - 1
app/Http/Controllers/Manager/Process/LowPriceGoods.php

@@ -1215,7 +1215,7 @@ class LowPriceGoods extends Controller
             if (!preg_match('/^[0-9]{4}-[0-9]{2}-[0-9]{2}$/',$item[21])){
                 return ['code' => 'error', 'msg' => "第{$key}行检索采集日期格式不正确", 'data' => $item];
             }
-            if (strtotime($item[21]. ' 23:59:59') > time()){
+            if (strtotime($item[21]. ' 00:00:00') > time()){
                 return ['code' => 'error', 'msg' => "第{$key}行检索采集日期不能大于当前日期", 'data' => $item];
             }
         }

+ 1 - 1
app/Http/Controllers/Manager/Process/ViolationProduct.php

@@ -1012,7 +1012,7 @@ class ViolationProduct extends Controller
             if (!preg_match('/^[0-9]{4}-[0-9]{2}-[0-9]{2}$/',$item[19])){
                 return ['code' => 'error', 'msg' => "第{$key}行检索采集日期格式不正确", 'data' => $item];
             }
-            if (strtotime($item[19]. ' 23:59:59') > time()){
+            if (strtotime($item[19]. ' 00:00:00') > time()){
                 return ['code' => 'error', 'msg' => "第{$key}行检索采集日期不能大于当前日期", 'data' => $item];
             }
         }