bug修复
This commit is contained in:
parent
daa39f2b6c
commit
386973a62d
|
|
@ -48,7 +48,8 @@
|
||||||
</div>
|
</div>
|
||||||
</div>-->
|
</div>-->
|
||||||
<div class="layui-form-item" style="width: 90%">
|
<div class="layui-form-item" style="width: 90%">
|
||||||
<label class="layui-form-label" style="width: 150px"><span style="color: red">*</span>身份证号码:</label>
|
<label class="layui-form-label" style="width: 150px"><span
|
||||||
|
style="color: red">*</span>身份证号码:</label>
|
||||||
<div class="layui-input-inline" style="width: 60%">
|
<div class="layui-input-inline" style="width: 60%">
|
||||||
<input class="layui-input" id="idCard" name="idCard" lay-verify="required\|idCard"
|
<input class="layui-input" id="idCard" name="idCard" lay-verify="required\|idCard"
|
||||||
lay-affix="clear" autocomplete="off" maxlength="18">
|
lay-affix="clear" autocomplete="off" maxlength="18">
|
||||||
|
|
@ -82,7 +83,7 @@
|
||||||
<div class="layui-form-item" style="width: 90%">
|
<div class="layui-form-item" style="width: 90%">
|
||||||
<label class="layui-form-label" style="width: 150px"><span style="color: red">*</span>系统角色:</label>
|
<label class="layui-form-label" style="width: 150px"><span style="color: red">*</span>系统角色:</label>
|
||||||
<div class="layui-input-inline" style="width: 60%">
|
<div class="layui-input-inline" style="width: 60%">
|
||||||
<select id="roleId" name="roleId" class="layui-select" lay-filter="changeOrg" lay-search
|
<select id="roleId" name="roleId" class="layui-select" lay-filter="changeRole" lay-search
|
||||||
lay-verify="required" style="height: 360px;"></select>
|
lay-verify="required" style="height: 360px;"></select>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -93,7 +94,7 @@
|
||||||
style="color: red">*</span>所属项目/部门:</label>
|
style="color: red">*</span>所属项目/部门:</label>
|
||||||
<div class="layui-input-inline" style="width: 60%">
|
<div class="layui-input-inline" style="width: 60%">
|
||||||
<select id="deptId" name="deptId" class="layui-select" lay-filter="changeOrg" lay-search
|
<select id="deptId" name="deptId" class="layui-select" lay-filter="changeOrg" lay-search
|
||||||
lay-verify="required" style="height: 360px;" disabled></select>
|
lay-verify="required" style="height: 360px;"></select>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -128,11 +129,7 @@
|
||||||
if (list && list.length > 0) {
|
if (list && list.length > 0) {
|
||||||
$.each(list, function (index, item) {
|
$.each(list, function (index, item) {
|
||||||
//html += "<option value='" + item[code] + "' item='" + JSON.stringify(item) + "'>" + item[nameCode] + "</option>";
|
//html += "<option value='" + item[code] + "' item='" + JSON.stringify(item) + "'>" + item[nameCode] + "</option>";
|
||||||
if (item.name === '发展运营中心'){
|
|
||||||
html += "<option value='" + item.id + "' selected>" + item.name + "</option>";
|
|
||||||
}else {
|
|
||||||
html += "<option value='" + item.id + "'>" + item.name + "</option>";
|
html += "<option value='" + item.id + "'>" + item.name + "</option>";
|
||||||
}
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -177,6 +174,15 @@
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
form.render();
|
form.render();
|
||||||
|
form.on('select(changeRole)', function (obj) {
|
||||||
|
if (obj.value == 5) {
|
||||||
|
$('#deptId').val(7); // 设置为发展运营中心
|
||||||
|
$('#deptId').attr('disabled', 'disabled');
|
||||||
|
} else {
|
||||||
|
$('#deptId').val("");
|
||||||
|
}
|
||||||
|
layui.form.render('select'); // 刷新下拉框
|
||||||
|
});
|
||||||
// 提交事件
|
// 提交事件
|
||||||
form.on('submit(formSubmit)', function (data) {
|
form.on('submit(formSubmit)', function (data) {
|
||||||
//对身份证和手机号验证
|
//对身份证和手机号验证
|
||||||
|
|
|
||||||
|
|
@ -135,6 +135,9 @@
|
||||||
elem.removeAttr("lay-verify");
|
elem.removeAttr("lay-verify");
|
||||||
//删除所属部门/项目前面的*
|
//删除所属部门/项目前面的*
|
||||||
$(".layui-form-label:eq(5)").html("所属部门/项目");
|
$(".layui-form-label:eq(5)").html("所属部门/项目");
|
||||||
|
} else if (value == 5) {
|
||||||
|
$('#deptId').val(7); // 设置为发展运营中心
|
||||||
|
$('#deptId').attr('disabled', 'disabled');
|
||||||
} else {
|
} else {
|
||||||
elem.removeAttr("disabled");
|
elem.removeAttr("disabled");
|
||||||
elem.attr("lay-verify", "required");
|
elem.attr("lay-verify", "required");
|
||||||
|
|
@ -154,6 +157,7 @@
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
function getDeptSelect() {
|
function getDeptSelect() {
|
||||||
$.ajax({
|
$.ajax({
|
||||||
type: 'post',
|
type: 'post',
|
||||||
|
|
@ -197,6 +201,7 @@
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
function closePage() {
|
function closePage() {
|
||||||
let index = parent.layer.getFrameIndex(window.name); // 先得到当前 iframe层的索引
|
let index = parent.layer.getFrameIndex(window.name); // 先得到当前 iframe层的索引
|
||||||
parent.searchTable(1)
|
parent.searchTable(1)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue