如果结算金额为0,减去优惠金额后为负数,还设置为0

This commit is contained in:
2024-02-19 11:36:55 +08:00
parent 5aed246b69
commit 092111bf91
2 changed files with 4 additions and 19 deletions

View File

@@ -59,25 +59,6 @@ public class BillingTemplateValidateRequestHandler extends AbstractHandler{
byte[] billingTemplateCodeByte = BytesUtil.copyBytes(msgBody, startIndex, length);
String billingTemplateCode = BytesUtil.binary(billingTemplateCodeByte, 16);
// 根据桩号查询计费模板
// BillingTemplateVO billingTemplateVO = pileBillingTemplateService.selectBillingTemplateDetailByPileSn(pileSn);
// String templateCode = null;
// if (billingTemplateVO != null) {
// templateCode = billingTemplateVO.getTemplateCode();
// }
// log.info("桩传的计费模型编码:{}, 根据桩号:{} 查询到的计费模型编码:{}", billingTemplateCode, pileSn, templateCode);
// log.info("桩传的计费模型编码:{}", billingTemplateCode);
/**
* 应答 0x00 桩计费模型与平台一致 0x01 桩计费模型与平台不一致
*/
// byte[] flag;
// if (StringUtils.equals(billingTemplateCode, "100")){
// flag = Constants.zeroByteArray;
// }else {
// }
byte[] flag = Constants.oneByteArray;
// 消息体
byte[] messageBody = Bytes.concat(pileSnByte, billingTemplateCodeByte, flag);