|
|
|
@ -58,6 +58,7 @@ import lombok.extern.slf4j.Slf4j; |
|
|
|
|
import org.apache.commons.lang3.StringUtils; |
|
|
|
|
import org.springframework.beans.BeanUtils; |
|
|
|
|
|
|
|
|
|
import java.io.IOException; |
|
|
|
|
import java.math.BigDecimal; |
|
|
|
|
import java.text.DecimalFormat; |
|
|
|
|
import java.util.*; |
|
|
|
@ -3547,6 +3548,22 @@ public class BeanTransitionUtils { |
|
|
|
|
ddmxxxBO.setSPSL(detail.getZZSL()); |
|
|
|
|
ddmxxxBO.setDJ(detail.getZZDJ()); |
|
|
|
|
} |
|
|
|
|
if(StringUtils.isNotBlank(ddmxxxBO.getGGXH())){ |
|
|
|
|
String ggxh = ddmxxxBO.getGGXH(); |
|
|
|
|
try { |
|
|
|
|
if (ggxh.getBytes(ConfigureConstant.STRING_CHARSET_GBK).length > ConfigureConstant.INT_40) { |
|
|
|
|
log.debug("对明细行规格型号进行截取,截取前数据为:{}", ggxh); |
|
|
|
|
ggxh = StringUtil.subStringByByte(ggxh, ConfigureConstant.INT_40); |
|
|
|
|
log.debug("对明细行规格型号进行截取,截取后数据为:{}", ggxh); |
|
|
|
|
ddmxxxBO.setGGXH(ggxh); |
|
|
|
|
} |
|
|
|
|
} catch (IOException e) { |
|
|
|
|
//编码格式错误
|
|
|
|
|
log.error("处理商品名称异常:{}", e); |
|
|
|
|
throw new RuntimeException(e); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
ddmxxxBO.setSL(new BigDecimal(detail.getZTAX()).divide(new BigDecimal("100"), 2, BigDecimal.ROUND_HALF_UP).toString()); |
|
|
|
|
|
|
|
|
|
if(StringUtils.isNotBlank(detail.getZZSE()) && StringUtils.isNotBlank(detail.getZBHSJE())){ |
|
|
|
|