liugc преди 1 година
родител
ревизия
401f7437b3
променени са 1 файла, в които са добавени 1 реда и са изтрити 1 реда
  1. 1 1
      app/adminapi/logic/spare_part/SparePartLogic.php

+ 1 - 1
app/adminapi/logic/spare_part/SparePartLogic.php

@@ -146,7 +146,7 @@ class SparePartLogic extends BaseLogic
     public static function isExamineOk($service_work_id)
     {
         $tm = time() - 3 * 86400;
-        $count = ServiceWorkSpare::where("create_time",'<', $tm)->where("service_work_id",$service_work_id)->whereIn('status', [0,2])->count();
+        $count = ServiceWorkSpare::where("service_work_id",$service_work_id)->whereIn('status', [0,2])->count();
         $serviceWorkInfo = ServiceWork::find($service_work_id);
         if((int)$serviceWorkInfo['work_pay_status'] !== 3){
             throw new \Exception('该工单非待结算状态');