- 按 docs/renew-code-comment.md 将 PHP 文件头改为带边框的 Author 注释\n- 注释中的 crmeb.com 替换为 uj345.cn(代码字符串中的外链未改)\n- 新增 docs/renew-code-comment.md 说明 Made-with: Cursor
46 lines
1.1 KiB
PHP
46 lines
1.1 KiB
PHP
<?php
|
|
// +----------------------------------------------------------------------
|
|
// | Author: ScottPan Team
|
|
// +----------------------------------------------------------------------
|
|
|
|
namespace app\jobs\order;
|
|
|
|
|
|
use app\services\order\StoreDeliveryOrderServices;
|
|
use crmeb\basic\BaseJobs;
|
|
use crmeb\traits\QueueTrait;
|
|
|
|
/**
|
|
* 同城配送
|
|
* Class CityDeliveryJob
|
|
* @package app\jobs
|
|
*/
|
|
class CityDeliveryJob extends BaseJobs
|
|
{
|
|
use QueueTrait;
|
|
|
|
/**
|
|
* 同步创建、更新达达门店信息
|
|
* @param $id
|
|
* @param $is_new
|
|
* @return bool
|
|
*/
|
|
public function syncCityShop($id, $is_new)
|
|
{
|
|
try {
|
|
/** @var StoreDeliveryOrderServices $deliveryOrderServices */
|
|
$deliveryOrderServices = app()->make(StoreDeliveryOrderServices::class);
|
|
$deliveryOrderServices->syncCityShop((int)$id);
|
|
} catch (\Throwable $e) {
|
|
response_log_write([
|
|
'message' => '同步创建同城配送达达门店失败,原因:' . $e->getMessage(),
|
|
'file' => $e->getFile(),
|
|
'line' => $e->getLine()
|
|
]);
|
|
}
|
|
return true;
|
|
}
|
|
|
|
|
|
}
|