|
@@ -69,6 +69,7 @@ import com.inkasso.factoring.tradingPlatform.entity.Platform;
|
|
import com.inkasso.factoring.tradingPlatform.service.ITradingPlatformService;
|
|
import com.inkasso.factoring.tradingPlatform.service.ITradingPlatformService;
|
|
import jodd.util.StringUtil;
|
|
import jodd.util.StringUtil;
|
|
import org.apache.commons.codec.binary.Base64;
|
|
import org.apache.commons.codec.binary.Base64;
|
|
|
|
+import org.apache.commons.math3.dfp.DfpField;
|
|
import org.apache.poi.xwpf.usermodel.XWPFTable;
|
|
import org.apache.poi.xwpf.usermodel.XWPFTable;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.beans.factory.annotation.Value;
|
|
import org.springframework.beans.factory.annotation.Value;
|
|
@@ -908,7 +909,8 @@ public class SettlementManagementServiceImpl extends ServiceImpl<SettlementBasic
|
|
for (SettlementGoodsInfo settlementGoodsInfo : settlementGoodsInfos) {
|
|
for (SettlementGoodsInfo settlementGoodsInfo : settlementGoodsInfos) {
|
|
Map<String, Object> map = new HashMap<>();
|
|
Map<String, Object> map = new HashMap<>();
|
|
CAcceptanceGoodsInfo acceptanceGoodsInfo = icAcceptanceGoodsInfoService.getById(settlementGoodsInfo.getAcceptanceGoodsInfoId());
|
|
CAcceptanceGoodsInfo acceptanceGoodsInfo = icAcceptanceGoodsInfoService.getById(settlementGoodsInfo.getAcceptanceGoodsInfoId());
|
|
- amountSum = amountSum.add(settlementGoodsInfo.getPurchaseTotalPrice());
|
|
|
|
|
|
+ BigDecimal purchasePrice = acceptanceGoodsInfo.getPurchasePrice() == null ? BigDecimal.ZERO : acceptanceGoodsInfo.getPurchasePrice();
|
|
|
|
+ amountSum = amountSum.add(purchasePrice.multiply(acceptanceGoodsInfo.getGoodsQuantity());
|
|
i = i + 1;
|
|
i = i + 1;
|
|
map.put("id", i);
|
|
map.put("id", i);
|
|
map.put("goodsName", acceptanceGoodsInfo.getGoodsName());
|
|
map.put("goodsName", acceptanceGoodsInfo.getGoodsName());
|
|
@@ -922,7 +924,7 @@ public class SettlementManagementServiceImpl extends ServiceImpl<SettlementBasic
|
|
num = num.add(settlementGoodsInfo.getGoodsQuantity());
|
|
num = num.add(settlementGoodsInfo.getGoodsQuantity());
|
|
}
|
|
}
|
|
dataMap.put("num", num);
|
|
dataMap.put("num", num);
|
|
- dataMap.put("amountSum", amountSum);
|
|
|
|
|
|
+ dataMap.put("amountSum", amountSum.setScale(2, RoundingMode.ROUND_HALF_UP));
|
|
}
|
|
}
|
|
dataMap.put("dealGoodsList", dealGoodsList);
|
|
dataMap.put("dealGoodsList", dealGoodsList);
|
|
File docxFile = null;
|
|
File docxFile = null;
|