| | |
| | | /** |
| | | * 查询用户和角色关联列表 |
| | | */ |
| | | @RequiresPermissions("car:role:list") |
| | | @GetMapping("/list") |
| | | public TableDataInfo list(SysUserRole sysUserRole) { |
| | | startPage(); |
| | |
| | | /** |
| | | * 导出用户和角色关联列表 |
| | | */ |
| | | @RequiresPermissions("car:role:export") |
| | | @Log(title = "用户和角色关联", businessType = BusinessType.EXPORT) |
| | | @PostMapping("/export") |
| | | public void export(HttpServletResponse response, SysUserRole sysUserRole) { |
| | |
| | | /** |
| | | * 获取用户和角色关联详细信息 |
| | | */ |
| | | @RequiresPermissions("car:role:query") |
| | | @GetMapping(value = "/{userId}") |
| | | public AjaxResult getInfo(@PathVariable("userId") Long userId) { |
| | | return success(sysUserRoleService.selectSysUserRoleByUserId(userId)); |
| | |
| | | /** |
| | | * 新增用户和角色关联 |
| | | */ |
| | | @RequiresPermissions("car:role:add") |
| | | @Log(title = "用户和角色关联", businessType = BusinessType.INSERT) |
| | | @PostMapping |
| | | public AjaxResult add(@RequestBody SysUserRole sysUserRole) { |
| | |
| | | /** |
| | | * 修改用户和角色关联 |
| | | */ |
| | | @RequiresPermissions("car:role:edit") |
| | | @Log(title = "用户和角色关联", businessType = BusinessType.UPDATE) |
| | | @PutMapping |
| | | public AjaxResult edit(@RequestBody SysUserRole sysUserRole) { |
| | |
| | | /** |
| | | * 删除用户和角色关联 |
| | | */ |
| | | @RequiresPermissions("car:role:remove") |
| | | @Log(title = "用户和角色关联", businessType = BusinessType.DELETE) |
| | | @DeleteMapping("/{userIds}") |
| | | public AjaxResult remove(@PathVariable Long[] userIds) { |