wangys 5 роки тому
батько
коміт
a8542c73ea

+ 2 - 2
efunbox-base/efunbox-base-web/src/main/java/cn/efunbox/manage/base/controller/ManageController.java

@@ -48,8 +48,8 @@ public class ManageController {
         return manageService.list(manageVO);
     }
 
-    @GetMapping("/export")
-    public void export( ManageVO manageVO, HttpServletResponse response) throws Exception{
+    @PostMapping("/export")
+    public void export(@RequestBody ManageVO manageVO, HttpServletResponse response) throws Exception{
         List<Long> deptIds = new ArrayList<>();
         if(null == manageVO.getDeptId() || manageVO.getDeptId().size() ==0){
             ApiResult<List<Department>> deptResult = departmentService.getDeptChild(12345l, DeptTypeEnum.COMPANY);

+ 5 - 5
manage-common/src/main/java/cn/efunbox/manage/common/intercepter/AdminInterceptor.java

@@ -34,11 +34,11 @@ public class AdminInterceptor implements HandlerInterceptor {
         }
         ServletOutputStream out = response.getOutputStream();
         String token = request.getHeader("uid");
-//        if (StringUtils.isBlank(token)) {
-//            ApiResult invalidTokenResult = ApiResult.error(ApiCode.INVALID_TOKEN);
-//            out.write(JSONObject.toJSONString(invalidTokenResult).getBytes("UTF-8"));
-//            return false;
-//        }
+        if (StringUtils.isBlank(token)) {
+            ApiResult invalidTokenResult = ApiResult.error(ApiCode.INVALID_TOKEN);
+            out.write(JSONObject.toJSONString(invalidTokenResult).getBytes("UTF-8"));
+            return false;
+        }
 //        String user = redisTemplate.opsForValue().get(Constants.EFUNBOX_ADMIN_TOKEN_PREFIX + token);
 //        if (StringUtils.isBlank(user)) {
 //            ApiResult invalidTokenResult = ApiResult.error(ApiCode.INVALID_TOKEN);