Browse Source

托书/预托书回写调整

fenghaifu 1 day ago
parent
commit
6c3c80d3f7

+ 3 - 0
jeecg-boot-module-system/src/main/java/org/jeecg/modules/quartz/job/PushShippingDetailsJob.java

@@ -171,6 +171,9 @@ public class PushShippingDetailsJob implements Job {
                     List<ReqShippingOrderItemVO> reqVoList = new ArrayList<>();
                     for (SyShippingOrderItem item : itemList){
                         SyShippingOrder findOrder = orderList.stream().filter(x -> x.getId().equals(item.getSyShippingOrderItemId())).findFirst().orElse(null);
+                        if ("0".equals(findOrder.getTheDocumentsState())){
+                            continue;
+                        }
                         if (findOrder != null){
                             ReqShippingOrderItemVO reqVo = new ReqShippingOrderItemVO();
                             reqVo.fromShippingOrder(item, findOrder);

+ 7 - 5
jeecg-boot-module-system/src/main/java/org/jeecg/modules/spapl/service/impl/SyPreAssembledPackingListServiceImpl.java

@@ -1505,7 +1505,7 @@ public class SyPreAssembledPackingListServiceImpl extends ServiceImpl<SyPreAssem
 	 */
 	@Override
 	@Transactional
-	public synchronized RespUpdateVO saveSrmBill(SyPreAssembledPackingList syPreAssembledPackingList) {
+	public RespUpdateVO saveSrmBill(SyPreAssembledPackingList syPreAssembledPackingList) {
 		RespUpdateVO respUpdateVO = new RespUpdateVO();
 		respUpdateVO.setSuccess(false);
 		respUpdateVO.setExtraInfo("");
@@ -1524,6 +1524,9 @@ public class SyPreAssembledPackingListServiceImpl extends ServiceImpl<SyPreAssem
 				syPreAssembledPackingList.setSyOrderDataId(syShippingDetails.getSyOrderDataId());
 			}
 		}
+		SyShippingDetailsItem syItem=syShippingDetailsItemMapper.selectById(items.get(0).getSizeTables().get(0).getItemId());
+		syPreAssembledPackingList.setElementsId(syItem.getElementsId());
+		syPreAssembledPackingList.setIsTc(syItem.getIsTc());
 		syPreAssembledPackingListMapper.insert(syPreAssembledPackingList);//往主表添加数据
 		if(syPreAssembledPackingList.getSyPreAssembledPackingListItemList()!=null){
 			//BigDecimal box=add(syPreAssembledPackingList.getSyPreAssembledPackingListItemList(),syPreAssembledPackingList.getId());
@@ -1560,11 +1563,10 @@ public class SyPreAssembledPackingListServiceImpl extends ServiceImpl<SyPreAssem
 					item1.setSort(size.getNum());//获取序号
 					item1.setId(oConvertUtils.id());//获取到随机id
 					//获取发育明细数据
-					SyShippingDetailsItem syItem=syShippingDetailsItemMapper.selectById(item1.getSyDeclarationElementsItemId());
+					syItem=syShippingDetailsItemMapper.selectById(item1.getSyDeclarationElementsItemId());
 					syItem.setIsReference(1);//修改成被参照
 					syShippingDetailsItemMapper.updateById(syItem);
-					syPreAssembledPackingList.setElementsId(syItem.getElementsId());
-					syPreAssembledPackingList.setIsTc(syItem.getIsTc());
+
 					item1.setPackId(syItem.getPackId());
 					item1.setOmpoIdItem(syItem.getOmpoIdItem());//获取委外/采购订单子表Id
 					item1.setOmpoId(syItem.getOmpoId());//获取委外/采购订单主表Id
@@ -1600,7 +1602,7 @@ public class SyPreAssembledPackingListServiceImpl extends ServiceImpl<SyPreAssem
 			for (String key : maps.keySet()){
 				//updateQuantity(maps.get(key),key);
 			}
-			syPreAssembledPackingListMapper.updateById(syPreAssembledPackingList);
+			//syPreAssembledPackingListMapper.updateById(syPreAssembledPackingList);
 			respUpdateVO.setMessage(syPreAssembledPackingList.getId());
 			respUpdateVO.setSuccess(true);
 		}else{

+ 1 - 1
jeecg-boot-module-system/src/main/java/org/jeecg/modules/splfi/controller/SyPackingListFabricController.java

@@ -1864,7 +1864,7 @@ public class SyPackingListFabricController implements Job {
 				 fabricItem.setOrderNumber(findExtraInfo.getOrderNumber());
 				 fabricItem.setElementsId(findExtraInfo.getElementsId());
 				 fabricItem.setFactoryUnitPrice(findExtraInfo.getFactoryUnitPrice());
-				 fabricItem.setTotalPrice(fabricItem.getPrice().multiply(fabricItem.getActualPackingQty()));
+				 fabricItem.setTotalPrice(fabricItem.getPrice().multiply(fabricItem.getInventoryQuantity()));
 				 fabricItem.setCustomsDeclarationUnitPrice(findExtraInfo.getCustomsDeclarationUnitPrice());
 				 fabricItem.setOmpoAccount(findExtraInfo.getOmpoAccount());
 				 fabricItem.setOmpoIdItem(findExtraInfo.getOmpoIdItem());