|
|
@ -4,9 +4,14 @@ layui.use(['form', 'admin', 'HttpRequest'], function () {
|
|
|
|
var admin = layui.admin;
|
|
|
|
var admin = layui.admin;
|
|
|
|
var HttpRequest = layui.HttpRequest;
|
|
|
|
var HttpRequest = layui.HttpRequest;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$("#groupCode").val(Feng.getUrlParam("groupCode"));
|
|
|
|
$("#groupCode").val(Feng.getUrlParam("groupCode"));
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 修改系统配置状态
|
|
|
|
|
|
|
|
var checked = 'Y';
|
|
|
|
|
|
|
|
form.on('switch(sysFlag)', function (obj) {
|
|
|
|
|
|
|
|
checked = obj.elem.checked ? 'Y' : 'N';
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
//表单提交事件
|
|
|
|
//表单提交事件
|
|
|
|
form.on('submit(btnSubmit)', function (data) {
|
|
|
|
form.on('submit(btnSubmit)', function (data) {
|
|
|
|
var httpRequest = new HttpRequest(Feng.ctxPath + "/sysConfig/add", 'post', function (data) {
|
|
|
|
var httpRequest = new HttpRequest(Feng.ctxPath + "/sysConfig/add", 'post', function (data) {
|
|
|
@ -17,6 +22,7 @@ layui.use(['form', 'admin', 'HttpRequest'], function () {
|
|
|
|
admin.closeThisDialog();
|
|
|
|
admin.closeThisDialog();
|
|
|
|
Feng.error("添加失败!" + data.message)
|
|
|
|
Feng.error("添加失败!" + data.message)
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
data.field.sysFlag = checked;
|
|
|
|
httpRequest.set(data.field);
|
|
|
|
httpRequest.set(data.field);
|
|
|
|
httpRequest.start(true);
|
|
|
|
httpRequest.start(true);
|
|
|
|
});
|
|
|
|
});
|
|
|
|