jianghaiqing 1 year ago
commit 557248a62f

@ -54,7 +54,11 @@ namespace Myshipping.Application
[HttpPost("/BookingYunZong/RefreshYunZong")]
public async Task RefreshYunZong(long[] Ids)
{
var order = await _rep.AsQueryable().Filter(null, true).Where(x => Ids.Contains(x.Id)).ToListAsync();
var order = await _rep.AsQueryable().Filter(null, true).Where(x => Ids.Contains(x.Id)&&x.IsDeleted==false&&x.ParentId==0&&x.IsBookingYZ!="0").ToListAsync();
if (order==null|| order.Count==0) {
throw Oops.Bah("存在未订阅单据");
}
var key = _cache.GetAllSysConfig().Result.Where(x => x.Code == "billTraceNewUserKey").Select(x => x.Value).FirstOrDefault();
if (string.IsNullOrEmpty(key))
{
@ -160,7 +164,7 @@ namespace Myshipping.Application
var mblno = item.GetValue("bno").ToString();
var bookingId = await _rep.AsQueryable().Filter(null, true).Where(x => x.MBLNO == mblno).Select(x => x.Id).FirstAsync();
var bookingId = await _rep.AsQueryable().Filter(null, true).Where(x => x.MBLNO == mblno&&x.IsDeleted==false&&x.ParentId==0).Select(x => x.Id).FirstAsync();
var jarrInnerData = item.GetValue("data") as JArray;
List<YardDataDto> yarddto = new List<YardDataDto>();
@ -262,7 +266,7 @@ namespace Myshipping.Application
var mblno = item.GetValue("bno").ToString();
var bookingId = await _rep.AsQueryable().Filter(null, true).Where(x => x.MBLNO == mblno).Select(x => x.Id).FirstAsync();
var bookingId = await _rep.AsQueryable().Filter(null, true).Where(x => x.MBLNO == mblno && x.IsDeleted == false && x.ParentId == 0).Select(x => x.Id).FirstAsync();
var list = await _repBookingStatus.AsQueryable().Filter(null, true).InnerJoin<SysDictData>((d, t) => d.StaCode == t.Code && d.StaCate == "book_sta_cate_billtrace" && d.BookingId == bookingId).Select((d, t) => new
{
BookingId = d.BookingId,
@ -357,7 +361,7 @@ namespace Myshipping.Application
//每票 货物
var mblno = item.GetValue("bno").ToString();
var bookingOrder = await _rep.AsQueryable().Filter(null, true).Where(x => x.MBLNO == mblno && x.IsDeleted == false).FirstAsync();
var bookingOrder = await _rep.AsQueryable().Filter(null, true).Where(x => x.MBLNO == mblno && x.IsDeleted == false && x.ParentId == 0).FirstAsync();
var list = await _repBookingStatus.AsQueryable().Filter(null, true).InnerJoin<SysDictData>((d, t) => d.StaCode == t.Code && d.StaCate == "book_sta_cate_billtrace" && d.BookingId == bookingOrder.Id).Select((d, t) => new
{
BookingId = d.BookingId,

Loading…
Cancel
Save