Read SupplierCode from rules publish snapshots before falling back to live itfx metadata so UpsertSmallBag gets apiCode at order create time.
50 lines
1.4 KiB
C#
50 lines
1.4 KiB
C#
namespace Oms.Application.Integrations.SmallBagTrack;
|
||
|
||
/// <summary>
|
||
/// POST /OrderV2/UpsertSmallBag 请求体。
|
||
/// </summary>
|
||
public class SmallBagTrackUpsertRequest
|
||
{
|
||
public string Client { get; set; } = string.Empty;
|
||
|
||
public string OrderNo { get; set; } = string.Empty;
|
||
|
||
public string TrackNo { get; set; } = string.Empty;
|
||
|
||
public string OtherNo { get; set; } = string.Empty;
|
||
|
||
public string Channel { get; set; } = string.Empty;
|
||
|
||
public string Product { get; set; } = string.Empty;
|
||
|
||
/// <summary>
|
||
/// 轨迹拉取配置 code(对应轨迹 ServiceProviderCode;优先发布快照 SupplierCode)。
|
||
/// </summary>
|
||
public string ApiCode { get; set; } = string.Empty;
|
||
|
||
public SmallBagTrackConsigneeRequest Consignee { get; set; } = new();
|
||
|
||
/// <summary>
|
||
/// 转发到轨迹网关的 Authorization(异步入队前从当前 HTTP 请求捕获)。
|
||
/// </summary>
|
||
public string? Authorization { get; set; }
|
||
|
||
/// <summary>
|
||
/// UpsertSmallBag 成功后是否追加创单默认轨迹(A0101/SZ)。
|
||
/// </summary>
|
||
public bool AppendInitialTrackOnSuccess { get; set; }
|
||
}
|
||
|
||
public class SmallBagTrackConsigneeRequest
|
||
{
|
||
public string CountryCode { get; set; } = string.Empty;
|
||
|
||
public string Province { get; set; } = string.Empty;
|
||
|
||
public string Postcode { get; set; } = string.Empty;
|
||
|
||
public string City { get; set; } = string.Empty;
|
||
|
||
public string Email { get; set; } = string.Empty;
|
||
}
|