Browse Source

添加清除科室地址缓存接口

lighter 7 months ago
parent
commit
22b607d600

+ 5 - 0
src/main/java/thyyxxk/wxservice_server/controller/AppointmentController.java

@@ -142,4 +142,9 @@ public class AppointmentController {
     public ResultVo<String> getDeptPos(@RequestParam("deptCode") String deptCode) {
         return ResultVoUtil.success(service.getDeptPos(deptCode));
     }
+
+    @GetMapping("/clearDeptPos")
+    public ResultVo<String> clearDeptPos() {
+        return ResultVoUtil.success(service.clearDeptPos());
+    }
 }

+ 4 - 0
src/main/java/thyyxxk/wxservice_server/service/AppointmentService.java

@@ -308,4 +308,8 @@ public class AppointmentService {
     public String getDeptPos(String deptCode) {
         return redis.getDeptPos(deptCode);
     }
+
+    public String clearDeptPos() {
+        return redis.clearDeptPos();
+    }
 }

+ 5 - 0
src/main/java/thyyxxk/wxservice_server/service/RedisLikeService.java

@@ -107,4 +107,9 @@ public class RedisLikeService {
         }
         return deptPos;
     }
+
+    public String clearDeptPos() {
+        deptPosMap.clear();
+        return "OK";
+    }
 }