YH-zlh
2023-09-06 85d7d8d3444dd931190603349cd4d961a9fd9114
eladmin-master/eladmin-system/src/main/java/me/zhengjie/modules/system/rest/UserController.java
@@ -19,6 +19,7 @@
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.RequiredArgsConstructor;
import me.zhengjie.annotation.AnonymousAccess;
import me.zhengjie.annotation.Log;
import me.zhengjie.config.RsaProperties;
import me.zhengjie.modules.system.domain.Dept;
@@ -29,6 +30,7 @@
import me.zhengjie.modules.system.service.DeptService;
import me.zhengjie.modules.system.service.RoleService;
import me.zhengjie.modules.system.service.dto.DeptDto;
import me.zhengjie.modules.system.service.dto.DeptUserNodeDto;
import me.zhengjie.modules.system.service.dto.RoleSmallDto;
import me.zhengjie.modules.system.service.dto.UserDto;
import me.zhengjie.modules.system.service.dto.UserQueryCriteria;
@@ -74,6 +76,12 @@
    @PreAuthorize("@el.check('user:download')")
    public void exportUser(HttpServletResponse response, UserQueryCriteria criteria) throws IOException {
        userService.download(userService.queryAll(criteria), response);
    }
    @GetMapping(value = "/dept/{deptId}")
    @AnonymousAccess
    public ResponseEntity<Object> queryDeptUserByDeptId(@PathVariable Long deptId) {
       return new ResponseEntity<>(userService.queryDeptUserByDeptId(deptId), HttpStatus.OK);
    }
    @GetMapping(value = "/all")
@@ -254,10 +262,10 @@
        return new ResponseEntity<>(userService.getUserCalendarInfo(month), HttpStatus.OK);
    }
    @GetMapping(value = "/getUserBaseInfo")
    @GetMapping(value = "/getUserBaseInfo/{yearMonth}")
    @Log("获取用户基础信息")
    @ApiOperation("获取用户日历信息")
    public ResponseEntity<Object> getUserBaseInfo() throws ParseException {
        return new ResponseEntity<>(userService.getUserBaseInfo(), HttpStatus.OK);
    public ResponseEntity<Object> getUserBaseInfo(@PathVariable Date yearMonth) throws ParseException {
        return new ResponseEntity<>(userService.getUserBaseInfo(yearMonth), HttpStatus.OK);
    }
}