logistic_number=$logistic_number; } /** * Execute the job. * * @return void */ public function handle() { LogService::log(LogisticAliJiSuSync::class, "{$this->logistic_number}-JOB-AliJiSu", ''); $this->logisticAliJiSuApiService = app('LogisticAliJiSuApiService'); try { $response = $this->logisticAliJiSuApiService->query($this->logistic_number); if ($response && $response->status==0){ $format = $this->logisticAliJiSuApiService->format($response); $this->orderPackageReceivedSyncService = app('OrderPackageReceivedSyncService'); if (count($format)>0 && $format['logistic_number']??false) $this->orderPackageReceivedSyncService->update([$format]); } } catch (\Exception $e) { app('LogService')->log(__METHOD__, __FUNCTION__, "阿里极速数据同步快递数据 ERROR " . ' || ' . json_encode($this->logistic_number) . ' || ' . json_encode($e->getMessage()) . ' || ' . json_encode($e->getTraceAsString())); } } }