Browse Source

发运明细导出以及订单接口调整

zengtx 2 years ago
parent
commit
c3d9caf27e

+ 5 - 0
jeecg-boot-module-system/src/main/java/org/jeecg/modules/documents/shippingDetails/entity/SyShippingDetailsItem.java

@@ -352,6 +352,10 @@ public class SyShippingDetailsItem {
 	@ApiModelProperty(value = "最底层供应商名称")
 	@ApiModelProperty(value = "最底层供应商名称")
 	private java.lang.String supplier;
 	private java.lang.String supplier;
 
 
+	@Excel(name = "计划到货日期", width = 15)
+	@ApiModelProperty(value = "计划到货日期")
+	private String dArriveDate;
+
 	//采购委外账套号
 	//采购委外账套号
 	private java.lang.String ompoAccount;
 	private java.lang.String ompoAccount;
 
 
@@ -443,6 +447,7 @@ public class SyShippingDetailsItem {
         this.rSupplierCode = orderDataVo.getRSupplierCode();
         this.rSupplierCode = orderDataVo.getRSupplierCode();
         this.orderDate = orderDataVo.getOrderDate();
         this.orderDate = orderDataVo.getOrderDate();
         this.factoryUnitPrice = orderDataVo.getITaxPrice().toString();
         this.factoryUnitPrice = orderDataVo.getITaxPrice().toString();
+        this.dArriveDate = orderDataVo.getDArriveDate();
 
 
 	}
 	}
 }
 }

+ 4 - 0
jeecg-boot-module-system/src/main/java/org/jeecg/modules/documents/shippingDetails/entity/VO/OrderDataVo.java

@@ -268,4 +268,8 @@ public class OrderDataVo {
     @Excel(name = "染厂供应商", width = 15)
     @Excel(name = "染厂供应商", width = 15)
     @ApiModelProperty(value = "染厂供应商")
     @ApiModelProperty(value = "染厂供应商")
     private java.lang.String rSupplier;
     private java.lang.String rSupplier;
+
+    @Excel(name = "计划到货日期", width = 15)
+    @ApiModelProperty(value = "计划到货日期")
+    private String dArriveDate;
 }
 }

+ 4 - 4
jeecg-boot-module-system/src/main/java/org/jeecg/modules/documents/shippingDetails/mapper/xml/SyShippingDetailsMapper.xml

@@ -60,7 +60,7 @@ a.end_customer) as endCustomer,
     select t.* from(select b.is_reference as isReference,a.id as id,GROUP_CONCAT(b.id) as itemIds,a.document_no as documentNo,a.document_date as documentDate,b.order_number as orderNumber,a.push_state,b.submit_status as submitStatus,
     select t.* from(select b.is_reference as isReference,a.id as id,GROUP_CONCAT(b.id) as itemIds,a.document_no as documentNo,a.document_date as documentDate,b.order_number as orderNumber,a.push_state,b.submit_status as submitStatus,
     b.customer_abbreviation as customerAbbreviation,b.sales_department as salesDepartment,b.salesman as salesman,a.customer as customer,b.specification_and_model as specificationAndModel,
     b.customer_abbreviation as customerAbbreviation,b.sales_department as salesDepartment,b.salesman as salesman,a.customer as customer,b.specification_and_model as specificationAndModel,
     b.small_po as smallPo,b.pack_id as packId,b.pre_delivery_date as preDeliveryDate,b.order_date as orderDate,b.inventory_ccode as inventoryCcode,
     b.small_po as smallPo,b.pack_id as packId,b.pre_delivery_date as preDeliveryDate,b.order_date as orderDate,b.inventory_ccode as inventoryCcode,
-    sum(b.shipment_quantity) as shipmentQuantity,b.customs_declaration_unit_price as customsDeclarationUnitPrice,b.order_quantity as orderQuantity,
+    sum(b.shipment_quantity) as shipmentQuantity,b.customs_declaration_unit_price as customsDeclarationUnitPrice,sum(b.order_quantity) as orderQuantity,
     b.is_tc as isTc,b.distribution_point as distributionPoint,b.item_number as itemNumber,b.business_type_text as businessTypeText,
     b.is_tc as isTc,b.distribution_point as distributionPoint,b.item_number as itemNumber,b.business_type_text as businessTypeText,
     b.arrival_date as arrivalDate,b.inventory_name as inventoryName,b.sales_unit_price as salesUnitPrice,b.order_remaining_quantity as orderRemainingQuantity,
     b.arrival_date as arrivalDate,b.inventory_name as inventoryName,b.sales_unit_price as salesUnitPrice,b.order_remaining_quantity as orderRemainingQuantity,
     b.pur_or_sub_order as purOrSubOrder,a.order_type as orderType,b.factory_unit_price as factoryUnitPrice,b.third_party as thirdParty,b.customer_order as customerOrder,
     b.pur_or_sub_order as purOrSubOrder,a.order_type as orderType,b.factory_unit_price as factoryUnitPrice,b.third_party as thirdParty,b.customer_order as customerOrder,
@@ -70,7 +70,7 @@ a.end_customer) as endCustomer,
     b.sales_type_text as salesTypeText,b.customer_name as customerName,b.exchange_rate as exchangeRate,a.whole_order_total as wholeOrderTotal,
     b.sales_type_text as salesTypeText,b.customer_name as customerName,b.exchange_rate as exchangeRate,a.whole_order_total as wholeOrderTotal,
     b.declaration_elements as declarationElements,b.number_of_sets as numberOfSets,a.chinese_name as chineseName,b.account as account,b.supplier as supplier,
     b.declaration_elements as declarationElements,b.number_of_sets as numberOfSets,a.chinese_name as chineseName,b.account as account,b.supplier as supplier,
     b.garment_factory as garmentFactory,b.elements_id as elementsId,b.coding_rules as codingRules,b.colour as colour,b.group_id as groupId,
     b.garment_factory as garmentFactory,b.elements_id as elementsId,b.coding_rules as codingRules,b.colour as colour,b.group_id as groupId,
-     c.declaration_name as declarationName,c.hs_code as hsCode,c.english_product_name as englishProductName
+     c.declaration_name as declarationName,c.hs_code as hsCode,c.english_product_name as englishProductName,b.d_arrive_date as dArriveDate
      from sy_shipping_details a
      from sy_shipping_details a
 left join sy_shipping_details_item b
 left join sy_shipping_details_item b
 on a.id = b.shipping_details_id and b.del_flag = 0
 on a.id = b.shipping_details_id and b.del_flag = 0
@@ -87,7 +87,7 @@ ${ew.customSqlSegment} and  t.inventoryCcode LIKE '19%'
     select t.* from(select b.is_reference as isReference,a.id as id,GROUP_CONCAT(b.id) as itemIds,a.document_no as documentNo,a.document_date as documentDate,b.order_number as orderNumber,a.push_state,b.submit_status as submitStatus,
     select t.* from(select b.is_reference as isReference,a.id as id,GROUP_CONCAT(b.id) as itemIds,a.document_no as documentNo,a.document_date as documentDate,b.order_number as orderNumber,a.push_state,b.submit_status as submitStatus,
     b.customer_abbreviation as customerAbbreviation,b.sales_department as salesDepartment,b.salesman as salesman,a.customer as customer,b.specification_and_model as specificationAndModel,
     b.customer_abbreviation as customerAbbreviation,b.sales_department as salesDepartment,b.salesman as salesman,a.customer as customer,b.specification_and_model as specificationAndModel,
     b.small_po as smallPo,b.pack_id as packId,b.pre_delivery_date as preDeliveryDate,b.order_date as orderDate,b.inventory_ccode as inventoryCcode,
     b.small_po as smallPo,b.pack_id as packId,b.pre_delivery_date as preDeliveryDate,b.order_date as orderDate,b.inventory_ccode as inventoryCcode,
-    sum(b.shipment_quantity) as shipmentQuantity,b.customs_declaration_unit_price as customsDeclarationUnitPrice,b.order_quantity as orderQuantity,
+    sum(b.shipment_quantity) as shipmentQuantity,b.customs_declaration_unit_price as customsDeclarationUnitPrice,sum(b.order_quantity) as orderQuantity,
     b.is_tc as isTc,b.distribution_point as distributionPoint,b.item_number as itemNumber,b.business_type_text as businessTypeText,
     b.is_tc as isTc,b.distribution_point as distributionPoint,b.item_number as itemNumber,b.business_type_text as businessTypeText,
     b.arrival_date as arrivalDate,b.inventory_name as inventoryName,b.sales_unit_price as salesUnitPrice,b.order_remaining_quantity as orderRemainingQuantity,
     b.arrival_date as arrivalDate,b.inventory_name as inventoryName,b.sales_unit_price as salesUnitPrice,b.order_remaining_quantity as orderRemainingQuantity,
     b.pur_or_sub_order as purOrSubOrder,a.order_type as orderType,b.factory_unit_price as factoryUnitPrice,b.third_party as thirdParty,b.customer_order as customerOrder,
     b.pur_or_sub_order as purOrSubOrder,a.order_type as orderType,b.factory_unit_price as factoryUnitPrice,b.third_party as thirdParty,b.customer_order as customerOrder,
@@ -97,7 +97,7 @@ ${ew.customSqlSegment} and  t.inventoryCcode LIKE '19%'
     b.sales_type_text as salesTypeText,b.customer_name as customerName,b.exchange_rate as exchangeRate,a.whole_order_total as wholeOrderTotal,
     b.sales_type_text as salesTypeText,b.customer_name as customerName,b.exchange_rate as exchangeRate,a.whole_order_total as wholeOrderTotal,
     b.declaration_elements as declarationElements,b.number_of_sets as numberOfSets,a.chinese_name as chineseName,b.account as account,b.supplier as supplier,
     b.declaration_elements as declarationElements,b.number_of_sets as numberOfSets,a.chinese_name as chineseName,b.account as account,b.supplier as supplier,
     b.garment_factory as garmentFactory,b.elements_id as elementsId,b.coding_rules as codingRules,b.colour as colour,b.group_id as groupId,
     b.garment_factory as garmentFactory,b.elements_id as elementsId,b.coding_rules as codingRules,b.colour as colour,b.group_id as groupId,
-     c.declaration_name as declarationName,c.hs_code as hsCode,c.english_product_name as englishProductName
+     c.declaration_name as declarationName,c.hs_code as hsCode,c.english_product_name as englishProductName,b.d_arrive_date as dArriveDate
      from sy_shipping_details a
      from sy_shipping_details a
 left join sy_shipping_details_item b
 left join sy_shipping_details_item b
 on a.id = b.shipping_details_id and b.del_flag = 0
 on a.id = b.shipping_details_id and b.del_flag = 0

+ 38 - 10
jeecg-boot-module-system/src/main/java/org/jeecg/modules/report/controller/FullSetRateController.java

@@ -50,19 +50,36 @@ public class FullSetRateController extends JeecgController<FullSetRate, IFullSet
         Result<IPage<FullSetRate>> result = new Result<IPage<FullSetRate>>();
         Result<IPage<FullSetRate>> result = new Result<IPage<FullSetRate>>();
         Page<FullSetRate> page = new Page<FullSetRate>(pageNo,pageSize);
         Page<FullSetRate> page = new Page<FullSetRate>(pageNo,pageSize);
         QueryWrapper<FullSetRate> queryWrapper = new QueryWrapper<>();
         QueryWrapper<FullSetRate> queryWrapper = new QueryWrapper<>();
-        if(oConvertUtils.isNotEmpty(fullSetRate.getSubcontractOrderNo())){
-            queryWrapper.like("a.cCode",fullSetRate.getSubcontractOrderNo());
+        //来源订单号
+        if(oConvertUtils.isNotEmpty(fullSetRate.getSourceOrderNo())){
+            queryWrapper.like("a.cSOCode",fullSetRate.getSourceOrderNo());
         }
         }
         if(oConvertUtils.isNotEmpty(fullSetRate.getBeginDate())){
         if(oConvertUtils.isNotEmpty(fullSetRate.getBeginDate())){
             queryWrapper.between("b.dPreDate",fullSetRate.getBeginDate(),fullSetRate.getEndDate());//"2022-07-01","2022-07-30"
             queryWrapper.between("b.dPreDate",fullSetRate.getBeginDate(),fullSetRate.getEndDate());//"2022-07-01","2022-07-30"
         }
         }
-//        if(oConvertUtils.isNotEmpty(fullSetRate.getSection())){
-//            queryWrapper.like("a.cCode",fullSetRate.getSection());
-//        }
-//        //颜色
-//        if(oConvertUtils.isNotEmpty(fullSetRate.getColor())){
-//            queryWrapper.like("b.cFree1",fullSetRate.getColor());
-//        }
+        if(oConvertUtils.isNotEmpty(fullSetRate.getDepartment())){
+            queryWrapper.eq("d.cDepName",fullSetRate.getDepartment());
+        }
+        //颜色
+        if(oConvertUtils.isNotEmpty(fullSetRate.getColor())){
+            queryWrapper.eq("b.cFree1",fullSetRate.getColor());
+        }
+        //订单编号
+        if(oConvertUtils.isNotEmpty(fullSetRate.getSubcontractOrderNo())){
+            queryWrapper.like("om.cCode",fullSetRate.getSubcontractOrderNo());
+        }
+        //交期
+        if(oConvertUtils.isNotEmpty(fullSetRate.getDeliveryDate())){
+            queryWrapper.eq("b.dPreDate",fullSetRate.getDeliveryDate());
+        }
+        //业务员
+        if(oConvertUtils.isNotEmpty(fullSetRate.getSalesman())){
+            queryWrapper.eq("p.cPersonName",fullSetRate.getSalesman());
+        }
+        //销售订单数量
+        if(oConvertUtils.isNotEmpty(fullSetRate.getSalesOrderQuantity())){
+            queryWrapper.eq("b.iQuantity",fullSetRate.getSalesOrderQuantity());
+        }
 
 
         queryWrapper.isNotNull("om.cCode");
         queryWrapper.isNotNull("om.cCode");
         queryWrapper.groupBy("a.ID");
         queryWrapper.groupBy("a.ID");
@@ -203,10 +220,21 @@ public class FullSetRateController extends JeecgController<FullSetRate, IFullSet
 
 
         List<FullSetRateList> list = fullSetRateService.queryOMMOdetilList(idList);
         List<FullSetRateList> list = fullSetRateService.queryOMMOdetilList(idList);
 
 
+
         for(FullSetRateList li:list){
         for(FullSetRateList li:list){
             //获取最小齐套率且赋值
             //获取最小齐套率且赋值
             List<FullSetRateSubInfo> setRate = fullSetRateService.queryOMMOmainSubInfo(li.getMODetailsID());
             List<FullSetRateSubInfo> setRate = fullSetRateService.queryOMMOmainSubInfo(li.getMODetailsID());
-            li.setSetRate(setRate.get(0).getSetRate());
+            if(list.size()!=0){
+                if(oConvertUtils.isNotEmpty(setRate.get(0).getSetRate())){
+                    li.setSetRate(setRate.get(0).getSetRate());
+                }else{
+                    li.setSetRate(BigDecimal.ZERO);
+                }
+
+            }else{
+                li.setSetRate(BigDecimal.ZERO);
+            }
+
         }
         }
 
 
         result.setSuccess(true);
         result.setSuccess(true);

+ 10 - 1
jeecg-boot-module-system/src/main/java/org/jeecg/modules/report/entity/FullSetRate.java

@@ -61,11 +61,20 @@ public class FullSetRate {
     List<String> soIDsID;
     List<String> soIDsID;
     private String cInvCode;
     private String cInvCode;
 
 
-    //查询条件所需字段
+    /**
+     * 查询条件所需字段
+     */
     private String beginDate;
     private String beginDate;
     private String endDate;
     private String endDate;
+    //区间
     private String section;
     private String section;
+    //颜色
     private String color;
     private String color;
+    //小PO
     private String smllPo;
     private String smllPo;
+    //出库齐套
+    private String fullSet;
+
+
 
 
 }
 }

+ 1 - 1
jeecg-boot-module-system/src/main/java/org/jeecg/modules/report/mapper/xml/FullSetTateMapper.xml

@@ -69,7 +69,7 @@ ${ew.customSqlSegment}
 select cInvCode,sum(iUnitQuantity) as quantityUsed,sum(iSendQTY) as totalCollectedQuantity,
 select cInvCode,sum(iUnitQuantity) as quantityUsed,sum(iSendQTY) as totalCollectedQuantity,
 sum(iQuantity) as totalQuantityReceivable,
 sum(iQuantity) as totalQuantityReceivable,
 max(cFree1) as clour,max(cFree6) as gramWeight,max(cFree2) as size,max(cDefine23) as doorframe,
 max(cFree1) as clour,max(cFree6) as gramWeight,max(cFree2) as size,max(cDefine23) as doorframe,
-(sum(iSendQTY)/sum(iQuantity)) as setRate
+(sum(iSendQTY)/sum(iQuantity))*100 as setRate
 from OM_MOMaterials
 from OM_MOMaterials
 where MoDetailsID = #{mODetailsID} group by cInvCode order by (sum(iSendQTY)/sum(iQuantity))
 where MoDetailsID = #{mODetailsID} group by cInvCode order by (sum(iSendQTY)/sum(iQuantity))
 
 

+ 75 - 3
jeecg-boot-module-system/src/main/java/org/jeecg/modules/system/util/JsonChangeUtils.java

@@ -102,7 +102,8 @@ public class JsonChangeUtils implements ApplicationContextAware{
                         "mo.iTaxPrice as 'customerPrice',(mo.iPerTaxRate/100) as 'lineTaxRate',case when mo.iSum is null then '0' else mo.iSum end as amount,ex.cbdefine2 as lineAttributeString7,ex.cbdefine3 as lineAttributeString8," +
                         "mo.iTaxPrice as 'customerPrice',(mo.iPerTaxRate/100) as 'lineTaxRate',case when mo.iSum is null then '0' else mo.iSum end as amount,ex.cbdefine2 as lineAttributeString7,ex.cbdefine3 as lineAttributeString8," +
                         "mo.cDefine28 as 'lineAttributeString1',mo.cDefine32 as 'lineAttributeString2',mo.cDefine29 as 'lineAttributeString3'," +
                         "mo.cDefine28 as 'lineAttributeString1',mo.cDefine32 as 'lineAttributeString2',mo.cDefine29 as 'lineAttributeString3'," +
                         "mo.cDefine30 as 'lineAttributeString4',mo.cbMemo as 'lineAttributeString5',mo.cDefine22 as lineAttributeString6,'' as lineAttributeString7,'' as lineAttributeString8," +
                         "mo.cDefine30 as 'lineAttributeString4',mo.cbMemo as 'lineAttributeString5',mo.cDefine22 as lineAttributeString6,'' as lineAttributeString7,'' as lineAttributeString8," +
-                        "cFree1 as 'color','' as 'customerNumber',mo.iUnitPrice as supplierExTaxPrice,'"+map.get("dVerifyDate")+"' as lineAttributeDatetime2," +
+                        "mo.cFree1 as 'color','' as 'customerNumber',mo.iUnitPrice as supplierExTaxPrice,'"+map.get("dVerifyDate")+"' as lineAttributeDatetime2," +
+                        "inv.bConfigFree1 as bConfigFree1,inv.bConfigFree2 as bConfigFree2,inv.bConfigFree3 as bConfigFree3,inv.bConfigFree4 as bConfigFree4,inv.bConfigFree5 as bConfigFree5,inv.bConfigFree6 as bConfigFree6,inv.bConfigFree7 as bConfigFree7,inv.bConfigFree8 as bConfigFree8,inv.bConfigFree9 as bConfigFree9,inv.bConfigFree10 as bConfigFree10,"+
                         "'' as externalLineNum,'' as itemAttrId,'"+map.get("moId")+"' as poId  from OM_MODetails mo  " +
                         "'' as externalLineNum,'' as itemAttrId,'"+map.get("moId")+"' as poId  from OM_MODetails mo  " +
                         "left join Inventory inv  on mo.cInvCode = inv.cInvCode "+
                         "left join Inventory inv  on mo.cInvCode = inv.cInvCode "+
                         "left join OM_MOdetails_extradefine ex on mo.MODetailsID = ex.MODetailsID "+
                         "left join OM_MOdetails_extradefine ex on mo.MODetailsID = ex.MODetailsID "+
@@ -130,7 +131,8 @@ public class JsonChangeUtils implements ApplicationContextAware{
                         "mo.iTaxPrice as 'customerPrice',(mo.iPerTaxRate/100) as 'lineTaxRate',case when mo.iSum is null then '0' else mo.iSum end as amount,ex.cbdefine2 as lineAttributeString7,ex.cbdefine3 as lineAttributeString8," +
                         "mo.iTaxPrice as 'customerPrice',(mo.iPerTaxRate/100) as 'lineTaxRate',case when mo.iSum is null then '0' else mo.iSum end as amount,ex.cbdefine2 as lineAttributeString7,ex.cbdefine3 as lineAttributeString8," +
                         "mo.cDefine28 as 'lineAttributeString1',mo.cDefine32 as 'lineAttributeString2',mo.cDefine29 as 'lineAttributeString3'," +
                         "mo.cDefine28 as 'lineAttributeString1',mo.cDefine32 as 'lineAttributeString2',mo.cDefine29 as 'lineAttributeString3'," +
                         "mo.cDefine30 as 'lineAttributeString4',mo.cbMemo as 'lineAttributeString5',mo.cDefine22 as lineAttributeString6,'' as lineAttributeString7,'' as lineAttributeString8," +
                         "mo.cDefine30 as 'lineAttributeString4',mo.cbMemo as 'lineAttributeString5',mo.cDefine22 as lineAttributeString6,'' as lineAttributeString7,'' as lineAttributeString8," +
-                        "cFree1 as 'color','' as 'customerNumber',mo.iUnitPrice as supplierExTaxPrice,'"+map.get("dVerifyDate")+"' as lineAttributeDatetime2," +
+                        "mo.cFree1 as 'color','' as 'customerNumber',mo.iUnitPrice as supplierExTaxPrice,'"+map.get("dVerifyDate")+"' as lineAttributeDatetime2," +
+                        "inv.bConfigFree1 as bConfigFree1,inv.bConfigFree2 as bConfigFree2,inv.bConfigFree3 as bConfigFree3,inv.bConfigFree4 as bConfigFree4,inv.bConfigFree5 as bConfigFree5,inv.bConfigFree6 as bConfigFree6,inv.bConfigFree7 as bConfigFree7,inv.bConfigFree8 as bConfigFree8,inv.bConfigFree9 as bConfigFree9,inv.bConfigFree10 as bConfigFree10,"+
                         "'' as externalLineNum,'' as itemAttrId,'"+map.get("moId")+"' as poId  from OM_MODetails mo  " +
                         "'' as externalLineNum,'' as itemAttrId,'"+map.get("moId")+"' as poId  from OM_MODetails mo  " +
                         "left join Inventory inv  on mo.cInvCode = inv.cInvCode "+
                         "left join Inventory inv  on mo.cInvCode = inv.cInvCode "+
                         "left join OM_MOdetails_extradefine ex on mo.MODetailsID = ex.MODetailsID "+
                         "left join OM_MOdetails_extradefine ex on mo.MODetailsID = ex.MODetailsID "+
@@ -159,7 +161,8 @@ public class JsonChangeUtils implements ApplicationContextAware{
                         "mo.iTaxPrice as 'customerPrice',(mo.iPerTaxRate/100) as 'lineTaxRate',case when mo.iSum is null then '0' else mo.iSum end as amount,ex.cbdefine2 as lineAttributeString7,ex.cbdefine3 as lineAttributeString8," +
                         "mo.iTaxPrice as 'customerPrice',(mo.iPerTaxRate/100) as 'lineTaxRate',case when mo.iSum is null then '0' else mo.iSum end as amount,ex.cbdefine2 as lineAttributeString7,ex.cbdefine3 as lineAttributeString8," +
                         "mo.cDefine28 as 'lineAttributeString1',mo.cDefine32 as 'lineAttributeString2',mo.cDefine29 as 'lineAttributeString3'," +
                         "mo.cDefine28 as 'lineAttributeString1',mo.cDefine32 as 'lineAttributeString2',mo.cDefine29 as 'lineAttributeString3'," +
                         "mo.cDefine30 as 'lineAttributeString4',mo.cbMemo as 'lineAttributeString5',mo.cDefine22 as lineAttributeString6,'' as lineAttributeString7,'' as lineAttributeString8," +
                         "mo.cDefine30 as 'lineAttributeString4',mo.cbMemo as 'lineAttributeString5',mo.cDefine22 as lineAttributeString6,'' as lineAttributeString7,'' as lineAttributeString8," +
-                        "cFree1 as 'color','' as 'customerNumber',mo.iUnitPrice as supplierExTaxPrice,'"+map.get("dVerifyDate")+"' as lineAttributeDatetime2," +
+                        "mo.cFree1 as 'color','' as 'customerNumber',mo.iUnitPrice as supplierExTaxPrice,'"+map.get("dVerifyDate")+"' as lineAttributeDatetime2," +
+                        "inv.bConfigFree1 as bConfigFree1,inv.bConfigFree2 as bConfigFree2,inv.bConfigFree3 as bConfigFree3,inv.bConfigFree4 as bConfigFree4,inv.bConfigFree5 as bConfigFree5,inv.bConfigFree6 as bConfigFree6,inv.bConfigFree7 as bConfigFree7,inv.bConfigFree8 as bConfigFree8,inv.bConfigFree9 as bConfigFree9,inv.bConfigFree10 as bConfigFree10,"+
                         "'' as externalLineNum,'' as itemAttrId,'"+map.get("moId")+"' as poId  from OM_MODetails mo  " +
                         "'' as externalLineNum,'' as itemAttrId,'"+map.get("moId")+"' as poId  from OM_MODetails mo  " +
                         "left join Inventory inv  on mo.cInvCode = inv.cInvCode "+
                         "left join Inventory inv  on mo.cInvCode = inv.cInvCode "+
                         "left join OM_MOdetails_extradefine ex on mo.MODetailsID = ex.MODetailsID "+
                         "left join OM_MOdetails_extradefine ex on mo.MODetailsID = ex.MODetailsID "+
@@ -233,6 +236,7 @@ public class JsonChangeUtils implements ApplicationContextAware{
                         "mo.iTaxPrice as 'customerPrice',(mo.iPerTaxRate/100) as 'lineTaxRate',mo.iSum as 'amount',mo.cDefine28 as 'lineAttributeString1'," +
                         "mo.iTaxPrice as 'customerPrice',(mo.iPerTaxRate/100) as 'lineTaxRate',mo.iSum as 'amount',mo.cDefine28 as 'lineAttributeString1'," +
                         "mo.cDefine32 as 'lineAttributeString2',mo.cDefine29 as 'lineAttributeString3','' as 'attributeString1',mo.cDefine30 as 'lineAttributeString4'," +
                         "mo.cDefine32 as 'lineAttributeString2',mo.cDefine29 as 'lineAttributeString3','' as 'attributeString1',mo.cDefine30 as 'lineAttributeString4'," +
                         "mo.cbMemo as 'lineAttributeString5',mo.cDefine22 as lineAttributeString6,'' as lineAttributeString7,'' as lineAttributeString8,'' as 'color'," +
                         "mo.cbMemo as 'lineAttributeString5',mo.cDefine22 as lineAttributeString6,'' as lineAttributeString7,'' as lineAttributeString8,'' as 'color'," +
+                        "inv.bConfigFree1 as bConfigFree1,inv.bConfigFree2 as bConfigFree2,inv.bConfigFree3 as bConfigFree3,inv.bConfigFree4 as bConfigFree4,inv.bConfigFree5 as bConfigFree5,inv.bConfigFree6 as bConfigFree6,inv.bConfigFree7 as bConfigFree7,inv.bConfigFree8 as bConfigFree8,inv.bConfigFree9 as bConfigFree9,inv.bConfigFree10 as bConfigFree10,"+
                         "'' as 'externalLineNum',0 as 'itemAttrId' from PO_Podetails mo left join Inventory inv on mo.cInvCode = inv.cInvCode " +
                         "'' as 'externalLineNum',0 as 'itemAttrId' from PO_Podetails mo left join Inventory inv on mo.cInvCode = inv.cInvCode " +
                         "left join PO_Podetails_extradefine ex on mo.ID = ex.ID"+
                         "left join PO_Podetails_extradefine ex on mo.ID = ex.ID"+
                         " where mo.POID = '"+map.get("moId")+"'";
                         " where mo.POID = '"+map.get("moId")+"'";
@@ -259,6 +263,7 @@ public class JsonChangeUtils implements ApplicationContextAware{
                         "mo.iTaxPrice as 'customerPrice',(mo.iPerTaxRate/100) as 'lineTaxRate',mo.iSum as 'amount',mo.cDefine28 as 'lineAttributeString1'," +
                         "mo.iTaxPrice as 'customerPrice',(mo.iPerTaxRate/100) as 'lineTaxRate',mo.iSum as 'amount',mo.cDefine28 as 'lineAttributeString1'," +
                         "mo.cDefine32 as 'lineAttributeString2',mo.cDefine29 as 'lineAttributeString3','' as 'attributeString1',mo.cDefine30 as 'lineAttributeString4'," +
                         "mo.cDefine32 as 'lineAttributeString2',mo.cDefine29 as 'lineAttributeString3','' as 'attributeString1',mo.cDefine30 as 'lineAttributeString4'," +
                         "mo.cbMemo as 'lineAttributeString5',mo.cDefine22 as lineAttributeString6,'' as lineAttributeString7,'' as lineAttributeString8,'' as 'color'," +
                         "mo.cbMemo as 'lineAttributeString5',mo.cDefine22 as lineAttributeString6,'' as lineAttributeString7,'' as lineAttributeString8,'' as 'color'," +
+                        "inv.bConfigFree1 as bConfigFree1,inv.bConfigFree2 as bConfigFree2,inv.bConfigFree3 as bConfigFree3,inv.bConfigFree4 as bConfigFree4,inv.bConfigFree5 as bConfigFree5,inv.bConfigFree6 as bConfigFree6,inv.bConfigFree7 as bConfigFree7,inv.bConfigFree8 as bConfigFree8,inv.bConfigFree9 as bConfigFree9,inv.bConfigFree10 as bConfigFree10,"+
                         "'' as 'externalLineNum',0 as 'itemAttrId' from PO_Podetails mo left join Inventory inv on mo.cInvCode = inv.cInvCode " +
                         "'' as 'externalLineNum',0 as 'itemAttrId' from PO_Podetails mo left join Inventory inv on mo.cInvCode = inv.cInvCode " +
                         "left join PO_Podetails_extradefine ex on mo.ID = ex.ID"+
                         "left join PO_Podetails_extradefine ex on mo.ID = ex.ID"+
                         " where mo.POID = '"+map.get("moId")+"'";
                         " where mo.POID = '"+map.get("moId")+"'";
@@ -284,6 +289,7 @@ public class JsonChangeUtils implements ApplicationContextAware{
                         "mo.iTaxPrice as 'customerPrice',(mo.iPerTaxRate/100) as 'lineTaxRate',mo.iSum as 'amount',mo.cDefine28 as 'lineAttributeString1'," +
                         "mo.iTaxPrice as 'customerPrice',(mo.iPerTaxRate/100) as 'lineTaxRate',mo.iSum as 'amount',mo.cDefine28 as 'lineAttributeString1'," +
                         "mo.cDefine32 as 'lineAttributeString2',mo.cDefine29 as 'lineAttributeString3','' as 'attributeString1',mo.cDefine30 as 'lineAttributeString4'," +
                         "mo.cDefine32 as 'lineAttributeString2',mo.cDefine29 as 'lineAttributeString3','' as 'attributeString1',mo.cDefine30 as 'lineAttributeString4'," +
                         "mo.cbMemo as 'lineAttributeString5',mo.cDefine22 as lineAttributeString6,'' as lineAttributeString7,'' as lineAttributeString8,'' as 'color'," +
                         "mo.cbMemo as 'lineAttributeString5',mo.cDefine22 as lineAttributeString6,'' as lineAttributeString7,'' as lineAttributeString8,'' as 'color'," +
+                        "inv.bConfigFree1 as bConfigFree1,inv.bConfigFree2 as bConfigFree2,inv.bConfigFree3 as bConfigFree3,inv.bConfigFree4 as bConfigFree4,inv.bConfigFree5 as bConfigFree5,inv.bConfigFree6 as bConfigFree6,inv.bConfigFree7 as bConfigFree7,inv.bConfigFree8 as bConfigFree8,inv.bConfigFree9 as bConfigFree9,inv.bConfigFree10 as bConfigFree10,"+
                         "'' as 'externalLineNum',0 as 'itemAttrId' from PO_Podetails mo left join Inventory inv on mo.cInvCode = inv.cInvCode " +
                         "'' as 'externalLineNum',0 as 'itemAttrId' from PO_Podetails mo left join Inventory inv on mo.cInvCode = inv.cInvCode " +
                         "left join PO_Podetails_extradefine ex on mo.ID = ex.ID "+
                         "left join PO_Podetails_extradefine ex on mo.ID = ex.ID "+
                         " where mo.POID = '"+map.get("moId")+"'";
                         " where mo.POID = '"+map.get("moId")+"'";
@@ -396,6 +402,28 @@ public class JsonChangeUtils implements ApplicationContextAware{
                     }else if(key.equals("cFree10")&&oConvertUtils.isNotEmpty(map.get(key))){
                     }else if(key.equals("cFree10")&&oConvertUtils.isNotEmpty(map.get(key))){
                         mapCfree.put(key,map.get(key));
                         mapCfree.put(key,map.get(key));
                     }
                     }
+                    //处理物料属性结构性
+                    if(key.equals("bConfigFree1")&&oConvertUtils.isNotEmpty(map.get(key))){
+                        mapCfree.put(key,map.get(key));
+                    }else if(key.equals("bConfigFree2")&&oConvertUtils.isNotEmpty(map.get(key))){
+                        mapCfree.put(key,map.get(key));
+                    }else if(key.equals("bConfigFree")&&oConvertUtils.isNotEmpty(map.get(key))){
+                        mapCfree.put(key,map.get(key));
+                    }else if(key.equals("bConfigFree")&&oConvertUtils.isNotEmpty(map.get(key))){
+                        mapCfree.put(key,map.get(key));
+                    }else if(key.equals("bConfigFree")&&oConvertUtils.isNotEmpty(map.get(key))){
+                        mapCfree.put(key,map.get(key));
+                    }else if(key.equals("bConfigFree")&&oConvertUtils.isNotEmpty(map.get(key))){
+                        mapCfree.put(key,map.get(key));
+                    }else if(key.equals("bConfigFree7")&&oConvertUtils.isNotEmpty(map.get(key))){
+                        mapCfree.put(key,map.get(key));
+                    }else if(key.equals("bConfigFree8")&&oConvertUtils.isNotEmpty(map.get(key))){
+                        mapCfree.put(key,map.get(key));
+                    }else if(key.equals("bConfigFree9")&&oConvertUtils.isNotEmpty(map.get(key))){
+                        mapCfree.put(key,map.get(key));
+                    }else if(key.equals("bConfigFree10")&&oConvertUtils.isNotEmpty(map.get(key))){
+                        mapCfree.put(key,map.get(key));
+                    }
                     jf.put(key, map.get(key));
                     jf.put(key, map.get(key));
                 }
                 }
             }
             }
@@ -418,6 +446,7 @@ public class JsonChangeUtils implements ApplicationContextAware{
             for (String key : keysCfree) {
             for (String key : keysCfree) {
                 jf.put("attributeCode"+ii, key);
                 jf.put("attributeCode"+ii, key);
                 jf.put("attributeValue"+ii, map.get(key));
                 jf.put("attributeValue"+ii, map.get(key));
+                jf.put("attributeFlag"+ii, key);
                 ii++;
                 ii++;
             }
             }
             ii = 1;
             ii = 1;
@@ -432,6 +461,16 @@ public class JsonChangeUtils implements ApplicationContextAware{
             jf.remove("cFree8");
             jf.remove("cFree8");
             jf.remove("cFree9");
             jf.remove("cFree9");
             jf.remove("cFree10");
             jf.remove("cFree10");
+            jf.remove("bConfigFree1");
+            jf.remove("bConfigFree2");
+            jf.remove("bConfigFree3");
+            jf.remove("bConfigFree4");
+            jf.remove("bConfigFree5");
+            jf.remove("bConfigFree6");
+            jf.remove("bConfigFree7");
+            jf.remove("bConfigFree8");
+            jf.remove("bConfigFree9");
+            jf.remove("bConfigFree10");
             pljf.add(jf);
             pljf.add(jf);
         }
         }
         return pljf;
         return pljf;
@@ -477,6 +516,28 @@ public class JsonChangeUtils implements ApplicationContextAware{
                     }else if(key.equals("cFree10")&&oConvertUtils.isNotEmpty(map.get(key))){
                     }else if(key.equals("cFree10")&&oConvertUtils.isNotEmpty(map.get(key))){
                         mapCfree.put(key,map.get(key));
                         mapCfree.put(key,map.get(key));
                     }
                     }
+                    //处理物料属性结构性
+                    if(key.equals("bConfigFree1")&&oConvertUtils.isNotEmpty(map.get(key))){
+                        mapCfree.put(key,map.get(key));
+                    }else if(key.equals("bConfigFree2")&&oConvertUtils.isNotEmpty(map.get(key))){
+                        mapCfree.put(key,map.get(key));
+                    }else if(key.equals("bConfigFree")&&oConvertUtils.isNotEmpty(map.get(key))){
+                        mapCfree.put(key,map.get(key));
+                    }else if(key.equals("bConfigFree")&&oConvertUtils.isNotEmpty(map.get(key))){
+                        mapCfree.put(key,map.get(key));
+                    }else if(key.equals("bConfigFree")&&oConvertUtils.isNotEmpty(map.get(key))){
+                        mapCfree.put(key,map.get(key));
+                    }else if(key.equals("bConfigFree")&&oConvertUtils.isNotEmpty(map.get(key))){
+                        mapCfree.put(key,map.get(key));
+                    }else if(key.equals("bConfigFree7")&&oConvertUtils.isNotEmpty(map.get(key))){
+                        mapCfree.put(key,map.get(key));
+                    }else if(key.equals("bConfigFree8")&&oConvertUtils.isNotEmpty(map.get(key))){
+                        mapCfree.put(key,map.get(key));
+                    }else if(key.equals("bConfigFree9")&&oConvertUtils.isNotEmpty(map.get(key))){
+                        mapCfree.put(key,map.get(key));
+                    }else if(key.equals("bConfigFree10")&&oConvertUtils.isNotEmpty(map.get(key))){
+                        mapCfree.put(key,map.get(key));
+                    }
                     jf.put(key, map.get(key));
                     jf.put(key, map.get(key));
                 }
                 }
             }
             }
@@ -536,6 +597,7 @@ public class JsonChangeUtils implements ApplicationContextAware{
             for (String key : keysCfree) {
             for (String key : keysCfree) {
                 jf.put("attributeCode"+ii, key);
                 jf.put("attributeCode"+ii, key);
                 jf.put("attributeValue"+ii, map.get(key));
                 jf.put("attributeValue"+ii, map.get(key));
+                jf.put("attributeFlag"+ii, key);
                 ii++;
                 ii++;
             }
             }
             ii = 1;
             ii = 1;
@@ -549,6 +611,16 @@ public class JsonChangeUtils implements ApplicationContextAware{
             jf.remove("cFree8");
             jf.remove("cFree8");
             jf.remove("cFree9");
             jf.remove("cFree9");
             jf.remove("cFree10");
             jf.remove("cFree10");
+            jf.remove("bConfigFree1");
+            jf.remove("bConfigFree2");
+            jf.remove("bConfigFree3");
+            jf.remove("bConfigFree4");
+            jf.remove("bConfigFree5");
+            jf.remove("bConfigFree6");
+            jf.remove("bConfigFree7");
+            jf.remove("bConfigFree8");
+            jf.remove("bConfigFree9");
+            jf.remove("bConfigFree10");
                 jf.remove("MODetailsID");
                 jf.remove("MODetailsID");
                 jf.remove("MOID");
                 jf.remove("MOID");
                 jf.remove("pkorg");
                 jf.remove("pkorg");