Эх сурвалжийг харах

清除取消订单 脚本

ajun 5 жил өмнө
parent
commit
9c2fe4bcc2

+ 11 - 0
app/Http/Controllers/TestController.php

@@ -19,6 +19,7 @@ use App\Console\Commands\WasSyncWmsAsnInformation;
 use App\Exceptions\ErrorException;
 use App\Events\CancelOrder;
 use App\Events\SendEmailEvent;
+use App\Exceptions\Exception;
 use App\Http\Requests\ForeignHaiRobotic_taskUpdateRequest;
 use App\Http\Requests\TestAaRequest;
 use App\Imports\OrderTrackingImport;
@@ -1555,4 +1556,14 @@ where (commodities.owner_id,commodity_barcodes.code) in (select commodities.owne
         app(BatchUpdateService::class)->batchUpdate('rejected_bills', $updates);
         }
     }
+
+    public function clearCancelledOrder()
+    {
+        try {
+            OracleDOCWaveDetails::query()->where('OrderNo', 'SO210202003270')->delete();
+            app('LogService')->log(__CLASS__, __METHOD__, 'Delete OracleDOCWaveDetails' . '  SO210202003270' );
+        } catch (Exception $e) {
+            app('LogService')->log(__CLASS__, __METHOD__,'Error clearCancelledOrder' . 'SO210202003270');
+        }
+    }
 }