File was renamed from ycl-platform/src/main/java/com/ycl/controller/UmsAdminController.java |
| | |
| | | package com.ycl.controller; |
| | | package com.ycl.controller.user; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ycl.api.CommonPage; |
| | | import com.ycl.api.CommonResult; |
| | |
| | | import com.ycl.entity.user.UmsRole; |
| | | import com.ycl.service.user.UmsAdminService; |
| | | import com.ycl.service.user.UmsRoleService; |
| | | import com.ycl.vo.user.UserVO; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | |
| | | return CommonResult.success(null); |
| | | } |
| | | |
| | | @ApiOperation("根据用户名或姓名分页获取用户列表") |
| | | @RequestMapping(value = "/list", method = RequestMethod.GET) |
| | | @ApiOperation("分页") |
| | | @RequestMapping(value = "/page", method = RequestMethod.GET) |
| | | @ResponseBody |
| | | public CommonResult<CommonPage<UmsAdmin>> list(@RequestParam(value = "keyword", required = false) String keyword, |
| | | @RequestParam(value = "pageSize", defaultValue = "5") Integer pageSize, |
| | | @RequestParam(value = "pageNum", defaultValue = "1") Integer pageNum) { |
| | | Page<UmsAdmin> adminList = adminService.list(keyword, pageSize, pageNum); |
| | | return CommonResult.success(CommonPage.restPage(adminList)); |
| | | public CommonResult<IPage<UmsAdmin>> list(@Validated UserVO.PageUserVO pageUserVO) { |
| | | IPage<UmsAdmin> page = adminService.pageUser(pageUserVO); |
| | | return CommonResult.success(page); |
| | | } |
| | | |
| | | @ApiOperation("获取指定用户信息") |