zengyf 2 vuotta sitten
vanhempi
commit
9f0bcd3597

+ 2 - 0
src/main/java/com/steerinfo/dil/mapper/AmsContractTruckPriceMapper.java

@@ -123,4 +123,6 @@ public interface AmsContractTruckPriceMapper extends IBaseMapper<AmsContractTran
 
     List<Map<String, Object>> getPriceValueListInward(BigDecimal oilTypeId);
 
+//    //子表信息复制新增、
+//    insertIntoAmsContractForMaterial(BigDecimal priceId);
 }

+ 11 - 6
src/main/java/com/steerinfo/dil/service/impl/AmsContractTruckPriceServiceImpl.java

@@ -358,13 +358,18 @@ public class AmsContractTruckPriceServiceImpl implements IAmsContractTruckPriceS
         BigDecimal type = DataChange.dataToBigDecimal(map.get("type"));
         //根据油品名称ID和非历史油价筛选出符合条件的运价合集
         List<Map<String, Object>> PriceValueList = new ArrayList<>();
-        if (type.compareTo(new BigDecimal(1)) == 0) {
-            PriceValueList = amsContractTruckPriceMapper.getPriceValueList(oilTypeId);
-        }else if(type.compareTo(new BigDecimal(2)) == 0) {
-            PriceValueList = amsContractTruckPriceMapper.getPriceValueListInward(oilTypeId);
-        }
-
+        PriceValueList = amsContractTruckPriceMapper.getPriceValueList(oilTypeId);
+//        if (type.compareTo(new BigDecimal(1)) == 0) {
+//
+//        }else if(type.compareTo(new BigDecimal(2)) == 0) {
+//            PriceValueList = amsContractTruckPriceMapper.getPriceValueListInward(oilTypeId);
+//        }
         for (Map<String, Object> stringObjectMap : PriceValueList) {
+            //内转的话复制子表信息并新增
+//            if(type.compareTo(new BigDecimal(2)) == 0){
+//                stringObjectMap.get("priceId");
+//                amsContractTruckPriceMapper.
+//            }
             //有距离则是销售钢材
             if (stringObjectMap.get("haulDistance")!=null) {
                 //中标价格或者收货地址(库存)则重新计算价格

+ 4 - 0
src/main/resources/com/steerinfo/dil/mapper/AmsContractTruckPriceMapper.xml

@@ -1614,6 +1614,10 @@
       and a_t_price.type in (2,5,6)
     order by a_t_price.PRICE_ID desc
   </select>
+
+  <insert id="insertIntoAmsContractForMaterial">
+    insert into 
+  </insert>
   <insert id="insertshdz" parameterType="map">
     insert into RMS_RECEIVE_ADDRESS (ADDRESS_ID, ADDRESS_PROVINCE, ADDRESS_DISTRICT
     <if test="addressTown!=null">