添加权限
This commit is contained in:
parent
a73cd622d1
commit
2b371d3113
|
|
@ -15,5 +15,6 @@ public class GsSubEvaluateApplication {
|
||||||
|
|
||||||
public static void main(String[] args) {
|
public static void main(String[] args) {
|
||||||
SpringApplication.run(GsSubEvaluateApplication.class, args);
|
SpringApplication.run(GsSubEvaluateApplication.class, args);
|
||||||
|
System.err.println("甘肃考试分包商评价系统启动成功");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -39,6 +39,8 @@ public class OrganizationalBean {
|
||||||
|
|
||||||
private String keyWorld;
|
private String keyWorld;
|
||||||
|
|
||||||
|
private String parentUserName;
|
||||||
|
|
||||||
private List<OrganizationalBean> children;
|
private List<OrganizationalBean> children;
|
||||||
/**
|
/**
|
||||||
* 是否是新增
|
* 是否是新增
|
||||||
|
|
|
||||||
|
|
@ -330,6 +330,9 @@ public class OrganizationalServiceImpl implements OrganizationalService {
|
||||||
.collect(Collectors.toList());
|
.collect(Collectors.toList());
|
||||||
|
|
||||||
if (!children.isEmpty()) {
|
if (!children.isEmpty()) {
|
||||||
|
for (OrganizationalBean vo:children){
|
||||||
|
vo.setParentUserName(parent.getUserName());
|
||||||
|
}
|
||||||
parent.setChildren(children);
|
parent.setChildren(children);
|
||||||
for (OrganizationalBean child : children) {
|
for (OrganizationalBean child : children) {
|
||||||
buildChildren(child, nodes);
|
buildChildren(child, nodes);
|
||||||
|
|
|
||||||
|
|
@ -116,16 +116,21 @@ function initTreeTable() {
|
||||||
{
|
{
|
||||||
fixed: 'right', width: '20%', title: '操作', align: 'center', templet: d => {
|
fixed: 'right', width: '20%', title: '操作', align: 'center', templet: d => {
|
||||||
let html = "";
|
let html = "";
|
||||||
|
|
||||||
if ([1, 2, 3, 4].includes(d.level)) {
|
if ([1, 2, 3, 4].includes(d.level)) {
|
||||||
if(user.roleId == 6 || user.roleId == 5){
|
if(user.roleId == 6 || user.roleId == 5){
|
||||||
html += '<a lay-event="add" style="color: #009688;cursor: pointer;font-size: 15px" id="add">新增</a>';
|
html += '<a lay-event="add" style="color: #009688;cursor: pointer;font-size: 15px" id="add">新增</a>';
|
||||||
}
|
}
|
||||||
if(user.roleId == 7 && d.level == 4 && d.userName == user.nickname){
|
if(user.roleId == 7 && d.level == 4 &&(d.userName == user.nickname || d.parentUserName==user.nickname) ){
|
||||||
html += '<a lay-event="add" style="color: #009688;cursor: pointer;font-size: 15px" id="add">新增</a>';
|
html += '<a lay-event="add" style="color: #009688;cursor: pointer;font-size: 15px" id="add">新增</a>';
|
||||||
}
|
}
|
||||||
if(user.roleId == 7 && d.level == 3 && d.userName == user.nickname){
|
if(user.roleId == 7 && d.level == 3 && d.userName == user.nickname){
|
||||||
html += '<a lay-event="add" style="color: #009688;cursor: pointer;font-size: 15px" id="add">新增</a>';
|
html += '<a lay-event="add" style="color: #009688;cursor: pointer;font-size: 15px" id="add">新增</a>';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
if (d.level === 5) {
|
if (d.level === 5) {
|
||||||
if(user.roleId == 6 || user.roleId == 5){
|
if(user.roleId == 6 || user.roleId == 5){
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue