|
@@ -1,5 +1,28 @@
|
|
package com.warewms.system.controller.system;
|
|
package com.warewms.system.controller.system;
|
|
|
|
|
|
|
|
+
|
|
|
|
+import java.util.List;
|
|
|
|
+import java.util.Map;
|
|
|
|
+import java.util.stream.Collectors;
|
|
|
|
+import javax.servlet.http.HttpServletResponse;
|
|
|
|
+
|
|
|
|
+import com.warewms.common.core.domain.base.page.PageDomain;
|
|
|
|
+import com.warewms.common.core.domain.base.page.TableDataInfo;
|
|
|
|
+import com.warewms.common.core.domain.entity.SysDictType;
|
|
|
|
+import com.warewms.common.utils.bean.BeanUtils;
|
|
|
|
+import org.apache.commons.lang3.ArrayUtils;
|
|
|
|
+import org.springframework.beans.factory.annotation.Autowired;
|
|
|
|
+import org.springframework.security.access.prepost.PreAuthorize;
|
|
|
|
+import org.springframework.validation.annotation.Validated;
|
|
|
|
+import org.springframework.web.bind.annotation.DeleteMapping;
|
|
|
|
+import org.springframework.web.bind.annotation.GetMapping;
|
|
|
|
+import org.springframework.web.bind.annotation.PathVariable;
|
|
|
|
+import org.springframework.web.bind.annotation.PostMapping;
|
|
|
|
+import org.springframework.web.bind.annotation.PutMapping;
|
|
|
|
+import org.springframework.web.bind.annotation.RequestBody;
|
|
|
|
+import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
|
+import org.springframework.web.bind.annotation.RestController;
|
|
|
|
+import org.springframework.web.multipart.MultipartFile;
|
|
import com.warewms.common.annotation.Log;
|
|
import com.warewms.common.annotation.Log;
|
|
import com.warewms.common.core.controller.BaseController;
|
|
import com.warewms.common.core.controller.BaseController;
|
|
import com.warewms.common.core.domain.AjaxResult;
|
|
import com.warewms.common.core.domain.AjaxResult;
|
|
@@ -14,16 +37,7 @@ import com.warewms.system.service.ISysDeptService;
|
|
import com.warewms.system.service.ISysPostService;
|
|
import com.warewms.system.service.ISysPostService;
|
|
import com.warewms.system.service.ISysRoleService;
|
|
import com.warewms.system.service.ISysRoleService;
|
|
import com.warewms.system.service.ISysUserService;
|
|
import com.warewms.system.service.ISysUserService;
|
|
-import org.apache.commons.lang3.ArrayUtils;
|
|
|
|
-import org.springframework.beans.factory.annotation.Autowired;
|
|
|
|
-import org.springframework.security.access.prepost.PreAuthorize;
|
|
|
|
-import org.springframework.validation.annotation.Validated;
|
|
|
|
-import org.springframework.web.bind.annotation.*;
|
|
|
|
-import org.springframework.web.multipart.MultipartFile;
|
|
|
|
|
|
|
|
-import javax.servlet.http.HttpServletResponse;
|
|
|
|
-import java.util.List;
|
|
|
|
-import java.util.stream.Collectors;
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
* 用户信息
|
|
* 用户信息
|
|
@@ -32,7 +46,7 @@ import java.util.stream.Collectors;
|
|
*/
|
|
*/
|
|
@RestController
|
|
@RestController
|
|
@RequestMapping("/system/user")
|
|
@RequestMapping("/system/user")
|
|
-public class SysUserController extends BaseController
|
|
|
|
|
|
+public class SysUserController extends BaseController<SysUser>
|
|
{
|
|
{
|
|
@Autowired
|
|
@Autowired
|
|
private ISysUserService userService;
|
|
private ISysUserService userService;
|
|
@@ -49,14 +63,17 @@ public class SysUserController extends BaseController
|
|
/**
|
|
/**
|
|
* 获取用户列表
|
|
* 获取用户列表
|
|
*/
|
|
*/
|
|
- /*@PreAuthorize("@ss.hasPermi('system:user:list')")
|
|
|
|
|
|
+ @PreAuthorize("@ss.hasPermi('system:user:list')")
|
|
@GetMapping("/list")
|
|
@GetMapping("/list")
|
|
- public TableDataInfo list(SysUser user)
|
|
|
|
|
|
+ public TableDataInfo list(PageDomain pageDomain,SysUser user)
|
|
{
|
|
{
|
|
- startPage();
|
|
|
|
|
|
+ /*startPage();
|
|
List<SysUser> list = userService.selectUserList(user);
|
|
List<SysUser> list = userService.selectUserList(user);
|
|
- return getDataTable(list);
|
|
|
|
- }*/
|
|
|
|
|
|
+ return getDataTable(list);*/
|
|
|
|
+ Map<String, Object> pageParams = BeanUtils.beanToMap(pageDomain);
|
|
|
|
+ Map<String, Object> params = BeanUtils.beanToMap(user, pageParams);
|
|
|
|
+ return getDataTable(userService.page(params));
|
|
|
|
+ }
|
|
|
|
|
|
@Log(title = "用户管理", businessType = BusinessType.EXPORT)
|
|
@Log(title = "用户管理", businessType = BusinessType.EXPORT)
|
|
@PreAuthorize("@ss.hasPermi('system:user:export')")
|
|
@PreAuthorize("@ss.hasPermi('system:user:export')")
|