浏览代码

Merge remote-tracking branch 'origin/master'

wushaodong 4 年之前
父节点
当前提交
3368719800

+ 2 - 0
uis/views/customer/check_index.html

@@ -148,6 +148,8 @@
                 yes: function (index, dom) {
                     layui.onSubmitChild = function (res) {
                         if(res.code === 0){
+                            // 刷新父级页面的菜单数量
+                            parent.layui.getData();
                             layer.msg("审核成功!", {icon: 1})
                         }
                         layer.close(index);

+ 18 - 13
uis/views/index.html

@@ -177,21 +177,26 @@
         if (!name) {
             location.href = '/views/account/login.html'; //没有用户,跳转到登录
         }
-
-        admin.req({
-            url: '/customer/list_count/',
-            type: 'get',
-            done: function (res) {
-                let tempObj = res.data;
-                for(let key in tempObj){
-                    if(tempObj[key] === 0){
-                        $('#' + key).hide()
-                    }else{
-                        $('#' + key).append(tempObj[key]);
+        //获取菜单的数量
+        layui.getData = function getData() {
+             admin.req({
+                url: '/customer/list_count/',
+                type: 'get',
+                done: function (res) {
+                    let tempObj = res.data;
+                    for(let key in tempObj){
+                        if(tempObj[key] === 0){
+                            $('#' + key).hide()
+                        }else{
+                            $('#' + key).append(tempObj[key]);
+                        }
                     }
                 }
-            }
-        });
+            });
+        };
+
+        //获取菜单的数量
+        layui.getData();
 
 
         var permissions = layui.data(layui.setter.tableName)['permissions'];

+ 2 - 0
uis/views/order/dispatch_process_index.html

@@ -166,6 +166,8 @@
                     btn: ['保存','取消'],
                     yes: function (index, dom) {
                         layui.onSubmitChild = function (res) {
+                            // 刷新父级页面的菜单数量
+                            parent.layui.getData();
                             layer.close(index);
                             table.reload('dispatch_process_datagrid', {});
                         };

+ 5 - 1
uis/views/report_check/index.html

@@ -138,6 +138,8 @@
                     btn: ['分配', '取消'],
                     yes: function (index, dom) {
                         layui.onSubmitChild = function (data) {
+                            // 刷新父级页面的菜单数量
+                            parent.layui.getData();
                             layer.close(index);
                             table.reload('report_check_datagrid', {});
                         };
@@ -158,7 +160,9 @@
                         , type: 'post'
                         , done: function (res) {
                             if (res.code === 0) {
-                                layer.msg("标记成功!", {icon: 1})
+                                // 刷新父级页面的菜单数量
+                                parent.layui.getData();
+                                layer.msg("标记成功!", {icon: 1});
                             }
                             table.reload('report_check_datagrid', {});
                         }