Commit a5299228 by 徐康

处理父商品id问题

parent 1c7071f2
...@@ -183,7 +183,7 @@ public class DeliveryAdapter { ...@@ -183,7 +183,7 @@ public class DeliveryAdapter {
OrderProductAddInfoDto orderProductAddInfoDto = JSON.parseObject(productList.getAddInfo(), OrderProductAddInfoDto.class); OrderProductAddInfoDto orderProductAddInfoDto = JSON.parseObject(productList.getAddInfo(), OrderProductAddInfoDto.class);
deliveryProductInfo.setTaxId(StringUtils.isNotEmpty(orderProductAddInfoDto.getTaxId()) ? orderProductAddInfoDto.getTaxId() : "10"); deliveryProductInfo.setTaxId(StringUtils.isNotEmpty(orderProductAddInfoDto.getTaxId()) ? orderProductAddInfoDto.getTaxId() : "10");
deliveryProductInfo.setTaxRate(orderProductAddInfoDto.getTax() > 0 ? orderProductAddInfoDto.getTax() : 6); deliveryProductInfo.setTaxRate(orderProductAddInfoDto.getTax() > 0 ? orderProductAddInfoDto.getTax() : 6);
deliveryProductInfo.setParentCode(Long.valueOf(productList.getParentProductId()) == 0l ? -1l : Long.valueOf(productList.getParentProductId())); deliveryProductInfo.setParentCode(-1l);
productInfos.add(deliveryProductInfo); productInfos.add(deliveryProductInfo);
...@@ -199,7 +199,8 @@ public class DeliveryAdapter { ...@@ -199,7 +199,8 @@ public class DeliveryAdapter {
OrderProductAddInfoDto orderComboProductAddInfoDto = JSON.parseObject(comboProduct.getAddInfo(), OrderProductAddInfoDto.class); OrderProductAddInfoDto orderComboProductAddInfoDto = JSON.parseObject(comboProduct.getAddInfo(), OrderProductAddInfoDto.class);
deliveryComboProductInfo.setTaxId(StringUtils.isNotEmpty(orderComboProductAddInfoDto.getTaxId()) ? orderComboProductAddInfoDto.getTaxId() : "10"); deliveryComboProductInfo.setTaxId(StringUtils.isNotEmpty(orderComboProductAddInfoDto.getTaxId()) ? orderComboProductAddInfoDto.getTaxId() : "10");
deliveryComboProductInfo.setTaxRate(orderComboProductAddInfoDto.getTax() > 0 ? orderComboProductAddInfoDto.getTax() : 6); deliveryComboProductInfo.setTaxRate(orderComboProductAddInfoDto.getTax() > 0 ? orderComboProductAddInfoDto.getTax() : 6);
deliveryComboProductInfo.setParentCode(Long.valueOf(comboProduct.getParentProductId()) == 0l ? -1l : Long.valueOf(comboProduct.getParentProductId()));
deliveryComboProductInfo.setParentCode(Long.valueOf(comboProduct.getParentProductId().split("_")[0]));
productInfos.add(deliveryComboProductInfo); productInfos.add(deliveryComboProductInfo);
}); });
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment