From 590a0eefb3d2c79a664d5db40138a3b45e4918e1 Mon Sep 17 00:00:00 2001 From: Helius <wangdoubleone@gmail.com> Date: Mon, 25 Apr 2022 16:39:55 +0800 Subject: [PATCH] fix --- src/main/resources/templates/febs/views/modules/mallMember/mallMemberList.html | 53 ++++++++++++++++++++++++++++++++++++++++++++++++----- 1 files changed, 48 insertions(+), 5 deletions(-) diff --git a/src/main/resources/templates/febs/views/modules/mallMember/mallMemberList.html b/src/main/resources/templates/febs/views/modules/mallMember/mallMemberList.html index dcff9c6..edf7f78 100644 --- a/src/main/resources/templates/febs/views/modules/mallMember/mallMemberList.html +++ b/src/main/resources/templates/febs/views/modules/mallMember/mallMemberList.html @@ -53,6 +53,11 @@ <a lay-event="edit" shiro:hasPermission="user:update"><i class="layui-icon febs-edit-area febs-blue"></i></a> </script> +<style> + .layui-form-onswitch { + background-color: #5FB878 !important; + } +</style> <!-- 表格操作栏 end --> <script data-th-inline="none" type="text/javascript"> // 引入组件并初始化 @@ -87,9 +92,32 @@ openAccount(data.id); }); } + + if (layEvent === 'reset') { + febs.modal.confirm('重置密码', '是否重置该账号密码?', function () { + resetPwd(data.id); + }); + } + if (layEvent === 'see') { febs.modal.open( '个人信息', 'modules/mallMember/detail/' + data.id, { maxmin: true, + }); + } + if (layEvent === 'moneyFlow') { + febs.modal.open( '用户资金流水', 'modules/mallMember/moneyFlow/' + data.id, { + maxmin: true, + }); + } + if (layEvent === 'systemPay') { + febs.modal.open('系统拨付', 'modules/mallMember/mallSystemPay/' + data.id, { + btn: ['提交', '取消'], + yes: function (index, layero) { + $('#systemPay-update').find('#submit').trigger('click'); + }, + btn2: function () { + layer.closeAll(); + } }); } }); @@ -102,6 +130,13 @@ function openAccount(id) { febs.get(ctx + 'admin/mallMember/openAccount/' + id, null, function () { febs.alert.success('开启成功'); + $query.click(); + }); + } + + function resetPwd(id) { + febs.post(ctx + 'admin/mallMember/resetPwd/' + id, null, function () { + febs.alert.success('重置成功'); $query.click(); }); } @@ -126,11 +161,14 @@ id: 'userTable', url: ctx + 'admin/mallMember/getMallMemberList', cols: [[ - {field: 'phone', title: '手机号', minWidth: 150,align:'left'}, - {field: 'email', title: '邮箱', minWidth: 150,align:'left'}, + {field: 'phone', title: '账号', minWidth: 150,align:'left'}, + {field: 'bindPhone', title: '手机号', minWidth: 150,align:'left'}, + // {field: 'email', title: '邮箱', minWidth: 150,align:'left'}, {field: 'name', title: '名称', minWidth: 100,align:'left'}, + {field: 'balance', title: '积分余额', minWidth: 100,align:'left'}, {field: 'inviteId', title: '邀请码', minWidth: 100,align:'left'}, - {field: 'referrerId', title: '推荐人邀请码', minWidth: 100,align:'left'}, + // {field: 'referrerId', title: '推荐人邀请码', minWidth: 100,align:'left'}, + {field: 'referrerName', title: '推荐人', minWidth: 100,align:'left'}, {field: 'accountType', title: '账号类型', templet: function (d) { if (d.accountType === 2) { @@ -144,9 +182,9 @@ {field: 'accountStatus', title: '账号状态', templet: function (d) { if (d.accountStatus === 1) { - return '<span style="color:green;">正常</span>' + return '<input type="checkbox" name="switch" lay-text="正常|禁用" checked lay-skin="switch" lay-event="accountSwitch">' } else if (d.accountStatus === 2) { - return '<span style="color:red;">禁用</span>' + return '<input type="checkbox" name="switch" lay-text="正常|禁用" lay-skin="switch" lay-event="accountSwitch">' }else{ return '' } @@ -157,10 +195,15 @@ if (d.accountStatus === 1) { return '<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="see" shiro:hasPermission="user:update">详情</button>' +'<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="close" shiro:hasPermission="user:update">禁用</button>' + +'<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="reset" shiro:hasPermission="user:update">重置密码</button>' + +'<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="systemPay" shiro:hasPermission="user:update">积分拨付</button>' + +'<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="moneyFlow" shiro:hasPermission="user:update">资金流水</button>' }else{ return '<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="see" shiro:hasPermission="user:update">详情</button>' +'<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="open" shiro:hasPermission="user:update">启用</button>' + +'<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="reset" shiro:hasPermission="user:update">重置密码</button>' + +'<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="moneyFlow" shiro:hasPermission="user:update">资金流水</button>' } },minWidth: 300,align:'center'} -- Gitblit v1.9.1