fix(logistics): 修复物流服务中订单状态和唯一ID的赋值逻辑 #58

Merged
longbot merged 3 commits from zhuotianyuan/API:div into stable 2026-01-22 06:53:18 +00:00
2 changed files with 32 additions and 32 deletions
Showing only changes of commit c592310fa9 - Show all commits

View File

@ -21,7 +21,7 @@ export class SyncTmsJob implements IJob {
shipmentModel: Repository<Shipment>
async onTick() {
const shipments:Shipment[] = await this.shipmentModel.findBy({ tracking_provider: 'freightwaves',finished: false });
const shipments: Shipment[] = await this.shipmentModel.findBy({ tracking_provider: 'freightwaves', finished: false });
const results = await Promise.all(
shipments.map(async shipment => {
return await this.logisticsService.updateFreightwavesShipmentState(shipment);

View File

@ -140,10 +140,10 @@ interface QueryOrderResponseData {
}
// 修改订单响应数据接口
interface ModifyOrderResponseData extends CreateOrderResponseData {}
interface ModifyOrderResponseData extends CreateOrderResponseData { }
// 订单退款响应数据接口
interface RefundOrderResponseData {}
interface RefundOrderResponseData { }
@Provide()
export class FreightwavesService {
@ -180,11 +180,11 @@ export class FreightwavesService {
};
// 记录请求前的详细信息
console.log(`Sending request to: ${this.config.apiBaseUrl}${url}`,JSON.stringify({
console.log(`Sending request to: ${this.config.apiBaseUrl}${url}`, JSON.stringify({
headers,
data
}))
console.log('Request data:', `${this.config.apiBaseUrl}${url}`, data,headers);
console.log('Request data:', `${this.config.apiBaseUrl}${url}`, data, headers);
// 发送请求 - 临时禁用SSL证书验证以解决UNABLE_TO_VERIFY_LEAF_SIGNATURE错误
const response = await axios.post<FreightwavesResponse<T>>(
`${this.config.apiBaseUrl}${url}`,