加入反扫金额校验

This commit is contained in:
lyf
2023-02-24 15:11:06 +08:00
parent c03ec8d1dc
commit 33950f8101
3 changed files with 19 additions and 2 deletions

View File

@@ -413,6 +413,10 @@ public class MerchantOrderController {
public Result<Object> scanPay(@RequestBody MerChantOrderDTO merchantOrderDTO) {
UserApp tokenUa = userAppService.queryUserAppByToken();
merchantOrderDTO.setMerchantCode(tokenUa.getMerchantCode());
//校验金额
if (!StringUtil.isMoney(String.valueOf(merchantOrderDTO.getConsumeFee()))){
MsgException.throwException("金额异常");
}
try {
return merchantOrderService.toActivePay(merchantOrderDTO);
} catch (Exception e){