Commit c2f8f135 by 王祖波

周月报

parent 75f5e432
...@@ -163,7 +163,7 @@ public class WeekMonthDataAdaptor { ...@@ -163,7 +163,7 @@ public class WeekMonthDataAdaptor {
if (jsonObject == null) { if (jsonObject == null) {
return null; return null;
} }
BigDecimal useMatlNum = jsonObject.getBigDecimal("useMatlNum"); BigDecimal useMatlNum = Optional.ofNullable(jsonObject.getBigDecimal("useMatlNum")).orElse(BigDecimal.ZERO);
BigDecimal convSalesAmt = Optional.ofNullable(jsonObject.getBigDecimal("omniConvSalesAmt")).orElse(BigDecimal.ZERO); BigDecimal convSalesAmt = Optional.ofNullable(jsonObject.getBigDecimal("omniConvSalesAmt")).orElse(BigDecimal.ZERO);
return formatDecimal(useMatlNum,convSalesAmt); return formatDecimal(useMatlNum,convSalesAmt);
} }
......
...@@ -143,7 +143,10 @@ public class WeekMonthReportBuilder { ...@@ -143,7 +143,10 @@ public class WeekMonthReportBuilder {
return; return;
} }
// 生成图片地址 // 生成图片地址
String url = DrawImageUtils.drawImage(context.getFactoryCode(), materialDataResult.getFirstValue(), materialDataResult.getSecondValue(), templatePath); String url = DrawImageUtils.drawImage(context.getFactoryCode(),
StringUtils.isBlank(materialDataResult.getFirstValue())?"0":materialDataResult.getFirstValue(),
StringUtils.isBlank(materialDataResult.getSecondValue())?"0":materialDataResult.getSecondValue(),
templatePath);
context.setMaterialReportUrl(url); context.setMaterialReportUrl(url);
} }
......
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