Browse Source

修改存储到redis中的消息

gaohp 1 year ago
parent
commit
4b9099772a

+ 1 - 1
feifan-module-sale/feifan-module-sale-biz/src/main/java/cn/newfeifan/mall/sale/service/merchant/MerchantServiceImpl.java

@@ -150,7 +150,7 @@ public class MerchantServiceImpl implements MerchantService {
 
         // 查询用户的商户信息,并且缓存到redis中
         OAuth2AccessTokenDO oAuth2AccessTokenDO = message.getOAuth2AccessTokenDO();
-        ShopMessage shopMessage = JsonUtils.parseObject(stringRedisTemplate.opsForValue().get("shop:" + message.getOAuth2AccessTokenDO().getAccessToken()), ShopMessage.class);
+        ShopMessage shopMessage = JsonUtils.parseObject(stringRedisTemplate.opsForValue().get("shop:" + message.getOAuth2AccessTokenDO().getUserId()), ShopMessage.class);
         if (shopMessage != null) {
             // 刷新时间
             stringRedisTemplate.opsForValue().set("shop:" + oAuth2AccessTokenDO.getUserId(), JsonUtils.toJsonString(shopMessage), 3600 * 24, TimeUnit.SECONDS);

+ 1 - 1
feifan-server/src/main/resources/application-local.yaml

@@ -146,7 +146,7 @@ spring:
     admin:
       # Spring Boot Admin Client 客户端的相关配置
       client:
-        url: http://10.0.5.227:${server.port}/${spring.boot.admin.context-path} # 设置 Spring Boot Admin Server 地址
+        url: http://10.0.5.228:${server.port}/${spring.boot.admin.context-path} # 设置 Spring Boot Admin Server 地址
         instance:
           service-host-type: IP # 注册实例时,优先使用 IP [IP, HOST_NAME, CANONICAL_HOST_NAME]
       # Spring Boot Admin Server 服务端的相关配置