格式化代码

This commit is contained in:
Binary Wang 2017-04-18 11:17:57 +08:00
parent 5c78a11319
commit 1efec6bc75

View File

@ -196,10 +196,9 @@ public class WxPayServiceImpl implements WxPayService {
}
Map<String, String> payInfo = new HashMap<>();
if ("NATIVE".equals(request.getTradeType()))
{
if ("NATIVE".equals(request.getTradeType())) {
payInfo.put("codeUrl", unifiedOrderResult.getCodeURL());
}else if ("APP".equals(request.getTradeType())){
} else if ("APP".equals(request.getTradeType())) {
// APP支付绑定的是微信开放平台上的账号APPID为开放平台上绑定APP后发放的参数
String appId = getConfig().getAppId();
Map<String, String> configMap = new HashMap<>();
@ -219,7 +218,7 @@ public class WxPayServiceImpl implements WxPayService {
payInfo.put("packageValue", "Sign=WXPay");
payInfo.put("timeStamp", String.valueOf(System.currentTimeMillis() / 1000));
payInfo.put("nonceStr", String.valueOf(System.currentTimeMillis()));
}else if ("JSAPI".equals(request.getTradeType())){
} else if ("JSAPI".equals(request.getTradeType())) {
payInfo.put("appId", unifiedOrderResult.getAppid());
// 支付签名时间戳注意微信jssdk中的所有使用timestamp字段均为小写但最新版的支付后台生成签名使用的timeStamp字段名需大写其中的S字符
payInfo.put("timeStamp", String.valueOf(System.currentTimeMillis() / 1000));