update 首页订单金额数据汇总采用总结算金额(已经与实收金额对比过,取二者大于0的最小值)

This commit is contained in:
Lemon
2025-08-05 16:17:12 +08:00
parent c3cc8704fd
commit 5fddbd8e8c
3 changed files with 8 additions and 1 deletions

View File

@@ -991,7 +991,8 @@ public class PileBasicInfoServiceImpl implements PileBasicInfoService {
if (SecurityUtils.getUsername().equals("demo")) { if (SecurityUtils.getUsername().equals("demo")) {
BigDecimal bigDecimal = new BigDecimal(Constants.THREE); BigDecimal bigDecimal = new BigDecimal(Constants.THREE);
log.info("demo账号, begin:{}", JSON.toJSONString(generalInfo)); log.info("demo账号, begin:{}", JSON.toJSONString(generalInfo));
generalInfo.setTotalChargingAmount(new BigDecimal(generalInfo.getTotalChargingAmount()).multiply(bigDecimal).toString()); // generalInfo.setTotalChargingAmount(new BigDecimal(generalInfo.getTotalChargingAmount()).multiply(bigDecimal).toString());
generalInfo.setTotalChargingAmount(new BigDecimal(generalInfo.getTotalSettleAmount()).multiply(bigDecimal).toString());
generalInfo.setTotalPileQuantity(new BigDecimal(generalInfo.getTotalPileQuantity()).multiply(bigDecimal).toString()); generalInfo.setTotalPileQuantity(new BigDecimal(generalInfo.getTotalPileQuantity()).multiply(bigDecimal).toString());
generalInfo.setTotalChargingDegree(new BigDecimal(generalInfo.getTotalChargingDegree()).multiply(bigDecimal).toString()); generalInfo.setTotalChargingDegree(new BigDecimal(generalInfo.getTotalChargingDegree()).multiply(bigDecimal).toString());
generalInfo.setTotalChargingQuantity(new BigDecimal(generalInfo.getTotalChargingQuantity()).multiply(bigDecimal).toString()); generalInfo.setTotalChargingQuantity(new BigDecimal(generalInfo.getTotalChargingQuantity()).multiply(bigDecimal).toString());

View File

@@ -20,6 +20,11 @@ public class IndexGeneralSituationVO {
*/ */
private String totalChargingAmount; private String totalChargingAmount;
/**
* 总结算金额
*/
private String totalSettleAmount;
/** /**
* 总充电笔数 * 总充电笔数
*/ */

View File

@@ -401,6 +401,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="getGeneralSituationInfo" resultType="com.jsowell.pile.vo.web.IndexGeneralSituationVO"> <select id="getGeneralSituationInfo" resultType="com.jsowell.pile.vo.web.IndexGeneralSituationVO">
select select
ifnull(sum(t1.total_amount), 0) as totalChargingAmount, ifnull(sum(t1.total_amount), 0) as totalChargingAmount,
ifnull(sum(t1.settle_amount), 0) as totalSettleAmount,
ifnull(sum(t1.use_electricity), 0) as totalChargingDegree, ifnull(sum(t1.use_electricity), 0) as totalChargingDegree,
ifnull(sum(t1.charge_num), 0) as totalChargingQuantity ifnull(sum(t1.charge_num), 0) as totalChargingQuantity
from from