|
|
|
@ -506,7 +506,7 @@ namespace Myshipping.Application
|
|
|
|
|
try
|
|
|
|
|
{
|
|
|
|
|
result.succ = true;
|
|
|
|
|
result.ext = InnerGetRunListBySigleBusiness(info);
|
|
|
|
|
result.ext = InnerGetRunListBySingleBusiness(info);
|
|
|
|
|
}
|
|
|
|
|
catch (Exception ex)
|
|
|
|
|
{
|
|
|
|
@ -524,7 +524,7 @@ namespace Myshipping.Application
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="info">查询服务流程详情</param>
|
|
|
|
|
/// <returns>返回查询列表</returns>
|
|
|
|
|
private List<ServiceWorkFlowRunDto> InnerGetRunListBySigleBusiness(TrackingQueryMessageInfo info)
|
|
|
|
|
private List<ServiceWorkFlowRunDto> InnerGetRunListBySingleBusiness(TrackingQueryMessageInfo info)
|
|
|
|
|
{
|
|
|
|
|
var runList = _serviceWorkFlowRunInfoRepository.AsQueryable()
|
|
|
|
|
.Filter(null, true)
|
|
|
|
@ -1241,7 +1241,7 @@ namespace Myshipping.Application
|
|
|
|
|
}
|
|
|
|
|
};
|
|
|
|
|
//在获取运行表已有的记录
|
|
|
|
|
var runList = InnerGetRunListBySigleBusiness(messageInfo);
|
|
|
|
|
var runList = InnerGetRunListBySingleBusiness(messageInfo);
|
|
|
|
|
|
|
|
|
|
var resultList = projectList.GroupJoin(runList, l => l.PKId, r => r.ServiceProjectId, (l, r) => {
|
|
|
|
|
var currList = r.ToList();
|
|
|
|
@ -1254,7 +1254,6 @@ namespace Myshipping.Application
|
|
|
|
|
ProjectCode = l.ServiceProjectCode,
|
|
|
|
|
ProjectName = l.ServiceProjectName,
|
|
|
|
|
SortNo = l.SortNo
|
|
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
if(runInfo != null)
|
|
|
|
@ -1278,6 +1277,96 @@ namespace Myshipping.Application
|
|
|
|
|
return result;
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
#region 检索服务项目下的状态列表
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 检索服务项目下的状态列表
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="model">查询服务项目和状态详情</param>
|
|
|
|
|
/// <returns>返回回执</returns>
|
|
|
|
|
public async Task<TaskManageOrderResultDto> GetEnableStatusListByProject(QueryServiceProjectWithStatus model)
|
|
|
|
|
{
|
|
|
|
|
TaskManageOrderResultDto result = new TaskManageOrderResultDto();
|
|
|
|
|
|
|
|
|
|
try
|
|
|
|
|
{
|
|
|
|
|
var statuList = await _serviceWorkFlowBaseService.GetEnableProjectWithStatusList(model.TenantId.ToString());
|
|
|
|
|
|
|
|
|
|
var resultList = statuList.Where(a => model.ProjectCodes.Contains(a.ProjectCode))
|
|
|
|
|
.OrderBy(a => a.SortNo)
|
|
|
|
|
.SelectMany(a => a.StatusList.OrderBy(b=>b.SortNo))
|
|
|
|
|
.ToList();
|
|
|
|
|
|
|
|
|
|
result.succ = true;
|
|
|
|
|
result.ext = resultList;
|
|
|
|
|
}
|
|
|
|
|
catch (Exception ex)
|
|
|
|
|
{
|
|
|
|
|
result.succ = false;
|
|
|
|
|
result.msg = $"检索服务项目下的状态列表失败,原因:{ex.Message}";
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return result;
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 单票检索服务项目下的状态列表
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 单票检索服务项目下的状态列表
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="model">查询服务项目和状态详情</param>
|
|
|
|
|
/// <returns>返回回执</returns>
|
|
|
|
|
public async Task<TaskManageOrderResultDto> GetEnableStatusListByBusiness(QueryServiceProjectWithStatus model)
|
|
|
|
|
{
|
|
|
|
|
TaskManageOrderResultDto result = new TaskManageOrderResultDto();
|
|
|
|
|
|
|
|
|
|
try
|
|
|
|
|
{
|
|
|
|
|
var statuList = await _serviceWorkFlowBaseService.GetEnableProjectWithStatusList(model.TenantId.ToString());
|
|
|
|
|
|
|
|
|
|
var resultList = statuList.Where(a => model.ProjectCodes.Contains(a.ProjectCode))
|
|
|
|
|
.OrderBy(a => a.SortNo)
|
|
|
|
|
.SelectMany(a => a.StatusList.OrderBy(b => b.SortNo))
|
|
|
|
|
.ToList();
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
|
TrackingQueryMessageInfo messageInfo = new TrackingQueryMessageInfo
|
|
|
|
|
{
|
|
|
|
|
Head = new TrackingMessageHeadInfo
|
|
|
|
|
{
|
|
|
|
|
GID = IDGen.NextID().ToString(),
|
|
|
|
|
MessageType = "PROJECT",
|
|
|
|
|
ReceiverId = "ServiceProjectStatus",
|
|
|
|
|
ReceiverName = "服务项目和状态",
|
|
|
|
|
SenderId = "BookingOrder",
|
|
|
|
|
SenderName = "海运订舱",
|
|
|
|
|
RequestDate = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss.fff"),
|
|
|
|
|
Version = "2.0",
|
|
|
|
|
RequestAction = "AddOrModify",
|
|
|
|
|
},
|
|
|
|
|
Main = new TrackingMessageQueryMainInfo
|
|
|
|
|
{
|
|
|
|
|
BusiId = model.BookingId.ToString(),
|
|
|
|
|
BusiSystemCode = "BOOKING_ORDER",
|
|
|
|
|
TenantId = model.TenantId.ToString(),
|
|
|
|
|
}
|
|
|
|
|
};
|
|
|
|
|
//在获取运行表已有的记录
|
|
|
|
|
var runList = InnerGetRunListBySingleBusiness(messageInfo);
|
|
|
|
|
*/
|
|
|
|
|
result.succ = true;
|
|
|
|
|
result.ext = resultList;
|
|
|
|
|
}
|
|
|
|
|
catch (Exception ex)
|
|
|
|
|
{
|
|
|
|
|
result.succ = false;
|
|
|
|
|
result.msg = $"检索服务项目下的状态列表失败,原因:{ex.Message}";
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return result;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|