From 6a86b993e89ce5d90c8707f2855aa1fe183d4b73 Mon Sep 17 00:00:00 2001 From: kongdeqiang <123456> Date: 星期三, 15 十一月 2023 09:33:10 +0800 Subject: [PATCH] 修改 --- src/main/java/com/boying/controller/phone/YCPayController.java | 22 +++++++++++++--------- 1 files changed, 13 insertions(+), 9 deletions(-) diff --git a/src/main/java/com/boying/controller/phone/YCPayController.java b/src/main/java/com/boying/controller/phone/YCPayController.java index c48444d..51b5ee0 100644 --- a/src/main/java/com/boying/controller/phone/YCPayController.java +++ b/src/main/java/com/boying/controller/phone/YCPayController.java @@ -16,6 +16,7 @@ import com.boying.util.HTTPEntityUtil; import com.google.gson.Gson; import lombok.RequiredArgsConstructor; +import org.springframework.beans.factory.annotation.Autowired; import org.springframework.http.ResponseEntity; import org.springframework.web.bind.annotation.*; @@ -52,6 +53,7 @@ private final OrderRecordService orderRecordService; private final TicketService ticketService; private final TicketBlackService ticketBlackService; + private final SystemConfigProperties systemConfigProperties; private final WhiteListService whiteListService; private final EnterParkService enterParkService; @@ -149,6 +151,7 @@ public Object parkXT(Long id){ SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd_HH:mm:ss"); OutPark outPark = outParkService.getById(id); + System.out.println("id:"+id); if(outPark.getPrice()==0){ updateOutPark(outPark.getId(),"03"); return R.failed("鏈鍋滆溅鏃犻渶鏀粯璐圭敤"); @@ -220,14 +223,14 @@ Map<String,Object> map = new HashMap<>(); map.put("encoding","UTF-8"); map.put("signMethod","01"); - map.put("sdkAppId","8202309110000001"); + map.put("sdkAppId",systemConfigProperties.getXTYHMERID()); map.put("txnType","1007"); map.put("txnSubType","100702"); map.put("txnAccType","03"); map.put("aesWay","01"); - map.put("merId","8202309110000001"); - map.put("merName","閭兏甯傚嘲宄扮熆鍖烘粡婧愬缓璁惧彂灞曟湁闄愬叕鍙�"); - map.put("backEndUrl","http://39.96.92.240:8089/ffzf/api/getResult"); + map.put("merId",systemConfigProperties.getXTYHMERID()); + map.put("merName",systemConfigProperties.getXTYHMERNAME()); + map.put("backEndUrl",systemConfigProperties.getXTYHRESULT()); map.put("txnOrderId",outPark.getId()+""+format); map.put("txnOrderTime",format); map.put("txnOrderBody",outPark.getCarNo()+"娉婅溅缂磋垂"); @@ -296,6 +299,7 @@ */ @PostMapping("payByWX") public Object payByWX(Long id,String openId){ + System.out.println("寮�濮嬫敮浠�"); OutPark outPark = outParkService.getById(id); String xtyhpay = systemConfigProperties.getXTYHPAY(); SimpleDateFormat sdf = new SimpleDateFormat("yyyyMMddHHmmss"); @@ -304,17 +308,17 @@ Map<String,Object> map = new HashMap<>(); map.put("encoding","UTF-8"); map.put("signMethod","01"); - map.put("sdkAppId","8202309110000001"); + map.put("sdkAppId",systemConfigProperties.getXTYHMERID()); map.put("txnType","1006"); map.put("txnSubType","100603"); map.put("txnAccType","02"); - map.put("secMerAppId","wx46e756aed958f895"); + map.put("secMerAppId",systemConfigProperties.getXTYHAPPID()); map.put("txnSubOpenid",openId); map.put("txnProductId",outPark.getId()+""); map.put("aesWay","01"); - map.put("merId","8202309110000001"); - map.put("merName","閭兏甯傚嘲宄扮熆鍖烘粡婧愬缓璁惧彂灞曟湁闄愬叕鍙�"); - map.put("backEndUrl","http://39.96.92.240:8089/ffzf/api/getResult"); + map.put("merId",systemConfigProperties.getXTYHMERID()); + map.put("merName",systemConfigProperties.getXTYHMERNAME()); + map.put("backEndUrl",systemConfigProperties.getXTYHRESULT()); map.put("txnOrderId",outPark.getId()+""+format); map.put("txnOrderTime",format); map.put("txnOrderBody",outPark.getCarNo()+"娉婅溅缂磋垂"); -- Gitblit v1.9.1