用户管理,部门管理,角色管理
This commit is contained in:
parent
b6279cbbb7
commit
ec5c419875
|
|
@ -2,6 +2,8 @@ package com.bonus.web.controller.system;
|
|||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import com.bonus.common.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
|
|
@ -24,7 +26,7 @@ import com.bonus.system.service.ISysConfigService;
|
|||
|
||||
/**
|
||||
* 参数配置 信息操作处理
|
||||
*
|
||||
*
|
||||
* @author bonus
|
||||
*/
|
||||
@RestController
|
||||
|
|
@ -37,7 +39,7 @@ public class SysConfigController extends BaseController
|
|||
/**
|
||||
* 获取参数配置列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:config:list')")
|
||||
@RequiresPermissions("system:config:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(SysConfig config)
|
||||
{
|
||||
|
|
@ -47,7 +49,7 @@ public class SysConfigController extends BaseController
|
|||
}
|
||||
|
||||
@Log(title = "参数管理", businessType = BusinessType.EXPORT)
|
||||
@PreAuthorize("@ss.hasPermi('system:config:export')")
|
||||
@RequiresPermissions("system:config:export")
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, SysConfig config)
|
||||
{
|
||||
|
|
@ -59,7 +61,7 @@ public class SysConfigController extends BaseController
|
|||
/**
|
||||
* 根据参数编号获取详细信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:config:query')")
|
||||
@RequiresPermissions("system:config:query")
|
||||
@GetMapping(value = "/{configId}")
|
||||
public AjaxResult getInfo(@PathVariable Long configId)
|
||||
{
|
||||
|
|
@ -78,7 +80,7 @@ public class SysConfigController extends BaseController
|
|||
/**
|
||||
* 新增参数配置
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:config:add')")
|
||||
@RequiresPermissions("system:config:add")
|
||||
@Log(title = "参数管理", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@Validated @RequestBody SysConfig config)
|
||||
|
|
@ -94,7 +96,7 @@ public class SysConfigController extends BaseController
|
|||
/**
|
||||
* 修改参数配置
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:config:edit')")
|
||||
@RequiresPermissions("system:config:edit")
|
||||
@Log(title = "参数管理", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@Validated @RequestBody SysConfig config)
|
||||
|
|
@ -110,7 +112,7 @@ public class SysConfigController extends BaseController
|
|||
/**
|
||||
* 删除参数配置
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:config:remove')")
|
||||
@RequiresPermissions("system:config:remove")
|
||||
@Log(title = "参数管理", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{configIds}")
|
||||
public AjaxResult remove(@PathVariable Long[] configIds)
|
||||
|
|
@ -122,7 +124,7 @@ public class SysConfigController extends BaseController
|
|||
/**
|
||||
* 刷新参数缓存
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:config:remove')")
|
||||
@RequiresPermissions("system:config:remove")
|
||||
@Log(title = "参数管理", businessType = BusinessType.CLEAN)
|
||||
@DeleteMapping("/refreshCache")
|
||||
public AjaxResult refreshCache()
|
||||
|
|
|
|||
|
|
@ -1,6 +1,8 @@
|
|||
package com.bonus.web.controller.system;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.bonus.common.annotation.RequiresPermissions;
|
||||
import org.apache.commons.lang3.ArrayUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
|
|
@ -24,7 +26,7 @@ import com.bonus.system.service.ISysDeptService;
|
|||
|
||||
/**
|
||||
* 部门信息
|
||||
*
|
||||
*
|
||||
* @author bonus
|
||||
*/
|
||||
@RestController
|
||||
|
|
@ -37,7 +39,8 @@ public class SysDeptController extends BaseController
|
|||
/**
|
||||
* 获取部门列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:dept:list')")
|
||||
// @PreAuthorize("@ss.hasPermi('system:dept:list')")
|
||||
@RequiresPermissions("system:dept:list")
|
||||
@GetMapping("/list")
|
||||
public AjaxResult list(SysDept dept)
|
||||
{
|
||||
|
|
@ -48,7 +51,7 @@ public class SysDeptController extends BaseController
|
|||
/**
|
||||
* 查询部门列表(排除节点)
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:dept:list')")
|
||||
@RequiresPermissions("system:dept:list")
|
||||
@GetMapping("/list/exclude/{deptId}")
|
||||
public AjaxResult excludeChild(@PathVariable(value = "deptId", required = false) Long deptId)
|
||||
{
|
||||
|
|
@ -60,7 +63,7 @@ public class SysDeptController extends BaseController
|
|||
/**
|
||||
* 根据部门编号获取详细信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:dept:query')")
|
||||
@RequiresPermissions("system:dept:query")
|
||||
@GetMapping(value = "/{deptId}")
|
||||
public AjaxResult getInfo(@PathVariable Long deptId)
|
||||
{
|
||||
|
|
@ -71,7 +74,7 @@ public class SysDeptController extends BaseController
|
|||
/**
|
||||
* 新增部门
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:dept:add')")
|
||||
@RequiresPermissions("system:dept:add")
|
||||
@Log(title = "部门管理", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@Validated @RequestBody SysDept dept)
|
||||
|
|
@ -87,7 +90,7 @@ public class SysDeptController extends BaseController
|
|||
/**
|
||||
* 修改部门
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:dept:edit')")
|
||||
@RequiresPermissions("system:dept:edit")
|
||||
@Log(title = "部门管理", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@Validated @RequestBody SysDept dept)
|
||||
|
|
@ -113,7 +116,7 @@ public class SysDeptController extends BaseController
|
|||
/**
|
||||
* 删除部门
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:dept:remove')")
|
||||
@RequiresPermissions("system:dept:remove")
|
||||
@Log(title = "部门管理", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{deptId}")
|
||||
public AjaxResult remove(@PathVariable Long deptId)
|
||||
|
|
|
|||
|
|
@ -2,6 +2,8 @@ package com.bonus.web.controller.system;
|
|||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import com.bonus.common.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
|
|
@ -24,7 +26,7 @@ import com.bonus.system.service.ISysPostService;
|
|||
|
||||
/**
|
||||
* 岗位信息操作处理
|
||||
*
|
||||
*
|
||||
* @author bonus
|
||||
*/
|
||||
@RestController
|
||||
|
|
@ -37,7 +39,7 @@ public class SysPostController extends BaseController
|
|||
/**
|
||||
* 获取岗位列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:post:list')")
|
||||
@RequiresPermissions("system:post:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(SysPost post)
|
||||
{
|
||||
|
|
@ -45,9 +47,9 @@ public class SysPostController extends BaseController
|
|||
List<SysPost> list = postService.selectPostList(post);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
|
||||
@Log(title = "岗位管理", businessType = BusinessType.EXPORT)
|
||||
@PreAuthorize("@ss.hasPermi('system:post:export')")
|
||||
@RequiresPermissions("system:post:export")
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, SysPost post)
|
||||
{
|
||||
|
|
@ -59,7 +61,7 @@ public class SysPostController extends BaseController
|
|||
/**
|
||||
* 根据岗位编号获取详细信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:post:query')")
|
||||
@RequiresPermissions("system:post:query")
|
||||
@GetMapping(value = "/{postId}")
|
||||
public AjaxResult getInfo(@PathVariable Long postId)
|
||||
{
|
||||
|
|
@ -69,7 +71,7 @@ public class SysPostController extends BaseController
|
|||
/**
|
||||
* 新增岗位
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:post:add')")
|
||||
@RequiresPermissions("system:post:add")
|
||||
@Log(title = "岗位管理", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@Validated @RequestBody SysPost post)
|
||||
|
|
@ -89,7 +91,7 @@ public class SysPostController extends BaseController
|
|||
/**
|
||||
* 修改岗位
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:post:edit')")
|
||||
@RequiresPermissions("system:post:edit")
|
||||
@Log(title = "岗位管理", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@Validated @RequestBody SysPost post)
|
||||
|
|
@ -109,7 +111,7 @@ public class SysPostController extends BaseController
|
|||
/**
|
||||
* 删除岗位
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:post:remove')")
|
||||
@RequiresPermissions("system:post:remove")
|
||||
@Log(title = "岗位管理", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{postIds}")
|
||||
public AjaxResult remove(@PathVariable Long[] postIds)
|
||||
|
|
|
|||
|
|
@ -2,6 +2,8 @@ package com.bonus.web.controller.system;
|
|||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import com.bonus.common.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
|
|
@ -33,7 +35,7 @@ import com.bonus.system.service.ISysUserService;
|
|||
|
||||
/**
|
||||
* 角色信息
|
||||
*
|
||||
*
|
||||
* @author bonus
|
||||
*/
|
||||
@RestController
|
||||
|
|
@ -65,7 +67,7 @@ public class SysRoleController extends BaseController
|
|||
}
|
||||
|
||||
@Log(title = "角色管理", businessType = BusinessType.EXPORT)
|
||||
@PreAuthorize("@ss.hasPermi('system:role:export')")
|
||||
@RequiresPermissions("system:role:export")
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, SysRole role)
|
||||
{
|
||||
|
|
@ -77,7 +79,7 @@ public class SysRoleController extends BaseController
|
|||
/**
|
||||
* 根据角色编号获取详细信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:role:query')")
|
||||
@RequiresPermissions("system:role:query")
|
||||
@GetMapping(value = "/{roleId}")
|
||||
public AjaxResult getInfo(@PathVariable Long roleId)
|
||||
{
|
||||
|
|
@ -88,7 +90,7 @@ public class SysRoleController extends BaseController
|
|||
/**
|
||||
* 新增角色
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:role:add')")
|
||||
@RequiresPermissions("system:role:add")
|
||||
@Log(title = "角色管理", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@Validated @RequestBody SysRole role)
|
||||
|
|
@ -109,7 +111,7 @@ public class SysRoleController extends BaseController
|
|||
/**
|
||||
* 修改保存角色
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:role:edit')")
|
||||
@RequiresPermissions("system:role:edit")
|
||||
@Log(title = "角色管理", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@Validated @RequestBody SysRole role)
|
||||
|
|
@ -125,7 +127,7 @@ public class SysRoleController extends BaseController
|
|||
return error("修改角色'" + role.getRoleName() + "'失败,角色权限已存在");
|
||||
}
|
||||
role.setUpdateBy(getUsername());
|
||||
|
||||
|
||||
if (roleService.updateRole(role) > 0)
|
||||
{
|
||||
// 更新缓存用户权限
|
||||
|
|
@ -144,7 +146,7 @@ public class SysRoleController extends BaseController
|
|||
/**
|
||||
* 修改保存数据权限
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:role:edit')")
|
||||
@RequiresPermissions("system:role:edit")
|
||||
@Log(title = "角色管理", businessType = BusinessType.UPDATE)
|
||||
@PutMapping("/dataScope")
|
||||
public AjaxResult dataScope(@RequestBody SysRole role)
|
||||
|
|
@ -157,7 +159,7 @@ public class SysRoleController extends BaseController
|
|||
/**
|
||||
* 状态修改
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:role:edit')")
|
||||
@RequiresPermissions("system:role:edit")
|
||||
@Log(title = "角色管理", businessType = BusinessType.UPDATE)
|
||||
@PutMapping("/changeStatus")
|
||||
public AjaxResult changeStatus(@RequestBody SysRole role)
|
||||
|
|
@ -171,7 +173,7 @@ public class SysRoleController extends BaseController
|
|||
/**
|
||||
* 删除角色
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:role:remove')")
|
||||
@RequiresPermissions("system:role:remove")
|
||||
@Log(title = "角色管理", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{roleIds}")
|
||||
public AjaxResult remove(@PathVariable Long[] roleIds)
|
||||
|
|
@ -182,7 +184,7 @@ public class SysRoleController extends BaseController
|
|||
/**
|
||||
* 获取角色选择框列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:role:query')")
|
||||
@RequiresPermissions("system:role:query")
|
||||
@GetMapping("/optionselect")
|
||||
public AjaxResult optionselect()
|
||||
{
|
||||
|
|
@ -192,7 +194,7 @@ public class SysRoleController extends BaseController
|
|||
/**
|
||||
* 查询已分配用户角色列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:role:list')")
|
||||
@RequiresPermissions("system:role:list")
|
||||
@GetMapping("/authUser/allocatedList")
|
||||
public TableDataInfo allocatedList(SysUser user)
|
||||
{
|
||||
|
|
@ -204,7 +206,7 @@ public class SysRoleController extends BaseController
|
|||
/**
|
||||
* 查询未分配用户角色列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:role:list')")
|
||||
@RequiresPermissions("system:role:list")
|
||||
@GetMapping("/authUser/unallocatedList")
|
||||
public TableDataInfo unallocatedList(SysUser user)
|
||||
{
|
||||
|
|
@ -216,7 +218,7 @@ public class SysRoleController extends BaseController
|
|||
/**
|
||||
* 取消授权用户
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:role:edit')")
|
||||
@RequiresPermissions("system:role:edit")
|
||||
@Log(title = "角色管理", businessType = BusinessType.GRANT)
|
||||
@PutMapping("/authUser/cancel")
|
||||
public AjaxResult cancelAuthUser(@RequestBody SysUserRole userRole)
|
||||
|
|
@ -227,7 +229,7 @@ public class SysRoleController extends BaseController
|
|||
/**
|
||||
* 批量取消授权用户
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:role:edit')")
|
||||
@RequiresPermissions("system:role:edit")
|
||||
@Log(title = "角色管理", businessType = BusinessType.GRANT)
|
||||
@PutMapping("/authUser/cancelAll")
|
||||
public AjaxResult cancelAuthUserAll(Long roleId, Long[] userIds)
|
||||
|
|
@ -238,7 +240,7 @@ public class SysRoleController extends BaseController
|
|||
/**
|
||||
* 批量选择用户授权
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:role:edit')")
|
||||
@RequiresPermissions("system:role:edit")
|
||||
@Log(title = "角色管理", businessType = BusinessType.GRANT)
|
||||
@PutMapping("/authUser/selectAll")
|
||||
public AjaxResult selectAuthUserAll(Long roleId, Long[] userIds)
|
||||
|
|
@ -250,7 +252,7 @@ public class SysRoleController extends BaseController
|
|||
/**
|
||||
* 获取对应角色部门树列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:role:query')")
|
||||
@RequiresPermissions("system:role:query")
|
||||
@GetMapping(value = "/deptTree/{roleId}")
|
||||
public AjaxResult deptTree(@PathVariable("roleId") Long roleId)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -73,7 +73,7 @@ public class SysUserController extends BaseController
|
|||
}
|
||||
|
||||
@Log(title = "用户管理", businessType = BusinessType.EXPORT)
|
||||
@PreAuthorize("@ss.hasPermi('system:user:export')")
|
||||
@RequiresPermissions("system:user:export")
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, SysUser user)
|
||||
{
|
||||
|
|
@ -83,7 +83,7 @@ public class SysUserController extends BaseController
|
|||
}
|
||||
|
||||
@Log(title = "用户管理", businessType = BusinessType.IMPORT)
|
||||
@PreAuthorize("@ss.hasPermi('system:user:import')")
|
||||
@RequiresPermissions("system:user:import")
|
||||
@PostMapping("/importData")
|
||||
public AjaxResult importData(MultipartFile file, boolean updateSupport) throws Exception
|
||||
{
|
||||
|
|
@ -104,7 +104,7 @@ public class SysUserController extends BaseController
|
|||
/**
|
||||
* 根据用户编号获取详细信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:user:query')")
|
||||
@RequiresPermissions("system:user:query")
|
||||
@GetMapping(value = { "/", "/{userId}" })
|
||||
public AjaxResult getInfo(@PathVariable(value = "userId", required = false) Long userId)
|
||||
{
|
||||
|
|
@ -126,7 +126,7 @@ public class SysUserController extends BaseController
|
|||
/**
|
||||
* 新增用户
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:user:add')")
|
||||
@RequiresPermissions("system:user:add")
|
||||
@Log(title = "用户管理", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@Validated @RequestBody SysUser user)
|
||||
|
|
@ -154,7 +154,7 @@ public class SysUserController extends BaseController
|
|||
/**
|
||||
* 修改用户
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:user:edit')")
|
||||
@RequiresPermissions("system:user:edit")
|
||||
@Log(title = "用户管理", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@Validated @RequestBody SysUser user)
|
||||
|
|
@ -182,7 +182,7 @@ public class SysUserController extends BaseController
|
|||
/**
|
||||
* 删除用户
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:user:remove')")
|
||||
@RequiresPermissions("system:user:remove")
|
||||
@Log(title = "用户管理", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{userIds}")
|
||||
public AjaxResult remove(@PathVariable Long[] userIds)
|
||||
|
|
@ -197,7 +197,7 @@ public class SysUserController extends BaseController
|
|||
/**
|
||||
* 重置密码
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:user:resetPwd')")
|
||||
@RequiresPermissions("system:user:resetPwd")
|
||||
@Log(title = "用户管理", businessType = BusinessType.UPDATE)
|
||||
@PutMapping("/resetPwd")
|
||||
public AjaxResult resetPwd(@RequestBody SysUser user)
|
||||
|
|
@ -212,7 +212,7 @@ public class SysUserController extends BaseController
|
|||
/**
|
||||
* 状态修改
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:user:edit')")
|
||||
@RequiresPermissions("system:user:edit")
|
||||
@Log(title = "用户管理", businessType = BusinessType.UPDATE)
|
||||
@PutMapping("/changeStatus")
|
||||
public AjaxResult changeStatus(@RequestBody SysUser user)
|
||||
|
|
@ -226,7 +226,7 @@ public class SysUserController extends BaseController
|
|||
/**
|
||||
* 根据用户编号获取授权角色
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:user:query')")
|
||||
@RequiresPermissions("system:user:query")
|
||||
@GetMapping("/authRole/{userId}")
|
||||
public AjaxResult authRole(@PathVariable("userId") Long userId)
|
||||
{
|
||||
|
|
@ -241,7 +241,7 @@ public class SysUserController extends BaseController
|
|||
/**
|
||||
* 用户授权角色
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:user:edit')")
|
||||
@RequiresPermissions("system:user:edit")
|
||||
@Log(title = "用户管理", businessType = BusinessType.GRANT)
|
||||
@PutMapping("/authRole")
|
||||
public AjaxResult insertAuthRole(Long userId, Long[] roleIds)
|
||||
|
|
|
|||
|
|
@ -0,0 +1,16 @@
|
|||
package com.bonus.web.controller.tool;
|
||||
|
||||
import com.bonus.common.core.controller.BaseController;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
/**
|
||||
* @author 马三炮
|
||||
* @date 2025/9/10
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/data/Collect")
|
||||
@Slf4j
|
||||
public class DataCollectDataController extends BaseController {
|
||||
}
|
||||
|
|
@ -1,6 +1,7 @@
|
|||
package com.bonus.web.controller.tool;
|
||||
|
||||
import com.bonus.common.annotation.Log;
|
||||
import com.bonus.common.annotation.RequiresPermissions;
|
||||
import com.bonus.common.annotation.SysLog;
|
||||
import com.bonus.common.core.controller.BaseController;
|
||||
import com.bonus.common.core.domain.AjaxResult;
|
||||
|
|
@ -42,7 +43,7 @@ public class KyDataClassifyController extends BaseController {
|
|||
* @return
|
||||
*/
|
||||
@SysLog(title = "数据集成", businessType = OperaType.QUERY, logType = 0, module = "数据集成->数据分类管理", details = "查询数据分类列表")
|
||||
@PreAuthorize("@ss.hasPermi('data:classify:list')")
|
||||
@RequiresPermissions("data:classify:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(KyDataClassify kyDataClassify)
|
||||
{
|
||||
|
|
@ -56,7 +57,7 @@ public class KyDataClassifyController extends BaseController {
|
|||
* @param kyDataClassify
|
||||
* @return
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('data:classify:add')")
|
||||
@RequiresPermissions("data:classify:add")
|
||||
@SysLog(title = "数据集成", businessType = OperaType.QUERY, logType = 0, module = "数据集成->数据分类管理", details = "新增数据分类")
|
||||
@PostMapping("/addKyDataClassify")
|
||||
public AjaxResult addKyDataClassify(@Validated @RequestBody KyDataClassify kyDataClassify)
|
||||
|
|
@ -76,7 +77,7 @@ public class KyDataClassifyController extends BaseController {
|
|||
* @param kyDataClassify
|
||||
* @return
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('data:classify:update')")
|
||||
@RequiresPermissions("data:classify:update")
|
||||
@SysLog(title = "数据集成", businessType = OperaType.QUERY, logType = 0, module = "数据集成->数据分类管理", details = "修改数据分类")
|
||||
@PostMapping("/updateKyDataClassify")
|
||||
public AjaxResult updateKyDataClassify(@Validated @RequestBody KyDataClassify kyDataClassify)
|
||||
|
|
@ -93,7 +94,7 @@ public class KyDataClassifyController extends BaseController {
|
|||
* @param kyDataClassify
|
||||
* @return
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('data:classify:del')")
|
||||
@RequiresPermissions("data:classify:del")
|
||||
@SysLog(title = "数据集成", businessType = OperaType.QUERY, logType = 0, module = "数据集成->数据分类管理", details = "删除数据分类")
|
||||
@PostMapping("/delKyDataClassify")
|
||||
public AjaxResult delKyDataClassify(@Validated @RequestBody KyDataClassify kyDataClassify)
|
||||
|
|
|
|||
|
|
@ -0,0 +1,44 @@
|
|||
package com.bonus.system.domain;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @author 马三炮
|
||||
* @date 2025/9/10
|
||||
*/
|
||||
@Data
|
||||
public class KyDataCollectData {
|
||||
|
||||
/**
|
||||
* id
|
||||
*/
|
||||
private Integer id;
|
||||
|
||||
/**
|
||||
* 数据分类id
|
||||
*/
|
||||
private Long dataClassifyId;
|
||||
|
||||
/**
|
||||
* 数据
|
||||
*/
|
||||
private String dataJson;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private String createTime;
|
||||
|
||||
/**
|
||||
* 修改时间
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private String updateTime;
|
||||
|
||||
/**
|
||||
*是否删除 0.删除 1.未删除
|
||||
*/
|
||||
private String delFlag;
|
||||
}
|
||||
|
|
@ -0,0 +1,173 @@
|
|||
package com.bonus.system.domain;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.Size;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* @author 马三炮
|
||||
* @date 2025/9/9
|
||||
*/
|
||||
public class KyFilesMultiClassify {
|
||||
|
||||
/**
|
||||
* id
|
||||
*/
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 分类名称
|
||||
*/
|
||||
private String classifyName;
|
||||
|
||||
/**
|
||||
* 维度(字典表配置)
|
||||
*/
|
||||
private String dimension;
|
||||
|
||||
/**
|
||||
* 分类描述
|
||||
*/
|
||||
private String classifyDesc;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
private Date createTime;
|
||||
|
||||
/**
|
||||
* 修改时间
|
||||
*/
|
||||
private Date updateTime;
|
||||
|
||||
/**
|
||||
* 创建人
|
||||
*/
|
||||
private Long createUserId;
|
||||
|
||||
/**
|
||||
* 创建人
|
||||
*/
|
||||
private String createUserName;
|
||||
|
||||
/**
|
||||
* 修改人
|
||||
*/
|
||||
private Long updateUserId;
|
||||
|
||||
/**
|
||||
* 修改人姓名
|
||||
*/
|
||||
private String updateUserName;
|
||||
|
||||
/**
|
||||
* 是否删除 0. 删除 1.未删除
|
||||
*/
|
||||
private String delFlag;
|
||||
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Long id) {
|
||||
this.id = id;
|
||||
}
|
||||
@Size(min = 0, max = 64, message = "分类名称不能超过64个字符")
|
||||
public String getClassifyName() {
|
||||
return classifyName;
|
||||
}
|
||||
|
||||
public void setClassifyName(String classifyName) {
|
||||
this.classifyName = classifyName;
|
||||
}
|
||||
|
||||
public String getDimension() {
|
||||
return dimension;
|
||||
}
|
||||
|
||||
public void setDimension(String dimension) {
|
||||
this.dimension = dimension;
|
||||
}
|
||||
@Size(min = 0, max = 255, message = "分类描述不能超过255个字符")
|
||||
public String getClassifyDesc() {
|
||||
return classifyDesc;
|
||||
}
|
||||
|
||||
public void setClassifyDesc(String classifyDesc) {
|
||||
this.classifyDesc = classifyDesc;
|
||||
}
|
||||
|
||||
public Date getCreateTime() {
|
||||
return createTime;
|
||||
}
|
||||
|
||||
public void setCreateTime(Date createTime) {
|
||||
this.createTime = createTime;
|
||||
}
|
||||
|
||||
public Date getUpdateTime() {
|
||||
return updateTime;
|
||||
}
|
||||
|
||||
public void setUpdateTime(Date updateTime) {
|
||||
this.updateTime = updateTime;
|
||||
}
|
||||
|
||||
public Long getCreateUserId() {
|
||||
return createUserId;
|
||||
}
|
||||
|
||||
public void setCreateUserId(Long createUserId) {
|
||||
this.createUserId = createUserId;
|
||||
}
|
||||
|
||||
public String getCreateUserName() {
|
||||
return createUserName;
|
||||
}
|
||||
|
||||
public void setCreateUserName(String createUserName) {
|
||||
this.createUserName = createUserName;
|
||||
}
|
||||
|
||||
public Long getUpdateUserId() {
|
||||
return updateUserId;
|
||||
}
|
||||
|
||||
public void setUpdateUserId(Long updateUserId) {
|
||||
this.updateUserId = updateUserId;
|
||||
}
|
||||
|
||||
public String getUpdateUserName() {
|
||||
return updateUserName;
|
||||
}
|
||||
|
||||
public void setUpdateUserName(String updateUserName) {
|
||||
this.updateUserName = updateUserName;
|
||||
}
|
||||
|
||||
public String getDelFlag() {
|
||||
return delFlag;
|
||||
}
|
||||
|
||||
public void setDelFlag(String delFlag) {
|
||||
this.delFlag = delFlag;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "KyFilesMultiClassify{" +
|
||||
"id=" + id +
|
||||
", classifyName='" + classifyName + '\'' +
|
||||
", dimension='" + dimension + '\'' +
|
||||
", classifyDesc='" + classifyDesc + '\'' +
|
||||
", createTime=" + createTime +
|
||||
", updateTime=" + updateTime +
|
||||
", createUserId=" + createUserId +
|
||||
", createUserName='" + createUserName + '\'' +
|
||||
", updateUserId=" + updateUserId +
|
||||
", updateUserName='" + updateUserName + '\'' +
|
||||
", delFlag='" + delFlag + '\'' +
|
||||
'}';
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,4 @@
|
|||
package com.bonus.system.mapper;
|
||||
|
||||
public interface DataCollectDataServiceMapper {
|
||||
}
|
||||
|
|
@ -0,0 +1,4 @@
|
|||
package com.bonus.system.service;
|
||||
|
||||
public interface DataCollectDataService {
|
||||
}
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
package com.bonus.system.service.impl;
|
||||
|
||||
import com.bonus.system.service.DataCollectDataService;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* @author 马三炮
|
||||
* @date 2025/9/10
|
||||
*/
|
||||
@Service
|
||||
@Slf4j
|
||||
public class DataCollectDataServiceImpl implements DataCollectDataService {
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,7 @@
|
|||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.bonus.system.mapper.DataCollectDataServiceMapper">
|
||||
|
||||
</mapper>
|
||||
Loading…
Reference in New Issue