Quellcode durchsuchen

Update ArticleCategoryController: remove cross-origin

StrayWarrior vor 6 Monaten
Ursprung
Commit
5f182aee38

+ 1 - 1
long-article-recommend-service/src/main/java/com/tzld/longarticle/recommend/server/config/ManagementServiceConfiguration.java

@@ -9,7 +9,7 @@ import org.springframework.context.annotation.Configuration;
 
 @Configuration
 public class ManagementServiceConfiguration implements WebServerFactoryCustomizer<TomcatServletWebServerFactory> {
-    @Value("${server.management.port:8081}")
+    @Value("${server.internal-port:8081}")
     private Integer port;
 
     @Override

+ 1 - 1
long-article-recommend-service/src/main/java/com/tzld/longarticle/recommend/server/web/InternalApiFilter.java

@@ -12,7 +12,7 @@ import java.io.IOException;
 
 @Component
 public class InternalApiFilter extends OncePerRequestFilter {
-    @Value("${server.management.port:8081}")
+    @Value("${server.internal-port:8081}")
     private Integer port;
 
     private static final String INTERNAL_API_PATH = "/internal";

+ 0 - 2
long-article-recommend-service/src/main/java/com/tzld/longarticle/recommend/server/web/recommend/ArticleCategoryController.java

@@ -19,13 +19,11 @@ public class ArticleCategoryController {
     private ArticleCategoryService service;
 
     @PostMapping("/list")
-    @CrossOrigin
     public CommonResponse<Page<ArticleCategoryListVO>> articleCategoryList(@RequestBody ArticleCategoryListParam param) {
         return CommonResponse.success(service.articleCategoryList(param));
     }
 
     @PostMapping("/updateCategory")
-    @CrossOrigin
     public CommonResponse<Void> articleCategoryUpdate(@RequestBody ArticleCategoryUpdateParam param) {
         service.articleCategoryUpdate(param);
         return CommonResponse.success();