KKSU
2024-12-30 6169d137461b01b47def5e3ab6353bbdcddbcc97
feat(mall): 添加节点身份管理和显示功能

- 在 AdminMallMemberServiceImpl 中添加节点时间设置逻辑
- 在 mallMemberList.html 中增加节点身份切换和时间显示功能
- 统一操作成功提示信息
2 files modified
21 ■■■■ changed files
src/main/java/cc/mrbird/febs/mall/service/impl/AdminMallMemberServiceImpl.java 1 ●●●● patch | view | raw | blame | history
src/main/resources/templates/febs/views/modules/mallMember/mallMemberList.html 20 ●●●● patch | view | raw | blame | history
src/main/java/cc/mrbird/febs/mall/service/impl/AdminMallMemberServiceImpl.java
@@ -127,6 +127,7 @@
        if (type == 1) {
            mallMember.setDirector(value);
            mallMember.setDirectorTime(DateUtil.date());
        } else if (type == 2){
            mallMember.setStoreMaster(value);
        } else {
src/main/resources/templates/febs/views/modules/mallMember/mallMemberList.html
@@ -166,33 +166,33 @@
        }
        function closeAccount(id) {
            febs.get(ctx + 'admin/mallMember/closeAccount/' + id, null, function () {
                febs.alert.success('禁用成功');
                febs.alert.success('操作成功');
                $query.click();
            });
        }
        function openAccount(id) {
            febs.get(ctx + 'admin/mallMember/openAccount/' + id, null, function () {
                febs.alert.success('开启成功');
                febs.alert.success('操作成功');
                $query.click();
            });
        }
        function changeIdentityYes(type, id) {
            febs.get(ctx + 'admin/mallMember/changeIdentityYes/' + type + "/" + id, null, function () {
                febs.alert.success('设置成功');
                febs.alert.success('操作成功');
                $query.click();
            });
        }
        function changeIdentityNo(type, id) {
            febs.get(ctx + 'admin/mallMember/changeIdentityNo/' + type + "/" + id, null, function () {
                febs.alert.success('设置成功');
                febs.alert.success('操作成功');
                $query.click();
            });
        }
        function resetPwd(id, type) {
            febs.post(ctx + 'admin/mallMember/resetPwdNew/' + type + "/"+ id, null, function () {
                febs.alert.success('重置成功');
                febs.alert.success('操作成功');
                $query.click();
            });
        }
@@ -248,6 +248,8 @@
                    {field: 'score', title: '碳积分', minWidth: 100,align:'left', totalRow:true},
                    {field: 'referrerName', title: '推荐人', minWidth: 100,align:'left'},
                    {field: 'levelName', title: '会员等级', minWidth: 100,align:'left'},
                    {field: 'director', title: '节点', templet: '#switchDirector', minWidth: 100,align:'center'},
                    {field: 'directorTime', title: '节点时间', minWidth: 180,align:'center'},
                    {field: 'vipLevelTime', title: '到期时间', minWidth: 180,align:'center'},
                    {field: 'createdTime', title: '注册时间', minWidth: 180,align:'center'},
                    {field: 'accountStatus', title: '账号状态', templet: '#switchStatus', minWidth: 100,align:'center'},
@@ -368,5 +370,13 @@
                closeAccount(data.value);
            }
        })
        form.on('switch(switchDirector)', function (data) {
            if (data.elem.checked) {
                changeIdentityYes(1,data.value);
            } else {
                changeIdentityNo(1,data.value);
            }
        })
    })
</script>