sync-namespace:同步命名空间

This commit is contained in:
hardstylewyl 2025-03-04 14:19:34 +08:00
parent 3382bcff76
commit 25298dc494
33 changed files with 498 additions and 514 deletions

View File

@ -1,4 +1,4 @@
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning.Complete;
namespace SJZY.Track.Application.Contract.Dtos.Warning.Complete;
/// <summary>
/// 完整预警

View File

@ -1,7 +1,7 @@
using Track.Warning.VNext.Application.Contract.Dtos.Common;
using Track.Warning.VNext.Application.Contract.Dtos.Warning.Return;
using SJZY.Track.Application.Contract.Dtos.Warning;
using SJZY.Track.Application.Contract.Dtos.Warning.Return;
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning.Complete;
namespace SJZY.Track.Application.Contract.Dtos.Warning.Complete;
/// <summary>
/// 完整预警规则配置条目

View File

@ -1,8 +1,7 @@
using System.ComponentModel.DataAnnotations;
using Track.Warning.VNext.Application.Contract.DataAnnotations;
using Track.Warning.VNext.Application.Contract.Dtos.Common;
using SJZY.Track.Application.Contract.Dtos.Warning.DataAnnotations;
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning.Complete;
namespace SJZY.Track.Application.Contract.Dtos.Warning.Complete;
/// <summary>
/// 编辑完整预警配置

View File

@ -1,6 +1,6 @@
using Track.Warning.VNext.Application.Contract.DataAnnotations;
using SJZY.Track.Application.Contract.Dtos.Warning.DataAnnotations;
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning.Complete;
namespace SJZY.Track.Application.Contract.Dtos.Warning.Complete;
/// <summary>
/// 获取完整预警规则条目列表

View File

@ -1,6 +1,4 @@
using Track.Warning.VNext.Application.Contract.Dtos.Common;
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning.Complete;
namespace SJZY.Track.Application.Contract.Dtos.Warning.Complete;
/// <summary>
/// 分页获取完成预警详情

View File

@ -1,6 +1,6 @@
using System.ComponentModel.DataAnnotations;
namespace Track.Warning.VNext.Application.Contract.DataAnnotations;
namespace SJZY.Track.Application.Contract.Dtos.Warning.DataAnnotations;
/// <summary>
/// 要求id存在并且大于0

View File

@ -1,4 +1,4 @@
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning;
namespace SJZY.Track.Application.Contract.Dtos.Warning;
/// <summary>
/// 获取预警规则主体

View File

@ -1,7 +1,7 @@
using System.ComponentModel.DataAnnotations;
using Track.Warning.VNext.Application.Contract.DataAnnotations;
using SJZY.Track.Application.Contract.Dtos.Warning.DataAnnotations;
namespace Track.Warning.VNext.Application.Contract.Dtos.Common;
namespace SJZY.Track.Application.Contract.Dtos.Warning;
public sealed class NotifyUserDto
{

View File

@ -1,8 +1,7 @@
using System.ComponentModel.DataAnnotations;
using Track.Warning.VNext.Application.Contract.DataAnnotations;
using Track.Warning.VNext.Application.Contract.Dtos.Common;
using SJZY.Track.Application.Contract.Dtos.Warning.DataAnnotations;
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning.Return;
namespace SJZY.Track.Application.Contract.Dtos.Warning.Return;
/// <summary>
/// 编辑回传时效配置

View File

@ -1,6 +1,4 @@
using Track.Warning.VNext.Application.Contract.Dtos.Common;
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning.Return;
namespace SJZY.Track.Application.Contract.Dtos.Warning.Return;
/// <summary>
/// 分页获取回传预警明细输入

View File

@ -1,6 +1,6 @@
using Track.Warning.VNext.Application.Contract.DataAnnotations;
using System.ComponentModel.DataAnnotations;
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning.Return;
namespace SJZY.Track.Application.Contract.Dtos.Warning.Return;
/// <summary>
/// 获取回传报文日志
@ -10,6 +10,6 @@ public class GetReturnMessageRecordInput
/// <summary>
/// 回传预警明细id
/// </summary>
[IdRequired]
[Required]
public string WarningDetailsId { get; set; }
}

View File

@ -1,6 +1,6 @@
using Track.Warning.VNext.Application.Contract.DataAnnotations;
using SJZY.Track.Application.Contract.Dtos.Warning.DataAnnotations;
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning.Return;
namespace SJZY.Track.Application.Contract.Dtos.Warning.Return;
/// <summary>
/// 获取回传预警规则项目列表

View File

@ -1,4 +1,4 @@
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning.Return;
namespace SJZY.Track.Application.Contract.Dtos.Warning.Return;
/// <summary>
/// 回传报文日志

View File

@ -1,4 +1,4 @@
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning.Return;
namespace SJZY.Track.Application.Contract.Dtos.Warning.Return;
/// <summary>
/// 回传预警明细

View File

@ -1,6 +1,4 @@
using Track.Warning.VNext.Application.Contract.Dtos.Common;
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning.Return;
namespace SJZY.Track.Application.Contract.Dtos.Warning.Return;
public class ReturnWarningRuleItemDto
{

View File

@ -1,8 +1,7 @@
using System.ComponentModel.DataAnnotations;
using Track.Warning.VNext.Application.Contract.DataAnnotations;
using Track.Warning.VNext.Application.Contract.Dtos.Common;
using SJZY.Track.Application.Contract.Dtos.Warning.DataAnnotations;
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning.Transport;
namespace SJZY.Track.Application.Contract.Dtos.Warning.Transport;
public class EditTransportWarningSceneRuleItemInput
{

View File

@ -1,6 +1,4 @@
using Track.Warning.VNext.Application.Contract.Dtos.Common;
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning.Transport;
namespace SJZY.Track.Application.Contract.Dtos.Warning.Transport;
/// <summary>
/// 分页获取运输预警明细

View File

@ -1,6 +1,6 @@
using Track.Warning.VNext.Application.Contract.DataAnnotations;
using SJZY.Track.Application.Contract.Dtos.Warning.DataAnnotations;
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning.Transport;
namespace SJZY.Track.Application.Contract.Dtos.Warning.Transport;
/// <summary>
/// 获取运输时效预警规则场景

View File

@ -1,6 +1,6 @@
using Track.Warning.VNext.Application.Contract.DataAnnotations;
using SJZY.Track.Application.Contract.Dtos.Warning.DataAnnotations;
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning.Transport;
namespace SJZY.Track.Application.Contract.Dtos.Warning.Transport;
/// <summary>
/// 获取运输时效预警场景规则条目列表

View File

@ -1,4 +1,4 @@
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning.Transport;
namespace SJZY.Track.Application.Contract.Dtos.Warning.Transport;
/// <summary>
/// 运输时效预警明细

View File

@ -1,4 +1,4 @@
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning.Transport;
namespace SJZY.Track.Application.Contract.Dtos.Warning.Transport;
/// <summary>
/// 预警规则场景

View File

@ -1,6 +1,6 @@
using Track.Warning.VNext.Application.Contract.Dtos.Common;
using SJZY.Track.Application.Contract.Dtos.Warning;
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning.Transport;
namespace SJZY.Track.Application.Contract.Dtos.Warning.Transport;
/// <summary>
/// 运输时效场景规则项目

View File

@ -1,6 +1,5 @@
using Track.Warning.VNext.Application.Contract.DataAnnotations;
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning.Transport;
using SJZY.Track.Application.Contract.Dtos.Warning.DataAnnotations;
namespace SJZY.Track.Application.Contract.Dtos.Warning.Transport;
public class UpsertTransportWarningSceneInput
{

View File

@ -1,7 +1,7 @@
using System.ComponentModel.DataAnnotations;
using Track.Warning.VNext.Application.Contract.DataAnnotations;
using SJZY.Track.Application.Contract.Dtos.Warning.DataAnnotations;
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning;
namespace SJZY.Track.Application.Contract.Dtos.Warning;
/// <summary>
/// 更新或者新增预警规则主体

View File

@ -1,4 +1,4 @@
namespace Track.Warning.VNext.Application.Contract.Dtos.Warning;
namespace SJZY.Track.Application.Contract.Dtos.Warning;
/// <summary>
/// 预警规则主体

View File

@ -557,24 +557,24 @@ public partial class TrackService : ApplicationService, ITrackService
//查询并按比较字段过滤轨迹,当比较字段为空时则使用轨迹发生时间过滤
//tips:后续进行投影缩参优化
private async Task<List<TrackDetailsIndex>> QueryAndFilterAsync(int orderId1, string trackCode1, DateTime trackTime1, string? extra1, string? compareFields1)
private async Task<List<TrackDetailsIndex>> QueryAndFilterAsync(int orderId, string trackCode, DateTime trackTime, string? extra, string? compareFields)
{
var tracks1 = await _trackDetailsEsRepository.GetListAsync(new[] { orderId1 }, trackCode1, true);
var tracks = await _trackDetailsEsRepository.GetListAsync(new[] { orderId }, trackCode, true);
//无比较字段时使用轨迹时间参与过滤(兼容老版本)
if (string.IsNullOrWhiteSpace(compareFields1))
if (string.IsNullOrWhiteSpace(compareFields))
{
return tracks1.Where(x => x.TrackTime == trackTime1).ToList();
return tracks.Where(x => x.TrackTime == trackTime).ToList();
}
return tracks1.Where(x =>
return tracks.Where(x =>
{
if (string.IsNullOrWhiteSpace(x.Extra))
throw new BusinessException(message: "轨迹extra为空无法使用比较字段比较,请检查轨迹");
var extraJsonElement = TextJsonHelper.DeserializeToJsonElement(x.Extra);
var inputExtraJsonElement = TextJsonHelper.DeserializeToJsonElement(extra1);
var inputExtraJsonElement = TextJsonHelper.DeserializeToJsonElement(extra);
return TextJsonHelper.EqByJsonElementField(extraJsonElement, inputExtraJsonElement, compareFields1);
return TextJsonHelper.EqByJsonElementField(extraJsonElement, inputExtraJsonElement, compareFields);
})
.ToList();
}

View File

@ -1,15 +1,13 @@
using Microsoft.AspNetCore.Mvc;
using Track.Warning.VNext.Application.Contract.Dtos.Common;
using Track.Warning.VNext.Application.Contract.Dtos.Warning.Complete;
using SJZY.Track.Application.Contract.Dtos.Warning.Complete;
namespace Track.Warning.VNext.Controllers.Warning;
namespace SJZY.Track.Application.Services.Warning;
/// <summary>
/// 完整预警服务
/// </summary>
[ApiController]
[ApiExplorerSettings(GroupName = "预警服务")]
[Route("Warning/Complete")]
public class CompleteWarningService : ControllerBase
public class CompleteWarningService : ApplicationService
{
/// <summary>
/// 编辑完整预警规则列表

View File

@ -1,15 +1,13 @@
using Microsoft.AspNetCore.Mvc;
using Track.Warning.VNext.Application.Contract.Dtos.Common;
using Track.Warning.VNext.Application.Contract.Dtos.Warning.Return;
using SJZY.Track.Application.Contract.Dtos.Warning.Return;
namespace Track.Warning.VNext.Controllers.Warning;
namespace SJZY.Track.Application.Services.Warning;
/// <summary>
/// 回传预警服务
/// </summary>
[ApiController]
[ApiExplorerSettings(GroupName = "预警服务")]
[Route("Warning/Return")]
public class ReturnWarningService : ControllerBase
public class ReturnWarningService : ApplicationService
{
/// <summary>
/// 编辑回传预警规则列表
@ -28,8 +26,7 @@ public class ReturnWarningService : ControllerBase
/// <param name="input"></param>
/// <returns></returns>
[HttpPost("GetPageReturnWarningDetails")]
public Task<UnifyPageResultDto<ReturnWarningDetailsDto>>
GetPageReturnWarningDetails(GetPageReturnWarningDetailsInput input)
public Task<UnifyPageResultDto<ReturnWarningDetailsDto>> GetPageReturnWarningDetails(GetPageReturnWarningDetailsInput input)
{
return Task.FromResult(new UnifyPageResultDto<ReturnWarningDetailsDto>());
}
@ -38,8 +35,7 @@ public class ReturnWarningService : ControllerBase
/// 获取回传报文日志
/// </summary>
[HttpPost("GetReturnMessageRecord")]
public Task<UnifyResultDto<List<ReturnMessageRecordDto>>>
GetReturnMessageRecord(GetReturnMessageRecordInput input)
public Task<UnifyResultDto<List<ReturnMessageRecordDto>>> GetReturnMessageRecord(GetReturnMessageRecordInput input)
{
return Task.FromResult(new UnifyResultDto<List<ReturnMessageRecordDto>>());
}

View File

@ -1,11 +1,11 @@
using Track.Warning.VNext.Application.Contract.Dtos.Warning.Transport;
using SJZY.Track.Application.Contract.Dtos.Warning.Transport;
/// <summary>
/// 运输时效预警服务
/// </summary>
[ApiController]
[ApiExplorerSettings(GroupName = "预警服务")]
[Route("Warning/Transport")]
public class TransportWarningService : ControllerBase
public class TransportWarningService : ApplicationService
{
/// <summary>

View File

@ -1,13 +1,13 @@
using Track.Warning.VNext.Application.Contract.Dtos.Warning;
using SJZY.Track.Application.Contract.Dtos.Warning;
namespace Track.Warning.VNext.Controllers.Warning;
namespace SJZY.Track.Application.Services.Warning;
/// <summary>
/// 预警规则主体
/// </summary>
[ApiController]
[ApiExplorerSettings(GroupName = "预警服务")]
[Route("Warning")]
public class WarningService : ControllerBase
public class WarningService : ApplicationService
{
/// <summary>
/// 新增/修改预警规则主体

View File

@ -8,6 +8,9 @@ public interface ITrackDetailsEsRepository : IElasticsearchClientService<TrackDe
{
Task<List<TrackDetailsIndex>> GetListAsync(int[] orderIds, string trackCode, bool forUpsert = false);
// todo:s07 获取这些订单的最新一条轨迹
// Task<List<TrackDetailsIndex>> GetLatestListAsync(HashSet<int> eventOrderIds);
Task<List<TrackDetailsIndex>> GetLatestListAsync(int[] eventOrderIds, List<string> trackCodes);
Task<List<TrackDetailsIndex>> GetListAsync(int subSystemId, int orderType, List<string> orderNos, List<string>? trackCodes = null);

View File

@ -2,9 +2,8 @@ using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Hosting;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Logging;
using SJZY.Track.Test;
namespace SJZY.OpenApi.Test;
namespace SJZY.Track.Test;
public class Startup
{

View File

@ -2,7 +2,7 @@ using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Hosting;
using Volo.Abp.AspNetCore.TestBase;
namespace SJZY.OpenApi.Test;
namespace SJZY.Track.Test;
public class TestModuleTestBase : AbpAspNetCoreIntegratedTestBase<Startup>
{