浏览代码

托书,预托书调整

zengtx 2 年之前
父节点
当前提交
6d70630350

+ 7 - 8
jeecg-boot-module-system/src/main/java/org/jeecg/modules/documents/letterDeposit/mapper/xml/SyLetterDepositMapper.xml

@@ -96,21 +96,21 @@ a.create_time as createTime,b.unit_price as unitPrice,sum(b.total_price) as tota
 
     <select id="queryItem" resultType="org.jeecg.modules.documents.letterDeposit.entity.SyLetterDepositItem">
 
-        select item_number as itemNumber,small_po as smallPo,sum(total) as total,box_number as boxNumber,pre_ids as syPreAssembledPackingListItemId,sy_pre_assembled_packing_list_id as syPreAssembledPackingListId,
-total_gross_weight as totalGrossWeight,total_net_weight as totalNetWeight,total_volume as totalVolume,distribution_point as distributionPoint,
+  select itemNumber,smallPo,sum(total) as total,sum(boxNumber) as boxNumber,syPreAssembledPackingListItemId,syPreAssembledPackingListId,sum(totalGrossWeight) as totalGrossWeight,sum(totalNetWeight) as totalNetWeight,sum(totalVolume) as totalVolume,distributionPoint,containerCode,containerNumber,unitPrice,sum(totalPrice) as totalPrice,hod,salesman,salesDepartment,spurOrSubOrder,supplier,clientAbbreviation from (select item_number as itemNumber,small_po as smallPo,sum(total) as total,box_number as boxNumber,GROUP_CONCAT(sy_pre_assembled_packing_list_item_id) as syPreAssembledPackingListItemId,sy_pre_assembled_packing_list_id as syPreAssembledPackingListId,
+total_gross_weight as totalGrossWeight,total_net_weight as totalNetWeight,total_volume as totalVolume,distribution_point as distributionPoint,letter_groupid as letterGroupid,
 container_code as containerCode,container_number as containerNumber,unit_price as unitPrice,sum(total_price) as totalPrice,
 hod,salesman,sales_Department as salesDepartment,spur_or_sub_order as spurOrSubOrder,supplier,client_abbreviation as clientAbbreviation
          from sy_letter_deposit_item
-         where del_flag = 0 and sy_letter_deposit_id = #{syId} group by letter_groupid order by item_number,small_po desc
-
+         where del_flag = 0 and sy_letter_deposit_id = #{syId} group by groupid order by item_number,small_po desc) t GROUP BY letterGroupid
 
     </select>
 
     <select id="printItem" resultType="org.jeecg.modules.documents.letterDeposit.entity.SyLetterDepositItem">
 
-         select a.item_number as itemNumber,a.small_po as smallPo,round(sum(a.total),2) as total,round(a.box_number,0) as boxNumber,
+         select itemNumber,sum(boxNumber) as boxNumber,smallPo,total,sum(totalGrossWeight) as totalGrossWeight,sum(totalNetWeight) as totalNetWeight,sum(totalVolume) as totalVolume,containerCode,containerNumber,unitPrice,sum(totalPrice) as totalPrice,hod,salesman,salesDepartment,spurOrSubOrder,supplier,englishName,pcs,ctns,kgs,cbm from(
+ select a.item_number as itemNumber,a.small_po as smallPo,round(sum(a.total),2) as total,round(a.box_number,0) as boxNumber,
 round(a.total_gross_weight,2) as totalGrossWeight,round(a.total_net_weight,2) as totalNetWeight,round(a.total_volume,3) as totalVolume,
-a.container_code as containerCode,a.container_number as containerNumber,a.unit_price as unitPrice,sum(a.total_price) as totalPrice,
+a.container_code as containerCode,a.container_number as containerNumber,a.unit_price as unitPrice,sum(a.total_price) as totalPrice,letter_groupid as letterGroupid,
 a.hod,a.salesman,a.sales_Department as salesDepartment,a.spur_or_sub_order as spurOrSubOrder,a.supplier,
 c.english_product_name as englishName,'PCS' as pcs, 'CTNS' as ctns,'KGS' as kgs,'CBM' as cbm
          from sy_letter_deposit_item a
@@ -118,7 +118,6 @@ c.english_product_name as englishName,'PCS' as pcs, 'CTNS' as ctns,'KGS' as kgs,
          on a.sy_pre_assembled_packing_list_id = b.id
          left join sy_declaration_elements c
          on b.elements_id = c.id
-         where a.del_flag = 0 and a.sy_letter_deposit_id = #{id} group by letter_groupid  order by a.item_number,a.small_po desc
-
+         where a.del_flag = 0 and a.sy_letter_deposit_id = #{id}  group by groupid  order by a.item_number,a.small_po desc) t GROUP BY t.letterGroupid
     </select>
 </mapper>

+ 3 - 3
jeecg-boot-module-system/src/main/java/org/jeecg/modules/documents/shippingDetails/controller/SyShippingDetailsController.java

@@ -1365,7 +1365,7 @@ public class SyShippingDetailsController extends JeecgController<SyShippingDetai
 
 
 	 /**
-	  * 通过hscode查询最近一次报关要素
+	  * 通过hscode查询最近一次报关要素(2023.1.10更改为 按照报关品名查询)
 	  * @param hscode
 	  * @param request
 	  * @param response
@@ -1378,12 +1378,12 @@ public class SyShippingDetailsController extends JeecgController<SyShippingDetai
 		 Result<SyDeclarationElements> result = new Result<SyDeclarationElements>();
 
 		 if(oConvertUtils.isEmpty(hscode)){
-			 result.setMessage("HSCODE未填写,请输入!");
+			 result.setMessage("报关品名未填写,请输入!");
 			 result.setSuccess(false);
 			 return result;
 		 }
 	 	QueryWrapper<SyDeclarationElements> queryWrapper = new QueryWrapper<>();
-		 queryWrapper.eq("hs_code",hscode).eq("del_flag",0).orderByDesc("create_time");
+		 queryWrapper.eq("declaration_name",hscode).eq("del_flag",0).orderByDesc("create_time");
 		 List<SyDeclarationElements> list = syDeclarationElementsService.list(queryWrapper);
 		 if(list.size()!=0){
 			 SyDeclarationElements entity = list.get(0);

+ 1 - 1
jeecg-boot-module-system/src/main/java/org/jeecg/modules/documents/syShippingOrder/controller/SyShippingOrderController.java

@@ -1343,7 +1343,7 @@ public class SyShippingOrderController extends JeecgController<SyShippingOrder,
 					 li.put("orderId", fabricEntity.getSyOrderDataId());//  = syShippingOrderMapper.querySOMain(tailoringEntity.getSyOrderDataId());
 				 } else {
 					 result.setResult(0);
-					 result.setMessage("推送失败!请联系管理员");
+					 result.setMessage("推送失败!未找到订单相关信息!");
 					 result.setSuccess(false);
 					 return result;
 				 }

+ 1 - 1
jeecg-boot-module-system/src/main/java/org/jeecg/modules/documents/syShippingOrder/mapper/xml/SyShippingOrderMapper.xml

@@ -7,7 +7,7 @@
   b.distribution_point as distributionPoint,a.unit_in_operation as unitInOperation,a.box_number as boxNumber,b.garment_factory as garmentFactory,
   a.total_gross_weight as totalGrossWeight,case when b.ready_fabric != '成衣' then b.volume else a.total_volume end as totalVolume,b.box_number as planQuantity,b.client_abbreviation as clientAbbreviation,
   a.money,a.the_actual_shipping_date as theActualShippingDate,a.exchange_earnings_text as exchangeEarningsText,a.ready_fabric as readyFabric,
-  a.consignee,a.bill_of_lading_or_carriage_receipt as billOfLadingOrCarriageReceipt,a.the_final_shipping_date as theFinalShippingDate,
+  a.consignee,a.bill_of_lading_or_carriage_receipt as billOfLadingOrCarriageReceipt,a.the_final_shipping_date as theFinalShippingDate,a.sy_stuta as syStuta,
   a.addressee,a.trade_country as tradeCountry,a.arrive_in_country as arriveInCountry,a.export_port as exportPort,
   a.notifier,a.nottfy,a.destination_port as destinationPort,a.latest_date_of_shipment as latestDateOfShipment,a.the_documents_state as theDocumentsState
   from sy_shipping_order a

+ 4 - 4
jeecg-boot-module-system/src/main/java/org/jeecg/modules/documents/syShippingOrder/service/impl/SyShippingOrderServiceImpl.java

@@ -227,7 +227,7 @@ public class SyShippingOrderServiceImpl extends ServiceImpl<SyShippingOrderMappe
                     syPackingListFabric.setExportInvoiceNo(syShippingOrder.getShippingOrderNumber());
                     syPackingListFabric.setIsReference(1);
                     syPackingListFabric.setShippingOrderNumber(syShippingOrder.getShippingOrderNumber());
-                    syPackingListFabric.setContainerCode(li.getContainerCode());
+                    //syPackingListFabric.setContainerCode(li.getContainerCode());
                     syPackingListFabric.setContainerNumber(li.getContainerNumber());
 
                     syPackingListFabricService.updateById(syPackingListFabric);
@@ -296,7 +296,7 @@ public class SyShippingOrderServiceImpl extends ServiceImpl<SyShippingOrderMappe
                     syPackingListTailoring.setExportInvoiceNo(syShippingOrder.getShippingOrderNumber());
                     syPackingListTailoring.setIsReference(1);
                     syPackingListTailoring.setShippingOrderNumber(syShippingOrder.getShippingOrderNumber());
-                    syPackingListTailoring.setContainerCode(li.getContainerCode());
+                    //syPackingListTailoring.setContainerCode(li.getContainerCode());
                     syPackingListTailoring.setContainerNumber(li.getContainerNumber());
                     syPackingListTailoringService.updateById(syPackingListTailoring);
 
@@ -373,7 +373,7 @@ public class SyShippingOrderServiceImpl extends ServiceImpl<SyShippingOrderMappe
                 syPackingListFabric.setIsReference(0);
                 syPackingListFabric.setShippingOrderNumber("");
                 syPackingListFabric.setExportInvoiceNo("");
-                syPackingListFabric.setContainerCode("");
+                //syPackingListFabric.setContainerCode("");
                 syPackingListFabric.setContainerNumber("");
                 syPackingListFabricService.updateById(syPackingListFabric);
 
@@ -386,7 +386,7 @@ public class SyShippingOrderServiceImpl extends ServiceImpl<SyShippingOrderMappe
                 syPackingListTailoring.setIsReference(0);
                 syPackingListTailoring.setShippingOrderNumber("");
                 syPackingListTailoring.setExportInvoiceNo("");
-                syPackingListTailoring.setContainerCode("");
+                //syPackingListTailoring.setContainerCode("");
                 syPackingListTailoring.setContainerNumber("");
                 syPackingListTailoringService.updateById(syPackingListTailoring);
             }