logistic_number = $logistic_number; } /** * Execute the job. * * @return void */ public function handle() { LogService::log(LogisticYTOSync::class, "{$this->logistic_number}-JOB-YTO", ''); $this->logisticYTOService = app('LogisticYTOService'); $nativeResponse = $this->logisticYTOService->query($this->logistic_number); $formattedData = $this->logisticYTOService->format($nativeResponse); $this->orderPackageReceivedSyncService = app('OrderPackageReceivedSyncService'); if (count($formattedData)>0 && $formattedData['logistic_number']){ $this->orderPackageReceivedSyncService->update([$formattedData]); }else{ LogService::log(LogisticYTOService::class, "YTO快递无快递异常", $formattedData); } } }