Commit f9cddd34 by 王军业

【统计值小数位2】

1 parent 83c49aa0
......@@ -463,18 +463,18 @@ public class ContractServiceImpl implements ContractService {
}
List<ContractVo> listAll = contractMapper.selectByConditionAll(selectVo);
BigDecimal contract_amount = new BigDecimal(0.00);
contract_amount.setScale(4);//合同金额
contract_amount.setScale(4,BigDecimal.ROUND_HALF_UP);//合同金额
BigDecimal total_reback_amount = new BigDecimal(0.00); //
total_reback_amount.setScale(4);
total_reback_amount.setScale(4,BigDecimal.ROUND_HALF_UP);
BigDecimal contract_remain=new BigDecimal(0.00);;
contract_remain.setScale(4);
contract_remain.setScale(4,BigDecimal.ROUND_HALF_UP);
BigDecimal total_amount_remain=new BigDecimal(0.00);;
total_amount_remain.setScale(4);
total_amount_remain.setScale(4,BigDecimal.ROUND_HALF_UP);
for(ContractVo contractVo : listAll){
contract_amount = contract_amount.add(new BigDecimal(contractVo.getContract_amount()).setScale(4)); //+= contractVo.getContract_amount();
total_reback_amount = total_reback_amount.add(new BigDecimal(contractVo.getTotal_reback_amount()).setScale(4));
contract_remain = contract_remain.add(new BigDecimal(contractVo.getContract_remain()).setScale(4));
total_amount_remain = total_amount_remain.add(new BigDecimal(contractVo.getTotal_amount_remain()).setScale(4));
contract_amount = contract_amount.add(new BigDecimal(contractVo.getContract_amount()).setScale(4,BigDecimal.ROUND_HALF_UP)); //+= contractVo.getContract_amount();
total_reback_amount = total_reback_amount.add(new BigDecimal(contractVo.getTotal_reback_amount()).setScale(4,BigDecimal.ROUND_HALF_UP));
contract_remain = contract_remain.add(new BigDecimal(contractVo.getContract_remain()).setScale(4,BigDecimal.ROUND_HALF_UP));
total_amount_remain = total_amount_remain.add(new BigDecimal(contractVo.getTotal_amount_remain()).setScale(4,BigDecimal.ROUND_HALF_UP));
//total_reback_amount += contractVo.getTotal_reback_amount();
//contract_remain += contractVo.getContract_remain();
//total_amount_remain += contractVo.getTotal_amount_remain();
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!