diff --git a/src/main/java/com/huoran/iasf/common/config/WebMvcConfigurer.java b/src/main/java/com/huoran/iasf/common/config/WebMvcConfigurer.java index 2538ed0..9d6ee9a 100644 --- a/src/main/java/com/huoran/iasf/common/config/WebMvcConfigurer.java +++ b/src/main/java/com/huoran/iasf/common/config/WebMvcConfigurer.java @@ -50,8 +50,8 @@ public class WebMvcConfigurer extends WebMvcConfigurationSupport { // corsConfiguration.addAllowedOrigin("*"); // 允许任何头 corsConfiguration.addAllowedOrigin("https://new.iasf.ac.cn"); //允许信任域名 corsConfiguration.addAllowedOrigin("https://www.iasf.ac.cn"); //允许信任域名 - corsConfiguration.addAllowedOrigin("http://192.168.31.125:8095"); //允许信任域名 - corsConfiguration.addAllowedOrigin("http://192.168.31.125:8089"); //允许信任域名 +// corsConfiguration.addAllowedOrigin("http://192.168.31.125:8095"); //允许信任域名 +// corsConfiguration.addAllowedOrigin("http://192.168.31.125:8088"); //允许信任域名 corsConfiguration.addAllowedOrigin("http://10.10.11.7"); //允许信任域名 corsConfiguration.addAllowedMethod("*"); // 允许任何方法(post、get等) return corsConfiguration; diff --git a/src/main/java/com/huoran/iasf/controller/SysFilesController.java b/src/main/java/com/huoran/iasf/controller/SysFilesController.java index 5aef0b0..0c8009c 100644 --- a/src/main/java/com/huoran/iasf/controller/SysFilesController.java +++ b/src/main/java/com/huoran/iasf/controller/SysFilesController.java @@ -22,6 +22,7 @@ import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiParam; import org.apache.commons.lang.StringUtils; +import org.apache.shiro.authz.annotation.Logical; import org.apache.shiro.authz.annotation.RequiresPermissions; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.bind.annotation.*; @@ -77,7 +78,7 @@ public class SysFilesController { @NoRepeatSubmit @ApiOperation(value = "新增") @PostMapping("/upload") - // @RequiresPermissions(value = {"sysFiles:add", "sysContent:update", "sysContent:add"}, logical = Logical.OR) +// @RequiresPermissions(value = {"sysFiles:add", "sysContent:update", "sysContent:add"}, logical = Logical.OR) public UEditorResultVO add( @RequestParam(required = false) String action, @RequestParam(value = "file") MultipartFile file, FileParameters fileParameters) throws Exception { diff --git a/src/main/java/com/huoran/iasf/controller/UserController.java b/src/main/java/com/huoran/iasf/controller/UserController.java index 753546c..e729516 100644 --- a/src/main/java/com/huoran/iasf/controller/UserController.java +++ b/src/main/java/com/huoran/iasf/controller/UserController.java @@ -109,6 +109,15 @@ public class UserController { return R.success(userResp); } + @PostMapping("/personalData") + @ApiOperation(value = "查询个人资料接口") + @LogAnnotation(title = "用户管理", action = "查询个人资料接口") + public R personalData() { + Integer currentUserId = httpSessionService.getCurrentUserId(); + UserListResp userResp = userService.detailInfo(currentUserId); + return R.success(userResp); + } + @PostMapping("/users") @ApiOperation(value = "分页获取用户列表接口") @RequiresPermissions("sys:user:list")