From c45ba41f54c6424a20198617ff4df7433bf9e9a9 Mon Sep 17 00:00:00 2001
From: houruijun <411269194@kidgrow.com>
Date: Fri, 07 Aug 2020 18:39:59 +0800
Subject: [PATCH] 1.走查运营后台后,修改了页面所有显著错误和问题 2.修改运营后台 医院,充值,产品,套餐部分业务错误 3.增加首页数据接口
---
kidgrow-web/kidgrow-web-manager/src/main/resources/static/pages/system/role.html | 48 +++++++++++++++++++++---------------------------
1 files changed, 21 insertions(+), 27 deletions(-)
diff --git a/kidgrow-web/kidgrow-web-manager/src/main/resources/static/pages/system/role.html b/kidgrow-web/kidgrow-web-manager/src/main/resources/static/pages/system/role.html
index d015f0d..ce7367f 100644
--- a/kidgrow-web/kidgrow-web-manager/src/main/resources/static/pages/system/role.html
+++ b/kidgrow-web/kidgrow-web-manager/src/main/resources/static/pages/system/role.html
@@ -16,7 +16,7 @@
<option value="">-请选择-</option>
<option value="name">角色名称</option>
</select> 
- <input id="role-edit-value" class="layui-input search-input" type="text" placeholder="输入关键字" /> 
+ <input id="role-edit-value" class="layui-input search-input" type="text" placeholder="按关键字" /> 
<button id="role-btn-search" class="layui-btn icon-btn"><i class="layui-icon"></i>搜索</button>
<button id="role-btn-add" class="layui-btn icon-btn permissions" permissions="saveOrUpdate"><i class="layui-icon"></i>添加</button>
</div>
@@ -138,21 +138,20 @@
page: true,
cellMinWidth: 80,
cols: [[
- { type: 'numbers' },
- { field: 'id', sort: true, title: 'ID', width: 80 },
{ field: 'name', sort: true, title: '角色名' },
{ field: 'code', sort: true, title: 'Code' },
{ field: 'tenantId', sort: true, title: '应用标识' },
- {
- field: 'createTime', sort: true, templet: function (d) {
- return util.toDateString(d.createTime);
- }, title: '创建时间'
- },
+ // {
+ // field: 'createTime', sort: true, templet: function (d) {
+ // return util.toDateString(d.createTime);
+ // }, title: '创建时间'
+ // },
+ { field: 'createTime', width: 250, sort: true, title: '创建时间', templet: "<div>{{layui.util.toDateString(d.createTime, 'yyyy/MM/dd HH:mm')}}</div>" },
{ field: 'enabled', width: 100, sort: true, templet: '#role-tpl-state', title: '状态' },
{ align: 'center', toolbar: '#role-table-bar', title: '操作', width: 320 }
]],
- done:function(){
- permissionsInput();
+ done:function(res){
+ permissionsInput(res,config);
}
});
@@ -174,7 +173,7 @@
})
form.render();
} else {
- layer.msg(data.msg, { icon: 2, time: 500 });
+ layer.msg(data.msg, { icon: 2, time: 2000 });
}
}, 'GET');
@@ -190,13 +189,12 @@
layer.load(2);
admin.req('api-user/roles/saveOrUpdate?tenantId=' + tenantId, JSON.stringify(data.field), function (data) {
layer.closeAll('loading');
- // console.log(data);
if (data.code === 0) {
- layer.msg(data.msg, { icon: 1, time: 500 });
+ layer.msg(data.msg, { icon: 1, time: 2000 });
table.reload('role-table');
layer.closeAll('page');
} else {
- layer.msg(data.msg, { icon: 2, time: 500 });
+ layer.msg(data.msg, { icon: 2, time: 2000 });
}
}, $('#role-form').attr('method'));
return false;
@@ -207,7 +205,6 @@
var treeObj = $.fn.zTree.getZTreeObj('treeMenu-role');
var nodes = treeObj.getCheckedNodes(true);
$.each(nodes,function(i,item){
- // console.log(item)
if(!item.children){
array.push(item.id);
}
@@ -219,13 +216,12 @@
layer.load(2);
admin.req('api-user/sysroleorganization', JSON.stringify(data.field), function (data) {
layer.closeAll('loading');
- console.log(data);
if (data.code === 0) {
- layer.msg(data.msg, { icon: 1, time: 500 });
+ layer.msg(data.msg, { icon: 1, time: 2000 });
table.reload('role-table');
layer.closeAll('page');
} else {
- layer.msg(data.msg, { icon: 2, time: 500 });
+ layer.msg(data.msg, { icon: 2, time: 2000 });
}
}, $('#role-form').attr('method'));
layer.closeAll('page');
@@ -255,9 +251,9 @@
}, function (data) {
layer.closeAll('loading');
if (data.code == 0) {
- layer.msg(data.msg, { icon: 1, time: 500 });
+ layer.msg(data.msg, { icon: 1, time: 2000 });
} else {
- layer.msg(data.msg, { icon: 2, time: 500 });
+ layer.msg(data.msg, { icon: 2, time: 2000 });
$(obj.elem).prop('checked', !obj.elem.checked);
form.render('checkbox');
}
@@ -296,7 +292,7 @@
layer.closeAll('loading');
} else {
- layer.msg(data.msg, { icon: 2, time: 500 });
+ layer.msg(data.msg, { icon: 2, time: 2000 });
}
}, 'get');
}
@@ -343,7 +339,6 @@
};
//数据权限的点击事件
form.on('select(role_organization)', function (data) {
- console.log(data.value)
if (data.value == 2) {
$("#tree").show();
}else{
@@ -363,7 +358,6 @@
$('#role-form').attr('method', 'POST');
if (data) {
getData();
- console.log(data.type)
if(data.type!=2){
$("#tree").hide();
}
@@ -383,10 +377,10 @@
admin.req('api-user/roles/' + obj.data.id + '?tenantId=' + tenantId, {}, function (data) {
layer.closeAll('loading');
if (data.code === 0) {
- layer.msg(data.msg, { icon: 1, time: 500 });
+ layer.msg(data.msg, { icon: 1, time: 2000 });
obj.del();
} else {
- layer.msg(data.msg, { icon: 2, time: 500 });
+ layer.msg(data.msg, { icon: 2, time: 2000 });
}
}, 'DELETE');
});
@@ -438,10 +432,10 @@
admin.req('api-user/menus/granted?tenantId=' + tenantId, JSON.stringify(data), function (data) {
layer.closeAll('loading');
if (0 == data.code) {
- layer.msg(data.msg, { icon: 1, time: 500 });
+ layer.msg(data.msg, { icon: 1, time: 2000 });
layer.close(index);
} else {
- layer.msg(data.msg, { icon: 2, time: 500 });
+ layer.msg(data.msg, { icon: 2, time: 2000 });
}
}, 'POST');
}
--
Gitblit v1.8.0