diff --git a/src/SJZY.Track.Application.Contract/Dtos/ProvideServices/OrderNoInfo.cs b/src/SJZY.Track.Application.Contract/Dtos/ProvideServices/OrderNoInfo.cs index 7418c745..48392a10 100644 --- a/src/SJZY.Track.Application.Contract/Dtos/ProvideServices/OrderNoInfo.cs +++ b/src/SJZY.Track.Application.Contract/Dtos/ProvideServices/OrderNoInfo.cs @@ -7,6 +7,13 @@ namespace SJZY.Track.Application.Contract.Dtos.ProvideServices; /// public class OrderNoInfo { + /// + /// 子系统id + /// + [Required] + [Range(1, int.MaxValue)] + public int SubSystemId { get; set; } + /// /// 订单类型,必填 /// @@ -24,6 +31,13 @@ public class OrderNoInfo public class OrderNosInfo { + /// + /// 子系统id + /// + [Required] + [Range(1, int.MaxValue)] + public int SubSystemId { get; set; } + /// /// 订单类型 /// diff --git a/src/SJZY.Track.Application.Contract/Dtos/ProvideServices/UpdateOrderInput.cs b/src/SJZY.Track.Application.Contract/Dtos/ProvideServices/UpdateOrderInput.cs index 17a9a838..3bb10008 100644 --- a/src/SJZY.Track.Application.Contract/Dtos/ProvideServices/UpdateOrderInput.cs +++ b/src/SJZY.Track.Application.Contract/Dtos/ProvideServices/UpdateOrderInput.cs @@ -61,4 +61,45 @@ public class UpdateOrderInput : OrderNoInfo /// 产品编码 /// public string? ProductCode { get; set; } + + /// + /// 业务key + /// + public string Key { get; set; } + + /// + /// 拉取配置信息 + /// + public List PullConfigInfos { get; set; } +} + +public class PullConfigInfo +{ + /// + /// 服务商code + /// + [Required] + public string ServiceCode { get; set; } + + /// + /// 开始轨迹code + /// + public string? StartCode { get; set; } + + /// + /// 结束轨迹code + /// + public string? EndCode { get; set; } + + /// + /// 静默多久后拉取(小时) + /// + [Range(0, 24 * 7)] + public int SilenceTime { get; set; } + + /// + /// 结束多久后停止拉取(小时) + /// + [Range(0, 24 * 7)] + public int StopTime { get; set; } } diff --git a/src/SJZY.Track.Application/Services/ProvideServices/OrderService.cs b/src/SJZY.Track.Application/Services/ProvideServices/OrderService.cs index 4d25a09a..fe813627 100644 --- a/src/SJZY.Track.Application/Services/ProvideServices/OrderService.cs +++ b/src/SJZY.Track.Application/Services/ProvideServices/OrderService.cs @@ -4,7 +4,6 @@ using SJZY.Track.Application.Contract.Services; using SJZY.Track.Domain.Aggregates.OrderAggregate; using SJZY.Track.Domain.Aggregates.TrackDetailsAggregate; using SJZY.Track.Domain.Queries; -using SJZY.UserCenter.HttpApi.Services; namespace SJZY.Track.Application.Services.ProvideServices; @@ -34,7 +33,7 @@ public partial class OrderService : ApplicationService, IOrderService [HttpPost("Order/Upsert")] public async Task> UpsertAsync(UpsertOrderInput input) { - var subSystemId = CurrentUserRequest.SubSystemId; + var subSystemId = input.SubSystemId; // 校验订单是否已存在,存在则更新 var order = await _orderRepository.GetFirstAsync(x => @@ -70,7 +69,7 @@ public partial class OrderService : ApplicationService, IOrderService [HttpPost("Order/Delete")] public async Task> DeleteOrderAsync(DeleteOrderInput input) { - var susSystemId = CurrentUserRequest.SubSystemId; + var susSystemId = input.SubSystemId; var orderId = await _orderRepository.GetFirstAsync(x => x.SubSystemId == susSystemId && x.OrderType == input.OrderType && x.OrderNo == input.OrderNo, x => x.Id); if (orderId == default) diff --git a/src/SJZY.Track.Application/Services/ProvideServices/TrackService.Query.cs b/src/SJZY.Track.Application/Services/ProvideServices/TrackService.Query.cs index 19db347d..9eb371f2 100644 --- a/src/SJZY.Track.Application/Services/ProvideServices/TrackService.Query.cs +++ b/src/SJZY.Track.Application/Services/ProvideServices/TrackService.Query.cs @@ -1,7 +1,6 @@ using SJZY.Track.Application.Contract.Dtos.ProvideServices; using SJZY.Track.Domain.Aggregates.TrackDetailsAggregate; using SJZY.Track.Domain.Consts; -using SJZY.UserCenter.HttpApi.Services; namespace SJZY.Track.Application.Services.ProvideServices; @@ -26,7 +25,7 @@ public partial class TrackService throw new BusinessException(message: "最多只能查询500单"); } - var subSystemId = CurrentUserRequest.SubSystemId; + var subSystemId = input.SubSystemId; var res = new List(); input.OrderNos = input.OrderNos.Where(x => !x.IsNullOrWhiteSpace()).Distinct().ToList(); // 单号去重、去空