|
|
@ -2435,7 +2435,7 @@ namespace Myshipping.Application
|
|
|
|
/// <param name="pageSize">页码容量</param>
|
|
|
|
/// <param name="pageSize">页码容量</param>
|
|
|
|
/// <param name="descSort">排序方法,默认降序</param>
|
|
|
|
/// <param name="descSort">排序方法,默认降序</param>
|
|
|
|
/// <returns>返回结果</returns>
|
|
|
|
/// <returns>返回结果</returns>
|
|
|
|
[HttpGet("/TaskManage/GetLaraPaperRecordPage")]
|
|
|
|
[HttpGet("/TaskManage/LaraPaperRecordExport")]
|
|
|
|
public async Task<IActionResult> LaraPaperRecordExport([FromQuery] string sortField,[FromQuery] int pageNo = 1, [FromQuery] int pageSize = 30, [FromQuery] bool descSort = true)
|
|
|
|
public async Task<IActionResult> LaraPaperRecordExport([FromQuery] string sortField,[FromQuery] int pageNo = 1, [FromQuery] int pageSize = 30, [FromQuery] bool descSort = true)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
QueryTaskManageBaseDto querySearch = new QueryTaskManageBaseDto
|
|
|
|
QueryTaskManageBaseDto querySearch = new QueryTaskManageBaseDto
|
|
|
@ -2465,6 +2465,7 @@ namespace Myshipping.Application
|
|
|
|
return new FileStreamResult(ms, "application/vnd.ms-excel") { FileDownloadName = $"{DateTime.Now.ToString("yyyyMMddHHmmss")}_LaraPaperRecord.xls" };
|
|
|
|
return new FileStreamResult(ms, "application/vnd.ms-excel") { FileDownloadName = $"{DateTime.Now.ToString("yyyyMMddHHmmss")}_LaraPaperRecord.xls" };
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#region 导出提单纸登记记录生成Excel
|
|
|
|
/// <summary>
|
|
|
|
/// <summary>
|
|
|
|
/// 导出提单纸登记记录生成Excel
|
|
|
|
/// 导出提单纸登记记录生成Excel
|
|
|
|
/// </summary>
|
|
|
|
/// </summary>
|
|
|
@ -2529,6 +2530,159 @@ namespace Myshipping.Application
|
|
|
|
|
|
|
|
|
|
|
|
return ms;
|
|
|
|
return ms;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
|
|
/// 保存SI信息
|
|
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
|
|
/// <param name="model">订舱信息</param>
|
|
|
|
|
|
|
|
/// <returns>返回结果</returns>
|
|
|
|
|
|
|
|
[HttpPost("/TaskManage/GetSIFeedBackInfo")]
|
|
|
|
|
|
|
|
public async Task<TaskManageOrderResultDto> SaveBookingSI(BookingOrderDto model)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
TaskManageOrderResultDto result = new TaskManageOrderResultDto();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
try
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
catch(Exception ex)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return result;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
|
|
/// 获取SI反馈信息
|
|
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
|
|
/// <param name="taskPKId">任务主键</param>
|
|
|
|
|
|
|
|
/// <returns>返回结果</returns>
|
|
|
|
|
|
|
|
[HttpGet("/TaskManage/GetSIFeedBackInfo")]
|
|
|
|
|
|
|
|
public async Task<TaskSIFeedBackResultDto> GetSIFeedBackInfo(string taskPKId)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
TaskSIFeedBackResultDto model = new TaskSIFeedBackResultDto();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
try
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
var taskInfo = _taskBaseInfoRepository.AsQueryable().First(t => t.PK_ID == taskPKId);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (taskInfo == null)
|
|
|
|
|
|
|
|
Oops.Oh($"任务信息获取失败");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (string.IsNullOrWhiteSpace(taskInfo.BOOK_ORDER_NO))
|
|
|
|
|
|
|
|
Oops.Oh($"任务信息的订舱主键不存在");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (taskInfo.TASK_TYPE != TaskBusiTypeEnum.SI_FEEDBACK.ToString())
|
|
|
|
|
|
|
|
Oops.Oh($"当前任务类型不是{TaskBusiTypeEnum.SI_FEEDBACK.GetDescription()}");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var orderInfo = _bookingOrderRepository.AsQueryable()
|
|
|
|
|
|
|
|
.First(t => t.Id == long.Parse(taskInfo.BOOK_ORDER_NO));
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
model.TaskId = taskInfo.PK_ID;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var siFeedBackList = _taskSIFeedBackInfoRepository.EntityContext.Queryable<TaskSIFeedBackInfo>()
|
|
|
|
|
|
|
|
.InnerJoin<TaskSIFeedBackContaInfo>((si, ctn) => si.PK_ID == ctn.P_PKID)
|
|
|
|
|
|
|
|
.Where((si, ctn) => si.TASK_PKID == model.TaskId && si.TenantId == UserManager.TENANT_ID)
|
|
|
|
|
|
|
|
.Select((si, ctn) => new { si = si, ctn = ctn }).ToList();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (siFeedBackList.Count == 0)
|
|
|
|
|
|
|
|
Oops.Oh($"SI反馈信息不存在");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
var siFeedBackInfo = siFeedBackList.FirstOrDefault().si.Adapt<TaskSIFeedBackResultBusiDto>();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
siFeedBackInfo.ContaList = siFeedBackList.Select(t => t.ctn.Adapt<TaskSIFeedBackResultContaDto>()).ToList();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
model.BusiInfo = siFeedBackInfo;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (orderInfo != null)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
//订舱
|
|
|
|
|
|
|
|
model.BookingOrder = orderInfo.Adapt<TaskBookingOrderDto>();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//进行数据比对确认差异字段KEY
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
catch (Exception ex)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
throw Oops.Bah($"获取获取单票账单详情异常,{0}", ex.Message);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
return model;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// private async Task<string> InnerCompareDiff()
|
|
|
|
|
|
|
|
// {
|
|
|
|
|
|
|
|
// var compareField = new string[] { "SHIPPER", "CONSIGNEE", "NOTIFYPARTY", "MARKS", "DESCRIPTION", "BLFRT", "SERVICE", "ISSUETYPE", "PORTLOAD", "PORTDISCHARGE", "TRANSPORT", "DESTINATION", "PKGS", "KGS", "CBM", "KINDPKGS", "THIRDPAYADDR" };
|
|
|
|
|
|
|
|
// var listDiffField = new List<string>();
|
|
|
|
|
|
|
|
// var bookProps = typeof(OP_SEAE_ORDER).GetProperties();
|
|
|
|
|
|
|
|
// var feedProps = typeof(OP_SEAE_SI_FEEDBACK).GetProperties();
|
|
|
|
|
|
|
|
// foreach (var prop in compareField)
|
|
|
|
|
|
|
|
// {
|
|
|
|
|
|
|
|
// var pBook = bookProps.First(p => p.Name == prop);
|
|
|
|
|
|
|
|
// var bookVal = pBook.GetValue(bill.order);
|
|
|
|
|
|
|
|
// var pFeed = feedProps.First(p => p.Name == prop);
|
|
|
|
|
|
|
|
// var feedVal = pFeed.GetValue(siFeedback);
|
|
|
|
|
|
|
|
// if (pBook.PropertyType == typeof(string))
|
|
|
|
|
|
|
|
// {
|
|
|
|
|
|
|
|
// string st1 = bookVal as string;
|
|
|
|
|
|
|
|
// string st2 = feedVal as string;
|
|
|
|
|
|
|
|
// st1 = ProcessString(st1);
|
|
|
|
|
|
|
|
// st2 = ProcessString(st2);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// if (st1 != st2)
|
|
|
|
|
|
|
|
// {
|
|
|
|
|
|
|
|
// listDiffField.Add(prop);
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// else if (pBook.PropertyType == typeof(int?))
|
|
|
|
|
|
|
|
// {
|
|
|
|
|
|
|
|
// var dt1 = bookVal as int?;
|
|
|
|
|
|
|
|
// var dt2 = feedVal as int?;
|
|
|
|
|
|
|
|
// if (dt1 != dt2)
|
|
|
|
|
|
|
|
// {
|
|
|
|
|
|
|
|
// listDiffField.Add(prop);
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// else if (pBook.PropertyType == typeof(decimal?))
|
|
|
|
|
|
|
|
// {
|
|
|
|
|
|
|
|
// var dt1 = bookVal as decimal?;
|
|
|
|
|
|
|
|
// var dt2 = feedVal as decimal?;
|
|
|
|
|
|
|
|
// if (dt1 != dt2)
|
|
|
|
|
|
|
|
// {
|
|
|
|
|
|
|
|
// listDiffField.Add(prop);
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// ViewData["DiffFields"] = listDiffField;
|
|
|
|
|
|
|
|
//#endregion
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// #region 箱信息对比
|
|
|
|
|
|
|
|
// var listDiffCtn = new List<string>();
|
|
|
|
|
|
|
|
// var ctns = bookingDB.Ctns.Where(c => c.ORDNO == bill.order.ORDNO).ToList();
|
|
|
|
|
|
|
|
// foreach (var cc in feedbackCtn)
|
|
|
|
|
|
|
|
// {
|
|
|
|
|
|
|
|
// var ctnB = ctns.FirstOrDefault(c => c.CNTRNO == cc.CNTRNO);
|
|
|
|
|
|
|
|
// if (ctnB == null)
|
|
|
|
|
|
|
|
// {
|
|
|
|
|
|
|
|
// listDiffCtn.Add(cc.CNTRNO);
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// else
|
|
|
|
|
|
|
|
// {
|
|
|
|
|
|
|
|
// if (cc.KGS != ctnB.KGS
|
|
|
|
|
|
|
|
// || cc.PKGS != ctnB.PKGS
|
|
|
|
|
|
|
|
// || cc.SEALNO != ctnB.SEALNO
|
|
|
|
|
|
|
|
// || cc.CTNALL != ctnB.CTNALL
|
|
|
|
|
|
|
|
// || cc.CBM != ctnB.CBM)
|
|
|
|
|
|
|
|
// {
|
|
|
|
|
|
|
|
// listDiffCtn.Add(cc.CNTRNO);
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// ViewData["DiffCtns"] = listDiffCtn;
|
|
|
|
|
|
|
|
// }
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
#region 样本业务提取帮助类
|
|
|
|
#region 样本业务提取帮助类
|
|
|
|