zyx 2 tahun lalu
induk
melakukan
a0ab3f1bac

+ 5 - 1
src/main/java/com/sxtvs/open/api/odata/controller/OauthRestController.java

@@ -24,8 +24,12 @@ public class OauthRestController {
     @NoAPIResponse
     @NoAPIResponse
     public String auth(@RequestBody String body) {
     public String auth(@RequestBody String body) {
         logger.info("body", body, "key", "oauth/weixin/auth");
         logger.info("body", body, "key", "oauth/weixin/auth");
-        String xml = WxCrypt.decrypt(WxXmlUtil.getEncrypt(body));
+        var encrypt = WxXmlUtil.getEncrypt(body);
+        logger.info("data", encrypt);
+        String xml = WxCrypt.decrypt(encrypt);
+        logger.info("data", xml);
         String componentVerifyTicket = WxXmlUtil.getComponentVerifyTicket(xml);
         String componentVerifyTicket = WxXmlUtil.getComponentVerifyTicket(xml);
+        logger.info("data", componentVerifyTicket);
         redisTemplate.opsForValue().set("WX_TICKET", componentVerifyTicket);
         redisTemplate.opsForValue().set("WX_TICKET", componentVerifyTicket);
         return "success";
         return "success";
     }
     }