|
|
|
@ -182,35 +182,54 @@ namespace Myshipping.Application
|
|
|
|
|
{
|
|
|
|
|
//校验
|
|
|
|
|
ValidateTruck(OperateTypeEnum.Save, new BookingTruck[] { model });
|
|
|
|
|
|
|
|
|
|
entity.UpdatedTime = DateTime.Now;
|
|
|
|
|
entity.UpdatedUserId = UserManager.UserId;
|
|
|
|
|
entity.UpdatedUserName = UserManager.Name;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
await _bookingTruckRepository.AsUpdateable(entity).IgnoreColumns(it => new
|
|
|
|
|
{
|
|
|
|
|
it.TenantId,
|
|
|
|
|
it.CreatedTime,
|
|
|
|
|
it.CreatedUserId,
|
|
|
|
|
it.CreatedUserName,
|
|
|
|
|
it.IsDeleted,
|
|
|
|
|
it.BookingId,
|
|
|
|
|
it.TruckId,
|
|
|
|
|
it.TruckName,
|
|
|
|
|
it.TruckCode,
|
|
|
|
|
it.Status,
|
|
|
|
|
it.TruckFlowNo,
|
|
|
|
|
it.TaskNo
|
|
|
|
|
}).ExecuteCommandAsync();
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
ValidateTruck(OperateTypeEnum.DispatchBackSave, new BookingTruck[] { model });
|
|
|
|
|
|
|
|
|
|
entity.Status = BookingTruckStatus.SEND_DISPATCH.ToString();
|
|
|
|
|
|
|
|
|
|
entity.UpdatedTime = DateTime.Now;
|
|
|
|
|
entity.UpdatedUserId = UserManager.UserId;
|
|
|
|
|
entity.UpdatedUserName = UserManager.Name;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
await _bookingTruckRepository.AsUpdateable(entity).IgnoreColumns(it => new
|
|
|
|
|
{
|
|
|
|
|
it.TenantId,
|
|
|
|
|
it.CreatedTime,
|
|
|
|
|
it.CreatedUserId,
|
|
|
|
|
it.CreatedUserName,
|
|
|
|
|
it.IsDeleted,
|
|
|
|
|
it.BookingId,
|
|
|
|
|
it.TruckFlowNo,
|
|
|
|
|
it.TaskNo
|
|
|
|
|
}).ExecuteCommandAsync();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
entity.UpdatedTime = DateTime.Now;
|
|
|
|
|
entity.UpdatedUserId = UserManager.UserId;
|
|
|
|
|
entity.UpdatedUserName = UserManager.Name;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
await _bookingTruckRepository.AsUpdateable(entity).IgnoreColumns(it => new
|
|
|
|
|
{
|
|
|
|
|
it.TenantId,
|
|
|
|
|
it.CreatedTime,
|
|
|
|
|
it.CreatedUserId,
|
|
|
|
|
it.CreatedUserName,
|
|
|
|
|
it.IsDeleted,
|
|
|
|
|
it.BookingId,
|
|
|
|
|
it.TruckId,
|
|
|
|
|
it.TruckName,
|
|
|
|
|
it.TruckCode,
|
|
|
|
|
it.Status,
|
|
|
|
|
it.TruckFlowNo,
|
|
|
|
|
it.TaskNo
|
|
|
|
|
}).ExecuteCommandAsync();
|
|
|
|
|
|
|
|
|
|
await _bookingTruckContaRepository.DeleteAsync(x => x.TruckId == model.Id);
|
|
|
|
|
|
|
|
|
|
if (entityCtnList != null && entityCtnList.Count > 0)
|
|
|
|
|