track/src/SJZY.Track.Application.Contract/Dtos/ProvideServices/UpdateOrderInput.cs
云龙 王 e09b8ac482 add-entity:
增加外部单号关联表实体OrderPlatformNumberEntity,一个主单关联对个外部单

update-entity:
OrderEntity,增加OrderPlatformNumbers导航属性用于SqlSugar的Include关联加载
OrderPullStatusEntity,增加Order(第三方单号)字段,当作拉取轨迹的首选项

入参模型更新:
UpdateOrderInput:轨迹订单创建/更新入参,增加【预计到达时间】【目的地时区】用于初始化

反参模型更新:
TrackOrderDto:用于轨迹订单查询的反参,增加【预计到达时间】【目的地时区】【第三方单号(格式化拼接后的字符串)】

feat:
- 实现轨迹订单查询支持三方单号查询,并将多个关联三方单号按(平台名称-三方单号)格式使用(、)拼接返回
- 创建/修改订单增加校验,规则为:【预计到达时间】【目的地时区】入参字段只允许全有值或全无值。
2024-11-14 16:12:29 +08:00

116 lines
2.5 KiB
C#
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

using System.ComponentModel.DataAnnotations;
namespace SJZY.Track.Application.Contract.Dtos.ProvideServices;
public class UpdateOrderInput : OrderNoInfo
{
/// <summary>
/// 目的港口
/// </summary>
public string? ArrivalPort { get; set; }
/// <summary>
/// 起运港口
/// </summary>
public string? LeavePort { get; set; }
/// <summary>
/// 目的国家,必填
/// </summary>
[Required]
[MaxLength(200)]
public string ArrivalCountry { get; set; } = null!;
/// <summary>
/// 起运国家,必填
/// </summary>
[Required]
[MaxLength(200)]
public string LeaveCountry { get; set; } = null!;
/// <summary>
/// 目的城市,必填
/// </summary>
[Required]
[MaxLength(200)]
public string ArrivalCity { get; set; } = null!;
/// <summary>
/// 起运城市,必填
/// </summary>
[Required]
[MaxLength(200)]
public string LeaveCity { get; set; } = null!;
/// <summary>
/// 货物类型
/// </summary>
public string? CargoType { get; set; }
/// <summary>
/// 是否转运
/// </summary>
public bool? IsTransit { get; set; }
/// <summary>
/// 产品编码
/// </summary>
public string? ProductCode { get; set; }
/// <summary>
/// 预计到达时间
/// </summary>
public DateTime? EstimatedDeliveryDate { get; set; }
/// <summary>
/// 目的地时区
/// </summary>
public float? DestinationTimeZone { get; set; }
/// <summary>
/// 拉取配置信息
/// </summary>
public List<PullConfigInfo>? PullConfigInfos { get; set; }
/// <summary>
/// 订单航班信息
/// </summary>
public List<OrderFlightInfo> FlightInfos { get; set; } = new();
}
public class PullConfigInfo
{
/// <summary>
/// 服务商code
/// </summary>
[Required]
public string ServiceCode { get; set; }
/// <summary>
/// api服务商订单号(第三方单号)
/// </summary>
public string? OrderNo { get; set; }
/// <summary>
/// 开始轨迹code
/// </summary>
public string? StartCode { get; set; }
/// <summary>
/// 结束轨迹code
/// </summary>
public string? EndCode { get; set; }
/// <summary>
/// 静默多久后拉取(小时)
/// </summary>
[Range(0, 24 * 7)]
public int SilenceTime { get; set; }
/// <summary>
/// 结束多久后停止拉取(小时)
/// </summary>
[Range(0, 24 * 7)]
public int StopTime { get; set; }
}