瀏覽代碼

更新商品模块redis缓存

chao 4 年之前
父節點
當前提交
50e1d1d766

+ 3 - 3
src/main/java/com/caimei/modules/cmpage/web/CmPageCentreController.java

@@ -109,7 +109,7 @@ public class CmPageCentreController extends BaseController {
         addMessage(redirectAttributes, "保存成功");
         if ("5".equals(cmPageCentre.getType())) {
             //清除产品仪器缓存
-            redisService.removePattern("instrumentData*");
+            redisService.removePattern("instrumentData*");redisService.removePattern("insCommodityData*");
         } else if ("6".equals(cmPageCentre.getType())) {
             //清除活动专题缓存
             redisService.removePattern("activityData*");
@@ -206,7 +206,7 @@ public class CmPageCentreController extends BaseController {
                 }
             }
             //清除产品仪器缓存
-            redisService.removePattern("instrumentData*");
+            redisService.removePattern("instrumentData*");redisService.removePattern("insCommodityData*");
             //清除活动专题缓存
             redisService.removePattern("activityData*");
             map.put("success", true);
@@ -230,4 +230,4 @@ public class CmPageCentreController extends BaseController {
         }
         return "modules/newhome/newPageFloorContentForm";
     }
-}
+}

+ 1 - 1
src/main/java/com/caimei/modules/newhome/web/NewPageFloorController.java

@@ -306,7 +306,7 @@ public class NewPageFloorController extends BaseController {
             return "redirect:" + Global.getAdminPath() + "/cmpage/cmPageCentre/?pageId=" + floorContent.getPageId() + "&type=6";
         } else {
             //清除产品仪器缓存
-            redisService.removePattern("instrumentData*");
+            redisService.removePattern("instrumentData*");redisService.removePattern("insCommodityData*");
             return "redirect:" + Global.getAdminPath() + "/cmpage/cmPageCentre/?pageId=" + floorContent.getPageId() + "&type=5";
         }
     }

+ 1 - 0
src/main/java/com/caimei/modules/product/web/CmSmalltypeController.java

@@ -199,6 +199,7 @@ public class CmSmalltypeController extends BaseController {
 		//分类缓存
 		String productClassify = "getClassify*";
 		redisService.removePattern(productClassify);
+		redisService.removePattern("getCommodityClassify*");
 	}
 	/**
 	 * 获取二级分类

+ 1 - 0
src/main/java/com/caimei/modules/product/web/CmTinytypeController.java

@@ -324,6 +324,7 @@ public class CmTinytypeController extends BaseController {
         //分类缓存
         String productClassify = "getClassify*";
         redisService.removePattern(productClassify);
+        redisService.removePattern("getCommodityClassify*");
 	}
 
 	/**