权限相关
parent
00160d2a5d
commit
3ce8fc526d
@ -0,0 +1,45 @@
|
||||
package com.glxp.udi.admin.controller.udidl;
|
||||
|
||||
import com.glxp.udi.admin.annotation.AuthRuleAnnotation;
|
||||
import com.glxp.udi.admin.req.feign.SysMenuModel;
|
||||
import com.glxp.udi.admin.service.udidl.UdidlService;
|
||||
import com.glxp.udi.common.res.BaseResponse;
|
||||
import feign.Param;
|
||||
import feign.RequestLine;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
|
||||
@RestController
|
||||
public class SysMenuController {
|
||||
@Resource
|
||||
UdidlService udidlService;
|
||||
|
||||
@AuthRuleAnnotation("")
|
||||
@PostMapping("/sys/menu/list")
|
||||
public BaseResponse list() {
|
||||
return udidlService.sysMenu_list();
|
||||
}
|
||||
@AuthRuleAnnotation("")
|
||||
@PostMapping("/sys/menu/insert")
|
||||
public BaseResponse insert(@RequestBody SysMenuModel model){
|
||||
return udidlService.sysMenu_insert(model);
|
||||
}
|
||||
@AuthRuleAnnotation("")
|
||||
@PostMapping("/sys/menu/update")
|
||||
public BaseResponse update(@RequestBody SysMenuModel model) {
|
||||
return udidlService.sysMenu_update(model);
|
||||
}
|
||||
@AuthRuleAnnotation("")
|
||||
@PostMapping("/sys/menu/detail")
|
||||
public BaseResponse detail(Integer id) {
|
||||
return udidlService.sysMenu_detail(id);
|
||||
}
|
||||
@AuthRuleAnnotation("")
|
||||
@PostMapping("/sys/menu/delete")
|
||||
public BaseResponse delete(Integer id){
|
||||
return udidlService.sysMenu_delete(id);
|
||||
}
|
||||
}
|
@ -0,0 +1,44 @@
|
||||
package com.glxp.udi.admin.controller.udidl;
|
||||
|
||||
import com.glxp.udi.admin.annotation.AuthRuleAnnotation;
|
||||
import com.glxp.udi.admin.req.feign.SysRoleModel;
|
||||
import com.glxp.udi.admin.req.feign.SysRoleParam;
|
||||
import com.glxp.udi.admin.service.udidl.UdidlService;
|
||||
import com.glxp.udi.common.res.BaseResponse;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
|
||||
@RestController
|
||||
public class SysRoleController {
|
||||
@Resource
|
||||
UdidlService udidlService;
|
||||
|
||||
@AuthRuleAnnotation("")
|
||||
@PostMapping("/sys/role/list")
|
||||
public BaseResponse list(@RequestBody SysRoleParam param) {
|
||||
return udidlService.sysRole_list(param);
|
||||
}
|
||||
@AuthRuleAnnotation("")
|
||||
@PostMapping("/sys/role/insert")
|
||||
public BaseResponse insert(@RequestBody SysRoleModel model){
|
||||
return udidlService.sysRole_insert(model);
|
||||
}
|
||||
@AuthRuleAnnotation("")
|
||||
@PostMapping("/sys/role/update")
|
||||
public BaseResponse update(@RequestBody SysRoleModel model) {
|
||||
return udidlService.sysRole_update(model);
|
||||
}
|
||||
@AuthRuleAnnotation("")
|
||||
@PostMapping("/sys/role/detail")
|
||||
public BaseResponse detail(Integer id) {
|
||||
return udidlService.sysRole_detail(id);
|
||||
}
|
||||
@AuthRuleAnnotation("")
|
||||
@PostMapping("/sys/role/delete")
|
||||
public BaseResponse delete(Integer id){
|
||||
return udidlService.sysRole_delete(id);
|
||||
}
|
||||
}
|
@ -0,0 +1,30 @@
|
||||
package com.glxp.udi.admin.req.feign;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
@Data
|
||||
public class SysRoleModel {
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private Integer id;
|
||||
|
||||
/**
|
||||
* 角色名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 角色代码
|
||||
*/
|
||||
private String code;
|
||||
|
||||
/**
|
||||
* 状态0: 启用,1: 禁用
|
||||
*/
|
||||
private String status;
|
||||
/**
|
||||
* 排序
|
||||
*/
|
||||
private Integer sort;
|
||||
}
|
@ -0,0 +1,10 @@
|
||||
package com.glxp.udi.admin.req.feign;
|
||||
|
||||
import com.glxp.udi.admin.req.ListPageRequest;
|
||||
import lombok.Data;
|
||||
|
||||
@Data
|
||||
public class SysRoleParam extends ListPageRequest {
|
||||
private String status;
|
||||
private String name;
|
||||
}
|
Loading…
Reference in New Issue