From b4458d30bb1a2f9360cd9fb75c7feda182908692 Mon Sep 17 00:00:00 2001 From: jianghaiqing Date: Fri, 19 Jan 2024 15:53:52 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E8=88=B1=E4=BD=8D=E6=8E=A5?= =?UTF-8?q?=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Service/BookingSlot/BookingSlotService.cs | 4 ++-- .../TaskManagePlat/TaskManageBCService.cs | 16 +++++++++++++++- 2 files changed, 17 insertions(+), 3 deletions(-) diff --git a/Myshipping.Application/Service/BookingSlot/BookingSlotService.cs b/Myshipping.Application/Service/BookingSlot/BookingSlotService.cs index 2b41d2ca..84e30e0c 100644 --- a/Myshipping.Application/Service/BookingSlot/BookingSlotService.cs +++ b/Myshipping.Application/Service/BookingSlot/BookingSlotService.cs @@ -220,8 +220,8 @@ namespace Myshipping.Application { bcNoticeFile = new DynameFileInfo { - FileBytes = file.ToByteArray(), - FileName = file.FileName + FileBytes = modifyFile.ToByteArray(), + FileName = modifyFile.FileName }; } diff --git a/Myshipping.Application/Service/TaskManagePlat/TaskManageBCService.cs b/Myshipping.Application/Service/TaskManagePlat/TaskManageBCService.cs index 7aff35cc..2eede93c 100644 --- a/Myshipping.Application/Service/TaskManagePlat/TaskManageBCService.cs +++ b/Myshipping.Application/Service/TaskManagePlat/TaskManageBCService.cs @@ -687,7 +687,16 @@ namespace Myshipping.Application { #region 推送舱位、推送订舱 //推送舱位 - var bookingSlotId = await GenerateBookingSlot(bcOrder, bcCtnList, fileList); + long bookingSlotId = 0; + + if(bcOrder.BOOKING_SLOT_ID.HasValue && bcOrder.BOOKING_SLOT_ID.Value > 0) + { + bookingSlotId = bcOrder.BOOKING_SLOT_ID.Value; + } + else + { + bookingSlotId = await GenerateBookingSlot(bcOrder, bcCtnList, fileList); + } if (bookingSlotId > 0) { @@ -696,6 +705,7 @@ namespace Myshipping.Application if (bookingOrderId > 0) { + //更新库存 //_bookingSlotService. var bcEntity = _taskBCInfoRepository.AsQueryable().First(a => a.PK_ID == bcOrder.PK_ID); @@ -722,6 +732,10 @@ namespace Myshipping.Application }).ExecuteCommand(); + var currBCOrder = _taskBCInfoRepository.AsQueryable().First(a => a.PK_ID == bcEntity.PK_ID); + + if (currBCOrder != null) + await GenerateSendEmail(currBCOrder); var taskEntity = _taskBaseRepository.AsQueryable().First(u => u.PK_ID == bcEntity.TASK_ID);