Merge branch 'master' of https://gitee.com/anthonywj/udims-java
commit
ad670388e2
@ -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,51 @@
|
||||
package com.glxp.udi.admin.controller.udidl;
|
||||
|
||||
import com.glxp.udi.admin.annotation.AuthRuleAnnotation;
|
||||
import com.glxp.udi.admin.req.feign.SysRoleMenuModel;
|
||||
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);
|
||||
}
|
||||
@AuthRuleAnnotation("")
|
||||
@PostMapping("/sys/role/getRoleMenu")
|
||||
public BaseResponse getRoleMenu(Integer roleId){ return udidlService.sysRole_getRoleMenu(roleId); }
|
||||
@AuthRuleAnnotation("")
|
||||
@PostMapping("/sys/role/saveRoleMenu")
|
||||
public BaseResponse saveRoleMenu(@RequestBody SysRoleMenuModel model){ return udidlService.sysRole_saveRoleMenu(model);}
|
||||
}
|
@ -0,0 +1,46 @@
|
||||
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.req.feign.SysUserModel;
|
||||
import com.glxp.udi.admin.req.feign.SysUserParam;
|
||||
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 SysUserController {
|
||||
@Resource
|
||||
UdidlService udidlService;
|
||||
|
||||
@AuthRuleAnnotation("")
|
||||
@PostMapping("/sys/user/list")
|
||||
public BaseResponse list(@RequestBody SysUserParam param) {
|
||||
return udidlService.sysUser_list(param);
|
||||
}
|
||||
@AuthRuleAnnotation("")
|
||||
@PostMapping("/sys/user/insert")
|
||||
public BaseResponse insert(@RequestBody SysUserModel model){
|
||||
return udidlService.sysUser_insert(model);
|
||||
}
|
||||
@AuthRuleAnnotation("")
|
||||
@PostMapping("/sys/user/update")
|
||||
public BaseResponse update(@RequestBody SysUserModel model) {
|
||||
return udidlService.sysUser_update(model);
|
||||
}
|
||||
@AuthRuleAnnotation("")
|
||||
@PostMapping("/sys/user/detail")
|
||||
public BaseResponse detail(Integer id) {
|
||||
return udidlService.sysUser_detail(id);
|
||||
}
|
||||
@AuthRuleAnnotation("")
|
||||
@PostMapping("/sys/user/delete")
|
||||
public BaseResponse delete(Integer id){
|
||||
return udidlService.sysUser_delete(id);
|
||||
}
|
||||
}
|
@ -0,0 +1,11 @@
|
||||
package com.glxp.udi.admin.req.feign;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
public class SysRoleMenuModel {
|
||||
private Integer roleId;
|
||||
private List<Integer> menuIds;
|
||||
}
|
@ -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;
|
||||
}
|
@ -0,0 +1,11 @@
|
||||
package com.glxp.udi.admin.req.feign;
|
||||
|
||||
import com.glxp.udi.admin.req.ListPageRequest;
|
||||
import lombok.Data;
|
||||
|
||||
|
||||
@Data
|
||||
public class SysUserParam extends ListPageRequest {
|
||||
private String status;
|
||||
private String name;
|
||||
}
|
Loading…
Reference in New Issue