|
|
|
@ -190,11 +190,10 @@ namespace Myshipping.Application
|
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
throw Oops.Bah("当前提单号已存在,请勿重复录入!");
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
var entity = model.Adapt<BookingOrder>();
|
|
|
|
|
entity.CreatedUserId = user.Result.Id;
|
|
|
|
|
entity.CreatedUserName = user.Result.Name;
|
|
|
|
|
entity.CreatedUserName = user.Result.Name.ToString();
|
|
|
|
|
entity.CreatedTime = DateTime.Now;
|
|
|
|
|
entity.ParentId =0;
|
|
|
|
|
await _rep.InsertAsync(entity);
|
|
|
|
@ -204,6 +203,8 @@ namespace Myshipping.Application
|
|
|
|
|
{
|
|
|
|
|
var ctnentity = item.Adapt<BookingCtn>();
|
|
|
|
|
ctnentity.BILLID = entity.Id;
|
|
|
|
|
ctnentity.CreatedUserId = user.Result.Id;
|
|
|
|
|
ctnentity.CreatedUserName = user.Result.Name;
|
|
|
|
|
await _repCtn.InsertAsync(ctnentity);
|
|
|
|
|
|
|
|
|
|
//这里保存有可能没有添加多品名,所有箱下没有货物信息
|
|
|
|
@ -213,6 +214,8 @@ namespace Myshipping.Application
|
|
|
|
|
{
|
|
|
|
|
var ctndetail = it.Adapt<BookingCtnDetail>();
|
|
|
|
|
ctndetail.CTNID = ctnentity.Id;
|
|
|
|
|
ctndetail.CreatedUserId = user.Result.Id;
|
|
|
|
|
ctndetail.CreatedUserName = user.Result.Name;
|
|
|
|
|
await _ctndetailrep.InsertAsync(ctndetail);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -229,6 +232,8 @@ namespace Myshipping.Application
|
|
|
|
|
ediExtEntity.CreatedUserId = user.Result.Id;
|
|
|
|
|
ediExtEntity.CreatedUserName = user.Result.Name;
|
|
|
|
|
ediExtEntity.CreatedTime = DateTime.Now;
|
|
|
|
|
ediExtEntity.CreatedUserId = user.Result.Id;
|
|
|
|
|
ediExtEntity.CreatedUserName = user.Result.Name;
|
|
|
|
|
await _bookingEDIExt.InsertAsync(ediExtEntity);
|
|
|
|
|
}
|
|
|
|
|
////添加booking日志
|
|
|
|
@ -283,6 +288,8 @@ namespace Myshipping.Application
|
|
|
|
|
{
|
|
|
|
|
var ctnentity = item.Adapt<BookingCtn>();
|
|
|
|
|
ctnentity.BILLID = fdentity.Id;
|
|
|
|
|
ctnentity.CreatedUserId = user.Result.Id;
|
|
|
|
|
ctnentity.CreatedUserName = user.Result.Name;
|
|
|
|
|
await _repCtn.InsertAsync(ctnentity);
|
|
|
|
|
|
|
|
|
|
//这里保存有可能没有添加多品名,所有箱下没有货物信息
|
|
|
|
@ -292,6 +299,9 @@ namespace Myshipping.Application
|
|
|
|
|
{
|
|
|
|
|
var ctndetail = dit.Adapt<BookingCtnDetail>();
|
|
|
|
|
ctndetail.CTNID = ctnentity.Id;
|
|
|
|
|
ctndetail.CreatedUserId = user.Result.Id;
|
|
|
|
|
ctndetail.CreatedUserName = user.Result.Name;
|
|
|
|
|
|
|
|
|
|
await _ctndetailrep.InsertAsync(ctndetail);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -376,6 +386,8 @@ namespace Myshipping.Application
|
|
|
|
|
{
|
|
|
|
|
var ctnentity = item.Adapt<BookingCtn>();
|
|
|
|
|
ctnentity.BILLID = main.Id;
|
|
|
|
|
ctnentity.CreatedUserId = user.Result.Id;
|
|
|
|
|
ctnentity.CreatedUserName = user.Result.Name;
|
|
|
|
|
await _repCtn.InsertAsync(ctnentity);
|
|
|
|
|
if (item.ctnDetailInputs != null)
|
|
|
|
|
{
|
|
|
|
@ -383,6 +395,9 @@ namespace Myshipping.Application
|
|
|
|
|
{
|
|
|
|
|
var ctndetail = it.Adapt<BookingCtnDetail>();
|
|
|
|
|
ctndetail.CTNID = ctnentity.Id;
|
|
|
|
|
ctndetail.CreatedUserId = user.Result.Id;
|
|
|
|
|
ctndetail.CreatedUserName = user.Result.Name;
|
|
|
|
|
|
|
|
|
|
await _ctndetailrep.InsertAsync(ctndetail);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -410,7 +425,8 @@ namespace Myshipping.Application
|
|
|
|
|
var currEdiExtEntity = model.BookingEDIExt.Adapt<BookingEDIExt>();
|
|
|
|
|
|
|
|
|
|
currEdiExtEntity.Id = ediExtEntity.Id;
|
|
|
|
|
|
|
|
|
|
currEdiExtEntity.UpdatedUserId = user.Result.Id;
|
|
|
|
|
currEdiExtEntity.UpdatedTime = DateTime.Now;
|
|
|
|
|
await _bookingEDIExt.AsUpdateable(currEdiExtEntity).IgnoreColumns(it => new
|
|
|
|
|
{
|
|
|
|
|
it.BookingId,
|
|
|
|
@ -518,6 +534,8 @@ namespace Myshipping.Application
|
|
|
|
|
{
|
|
|
|
|
var ctnentity = item.Adapt<BookingCtn>();
|
|
|
|
|
ctnentity.BILLID = fdmain.Id;
|
|
|
|
|
ctnentity.CreatedUserId = user.Result.Id;
|
|
|
|
|
ctnentity.CreatedUserName = user.Result.Name;
|
|
|
|
|
await _repCtn.InsertAsync(ctnentity);
|
|
|
|
|
if (it.ctnDetailInputs != null)
|
|
|
|
|
{
|
|
|
|
@ -525,6 +543,8 @@ namespace Myshipping.Application
|
|
|
|
|
{
|
|
|
|
|
var ctndetail = it_.Adapt<BookingCtnDetail>();
|
|
|
|
|
ctndetail.CTNID = ctnentity.Id;
|
|
|
|
|
ctndetail.CreatedUserId = user.Result.Id;
|
|
|
|
|
ctndetail.CreatedUserName = user.Result.Name;
|
|
|
|
|
await _ctndetailrep.InsertAsync(ctndetail);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -548,6 +568,8 @@ namespace Myshipping.Application
|
|
|
|
|
{
|
|
|
|
|
var ctnentity = item.Adapt<BookingCtn>();
|
|
|
|
|
ctnentity.BILLID = fdentity.Id;
|
|
|
|
|
ctnentity.CreatedUserId = user.Result.Id;
|
|
|
|
|
ctnentity.CreatedUserName = user.Result.Name;
|
|
|
|
|
await _repCtn.InsertAsync(ctnentity);
|
|
|
|
|
|
|
|
|
|
//这里保存有可能没有添加多品名,所有箱下没有货物信息
|
|
|
|
@ -557,6 +579,8 @@ namespace Myshipping.Application
|
|
|
|
|
{
|
|
|
|
|
var ctndetail = dit.Adapt<BookingCtnDetail>();
|
|
|
|
|
ctndetail.CTNID = ctnentity.Id;
|
|
|
|
|
ctndetail.CreatedUserId = user.Result.Id;
|
|
|
|
|
ctndetail.CreatedUserName = user.Result.Name;
|
|
|
|
|
await _ctndetailrep.InsertAsync(ctndetail);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|