|
|
|
@ -88,11 +88,10 @@ public class AliPayServiceImpl implements AliPayService {
|
|
|
|
|
companyById.getUserBalance() : DefaultNumberConstants.ZERO_NUMBER;
|
|
|
|
|
companyService.updateUserBalanceByCompanyId
|
|
|
|
|
(NumberUtil.add(balance, order.getAmount()), companyId);
|
|
|
|
|
|
|
|
|
|
redisUtils.set("call_sms:" + companyId, 0);
|
|
|
|
|
payOrderRepository.save(order);
|
|
|
|
|
return ResponseCode.SUCCESS.getDesc();
|
|
|
|
|
}
|
|
|
|
|
payOrderRepository.save(order);
|
|
|
|
|
return ResponseCode.SUCCESS.getDesc();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
} catch (Exception e) {
|
|
|
|
@ -113,9 +112,9 @@ public class AliPayServiceImpl implements AliPayService {
|
|
|
|
|
valueStr = (i == values.length - 1) ? valueStr + values[i]
|
|
|
|
|
: valueStr + values[i] + StrPool.COMMA;
|
|
|
|
|
}
|
|
|
|
|
//乱码解决,这段代码在出现乱码时使用
|
|
|
|
|
/* //乱码解决,这段代码在出现乱码时使用
|
|
|
|
|
valueStr = new String(valueStr.getBytes
|
|
|
|
|
(StandardCharsets.ISO_8859_1), StandardCharsets.UTF_8);
|
|
|
|
|
(StandardCharsets.ISO_8859_1), StandardCharsets.UTF_8);*/
|
|
|
|
|
params.put(stringEntry.getKey(), valueStr);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -132,7 +131,7 @@ public class AliPayServiceImpl implements AliPayService {
|
|
|
|
|
AlipayTradePagePayResponse response = Factory.Payment.Page()
|
|
|
|
|
.pay(PayConstants.PAY_TITLE + orderNo,
|
|
|
|
|
orderNo, aliPayPcDTO.getAmount().toString(),
|
|
|
|
|
aliPay.getNotifyUrl());
|
|
|
|
|
aliPay.getReturnUrl());
|
|
|
|
|
if (ResponseChecker.success(response)) {
|
|
|
|
|
boolean result = savePayOrder(aliPayPcDTO, orderNo);
|
|
|
|
|
log.info("============= the save order result {} =============", result);
|
|
|
|
|