mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-05-17 00:08:35 +08:00
Merge branch 'dev' of http://192.168.2.2:8099/jsowell/jsowell-charger-web into dev
This commit is contained in:
@@ -73,19 +73,27 @@ public class AdapayMemberService {
|
|||||||
// 银行卡对应的户名
|
// 银行卡对应的户名
|
||||||
accountInfo.put("card_name", dto.getCardName());
|
accountInfo.put("card_name", dto.getCardName());
|
||||||
// 证件号,银行账户类型为对私时,必填
|
// 证件号,银行账户类型为对私时,必填
|
||||||
accountInfo.put("cert_id", dto.getCertId());
|
if (StringUtils.isNotBlank(dto.getCertId())) {
|
||||||
|
accountInfo.put("cert_id", dto.getCertId());
|
||||||
|
}
|
||||||
// 证件类型,仅支持:00-身份证,银行账户类型为对私时,必填
|
// 证件类型,仅支持:00-身份证,银行账户类型为对私时,必填
|
||||||
accountInfo.put("cert_type", "00");
|
accountInfo.put("cert_type", "00");
|
||||||
// 手机号
|
// 手机号
|
||||||
accountInfo.put("tel_no", dto.getTelNo());
|
accountInfo.put("tel_no", dto.getTelNo());
|
||||||
// 银行编码,详见附录 银行代码,银行账户类型对公时,必填
|
// 银行编码,详见附录 银行代码,银行账户类型对公时,必填
|
||||||
accountInfo.put("bank_code", dto.getBankCode());
|
if (StringUtils.isNotBlank(dto.getBankCode())) {
|
||||||
|
accountInfo.put("bank_code", dto.getBankCode());
|
||||||
|
}
|
||||||
// 银行账户类型:1-对公;2-对私
|
// 银行账户类型:1-对公;2-对私
|
||||||
accountInfo.put("bank_acct_type", dto.getBankAcctType());
|
accountInfo.put("bank_acct_type", dto.getBankAcctType());
|
||||||
// 银行账户开户银行所在省份编码 (省市编码),银行账户类型为对公时,必填
|
// 银行账户开户银行所在省份编码 (省市编码),银行账户类型为对公时,必填
|
||||||
accountInfo.put("prov_code", dto.getProvCode());
|
if (StringUtils.isNotBlank(dto.getProvCode())) {
|
||||||
|
accountInfo.put("prov_code", dto.getProvCode());
|
||||||
|
}
|
||||||
// 银行账户开户银行所在地区编码(省市编码),银行账户类型为对公时,必填
|
// 银行账户开户银行所在地区编码(省市编码),银行账户类型为对公时,必填
|
||||||
accountInfo.put("area_code", dto.getAreaCode());
|
if (StringUtils.isNotBlank(dto.getAreaCode())) {
|
||||||
|
accountInfo.put("area_code", dto.getAreaCode());
|
||||||
|
}
|
||||||
|
|
||||||
Map<String, Object> settleCountParams = Maps.newHashMap();
|
Map<String, Object> settleCountParams = Maps.newHashMap();
|
||||||
settleCountParams.put("member_id", adapayMemberId);
|
settleCountParams.put("member_id", adapayMemberId);
|
||||||
@@ -93,6 +101,7 @@ public class AdapayMemberService {
|
|||||||
// channel String Y 目前仅支持:bank_account(银行卡)
|
// channel String Y 目前仅支持:bank_account(银行卡)
|
||||||
settleCountParams.put("channel", "bank_account");
|
settleCountParams.put("channel", "bank_account");
|
||||||
settleCountParams.put("account_info", accountInfo);
|
settleCountParams.put("account_info", accountInfo);
|
||||||
|
log.info("创建汇付结算账户param:{}", settleCountParams);
|
||||||
Map<String, Object> settleCount = SettleAccount.create(settleCountParams);
|
Map<String, Object> settleCount = SettleAccount.create(settleCountParams);
|
||||||
log.info("创建汇付结算账户result:{}", settleCount);
|
log.info("创建汇付结算账户result:{}", settleCount);
|
||||||
|
|
||||||
|
|||||||
@@ -757,6 +757,10 @@ public class OrderBasicInfoServiceImpl implements IOrderBasicInfoService {
|
|||||||
totalElectricityAmount = totalElectricityAmount.add(multiply);
|
totalElectricityAmount = totalElectricityAmount.add(multiply);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 如果算出来的电费金额大于总消费金额,则电费金额等于总消费金额
|
||||||
|
if (totalElectricityAmount.compareTo(orderAmount) > 0) {
|
||||||
|
totalElectricityAmount = orderAmount;
|
||||||
|
}
|
||||||
orderDetail.setTotalElectricityAmount(totalElectricityAmount);
|
orderDetail.setTotalElectricityAmount(totalElectricityAmount);
|
||||||
orderDetail.setTotalServiceAmount(orderAmount.subtract(totalElectricityAmount));
|
orderDetail.setTotalServiceAmount(orderAmount.subtract(totalElectricityAmount));
|
||||||
orderDetail.setTotalUsedElectricity(new BigDecimal(data.getTotalElectricity())); // 总用电量
|
orderDetail.setTotalUsedElectricity(new BigDecimal(data.getTotalElectricity())); // 总用电量
|
||||||
|
|||||||
Reference in New Issue
Block a user