获取所有收藏帖子

Change-Id: I599df61bff71f48b80849bd4b75236a8c4529d91
diff --git a/src/main/java/com/example/myproject/controller/PostController.java b/src/main/java/com/example/myproject/controller/PostController.java
index 63fcbe8..4233028 100644
--- a/src/main/java/com/example/myproject/controller/PostController.java
+++ b/src/main/java/com/example/myproject/controller/PostController.java
@@ -90,5 +90,11 @@
         return "Post uncollected successfully!";
     }
 
+    // 获取用户收藏的所有帖子
+    @GetMapping("/{userId}/getAllcollections")
+    public List<Map<String, Object>> getAllCollections(@PathVariable("userId") Long userId) {
+        return postService.getAllCollections(userId);
+    }
+
 
 }