父部门不能选择&选择树自适应

This commit is contained in:
RuoYi
2018-10-08 13:41:45 +08:00
parent 5b2664a87a
commit 16dc6ab57e
11 changed files with 39 additions and 24 deletions

View File

@@ -107,7 +107,6 @@
var options = {
title: '部门选择',
width: "380",
height: "380",
url: prefix + "/selectDeptTree/" + $("#treeId").val(),
callBack: doSubmit
};

View File

@@ -108,14 +108,18 @@
/*部门管理-修改-选择部门树*/
function selectDeptTree() {
var options = {
title: '部门选择',
width: "380",
height: "380",
url: prefix + "/selectDeptTree/" + $("#treeId").val(),
callBack: doSubmit
};
$.modal.openOptions(options);
var deptId = $("#treeId").val();
if(deptId > 0) {
var options = {
title: '部门选择',
width: "380",
url: prefix + "/selectDeptTree/" + $("#treeId").val(),
callBack: doSubmit
};
$.modal.openOptions(options);
} else {
$.modal.alertError("父部门不能选择");
}
}
function doSubmit(index, layero){