save
This commit is contained in:
parent
ddbe85c6c0
commit
5576a94f59
@ -75,7 +75,7 @@ class RoleController extends Crud
|
||||
}
|
||||
if (isset($data['pid'])) {
|
||||
if ($data['pid'] == $id) {
|
||||
return $this->json(1, '父集不能是自己');
|
||||
return $this->json(1, '父级不能是自己');
|
||||
}
|
||||
if ($data['pid'] == 0) {
|
||||
return $this->json(1, '请选择父级权限组');
|
||||
|
@ -72,7 +72,7 @@
|
||||
el: "#rules",
|
||||
name: "rules",
|
||||
initValue: initValue,
|
||||
data: e.data,
|
||||
data: e.data,
|
||||
tree: {"show":true,expandedKeys:initValue},
|
||||
toolbar: {show:true,list:["ALL","CLEAR","REVERSE"]},
|
||||
})
|
||||
@ -80,7 +80,7 @@
|
||||
});
|
||||
});
|
||||
|
||||
// 字段 上级id pid
|
||||
// 字段 父级 pid
|
||||
layui.use(["jquery", "xmSelect"], function() {
|
||||
layui.$.ajax({
|
||||
url: "/app/admin/role/select?format=tree",
|
||||
@ -92,10 +92,14 @@
|
||||
el: "#pid",
|
||||
name: "pid",
|
||||
initValue: initValue,
|
||||
data: e.data,
|
||||
tips: "请选择",
|
||||
toolbar: {show: true, list: ["CLEAR"]},
|
||||
data: e.data,
|
||||
value: "0",
|
||||
model: {"icon":"hidden","label":{"type":"text"}},
|
||||
clickClose: true,
|
||||
radio: true,
|
||||
tree: {show: true,"strict":false,"clickCheck":true,"clickExpand":false,expandedKeys:true},
|
||||
})
|
||||
}
|
||||
});
|
||||
|
@ -96,7 +96,7 @@
|
||||
el: "#rules",
|
||||
name: "rules",
|
||||
initValue: initValue,
|
||||
data: e.data,
|
||||
data: e.data,
|
||||
tree: {"show":true,expandedKeys:initValue},
|
||||
toolbar: {show:true,list:["ALL","CLEAR","REVERSE"]},
|
||||
})
|
||||
@ -104,7 +104,7 @@
|
||||
});
|
||||
});
|
||||
|
||||
// 字段 上级id pid
|
||||
// 字段 父级角色组 pid
|
||||
layui.use(["jquery", "xmSelect"], function() {
|
||||
layui.$.ajax({
|
||||
url: "/app/admin/role/select?format=tree",
|
||||
@ -116,10 +116,14 @@
|
||||
el: "#pid",
|
||||
name: "pid",
|
||||
initValue: initValue,
|
||||
data: e.data,
|
||||
tips: "请选择",
|
||||
toolbar: {show: true, list: ["CLEAR"]},
|
||||
data: e.data,
|
||||
value: "0",
|
||||
model: {"icon":"hidden","label":{"type":"text"}},
|
||||
clickClose: true,
|
||||
radio: true,
|
||||
tree: {show: true,"strict":false,"clickCheck":true,"clickExpand":false,expandedKeys:true},
|
||||
})
|
||||
}
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user