optimize
wet 2 years ago
parent 692350b594
commit 83803524b3

@ -324,16 +324,21 @@ namespace Myshipping.Application
var list = entities.Adapt<SqlSugarPagedList<PageBookingOrder>>();
var status = _repBookingStatus.AsQueryable();
var remark = _bookingremark.AsQueryable();
var status = await _repBookingStatus.AsQueryable().ToListAsync();
var remark = await _bookingremark.AsQueryable().ToListAsync();
foreach (var item in list.Items)
{
var sta = await status.Where(x => x.BookingId == item.Id).ToListAsync();
if (sta != null) { item.bookstatus = sta; }
var st = await remark.Where(x => x.PId == item.Id).ToListAsync();
if (st != null) { item.bookremark = st; }
var sta = status.Where(x => x.BookingId == item.Id).ToList();
if (sta != null) {
item.bookstatus = sta;
}
var st = remark.Where(x => x.PId == item.Id).ToList();
if (st != null) {
item.bookremark = st;
}
if (!string.IsNullOrWhiteSpace(item.ETD))
{
item.ETD = Convert.ToDateTime(item.ETD).ToString("yyyy-MM-dd");
@ -4810,9 +4815,6 @@ namespace Myshipping.Application
{
return allData;
}
//服务项目
var itemlist = await _serviceItem.AsQueryable().Where(x => x.BookingId == bookingId).ToListAsync();
allData.item = itemlist;
@ -4823,10 +4825,10 @@ namespace Myshipping.Application
var statuslog = await _repStatuslog.AsQueryable().Filter(null, true).Where(x => x.BookingId == bookingId).OrderByDescending(x => x.OpTime).ToListAsync();
var dto = statuslog.Adapt<List<BookingStatusLogDto>>();
var statuslogdetail = _statuslogdetail.AsQueryable();
var statuslogdetail = await _statuslogdetail.AsQueryable().ToListAsync();
foreach (var item in dto)
{
var detail =await statuslogdetail.Where(x => x.PId == item.Id).ToListAsync();
var detail = statuslogdetail.Where(x => x.PId == item.Id).ToList();
item.detail = detail.Adapt<List<BookingStatusLogDetailDto>>();
}
allData.statuslog = dto;
@ -4836,10 +4838,10 @@ namespace Myshipping.Application
list = main.Adapt<List<BookingLogDto>>();
if (list != null)
{
var bookinglogdetail = _bookinglogdetail.AsQueryable() ;
var bookinglogdetail = await _bookinglogdetail.AsQueryable().ToListAsync() ;
foreach (var item in list)
{
var details = await bookinglogdetail.Where(x => x.PId == item.Id).ToListAsync();
var details = bookinglogdetail.Where(x => x.PId == item.Id).ToList();
item.details = details;
}
}

@ -10467,6 +10467,11 @@
美元账号
</summary>
</member>
<member name="P:Myshipping.Core.Service.QueryDjyCustomerInput.ServiceItem">
<summary>
服务项目
</summary>
</member>
<member name="T:Myshipping.Core.Service.DjyCustomerOutput">
<summary>
客户输出参数

Loading…
Cancel
Save