From 4d366b62e09fd9269222cd7b3dc37f5cbcef8c75 Mon Sep 17 00:00:00 2001 From: wzy <wzy19931122ai@163.com> Date: Mon, 04 Apr 2022 12:46:30 +0800 Subject: [PATCH] fix --- src/main/resources/templates/febs/views/dapp/user.html | 25 ++++++++++++++++++++++--- 1 files changed, 22 insertions(+), 3 deletions(-) diff --git a/src/main/resources/templates/febs/views/dapp/user.html b/src/main/resources/templates/febs/views/dapp/user.html index 5866287..30c675c 100644 --- a/src/main/resources/templates/febs/views/dapp/user.html +++ b/src/main/resources/templates/febs/views/dapp/user.html @@ -39,7 +39,7 @@ <i class="layui-icon"></i> </div> <div class="layui-btn layui-btn-sm layui-btn-primary table-action action-more" - shiro:hasAnyPermissions="admin:add,admin:update,admin:reset"> + shiro:hasAnyPermissions="admin:add,admin:update,admin:reset,admin:simulate"> <i class="layui-icon"></i> </div> </div> @@ -51,7 +51,7 @@ </div> </div> </div> -<script type="text/html" id="user-status"> +<script type="text/html" id="admin-status"> {{# var status = { 1: {title: '有效', color: 'green'}, @@ -77,6 +77,7 @@ dropdown = layui.dropdown, $view = $('#febs-admin'), $query = $view.find('#query'), + $simulate = $view.find('#simulate'), $reset = $view.find('#reset'), $searchForm = $view.find('form'), sortObject = {field: 'createTime', type: null}, @@ -138,6 +139,20 @@ }); } } + if (name === 'simulate') { + febs.modal.open('生成虚拟收益', 'dappView/admin/simulate', { + btn: ['提交', '重置'], + area: $(window).width() <= 750 ? '95%' : '50%', + offset: '30px', + yes: function (index, layero) { + $('#dapp-simulate-data').find('#submit').trigger('click'); + }, + btn2: function () { + $('#dapp-simulate-data').find('#reset').trigger('click'); + return false; + } + }); + } }, options: [{ name: 'add', @@ -151,6 +166,10 @@ name: 'reset', title: '密码重置', perms: 'admin:reset' + }, { + name: 'simulate', + title: '生成虚拟收益', + perms: 'admin:simulate' }] }); @@ -207,7 +226,7 @@ {type: 'checkbox'}, {field: 'username', title: '用户名', minWidth: 100}, {field: 'inviteId', title: '邀请码', minWidth: 100}, - {title: '状态', templet: '#user-status'}, + {title: '状态', templet: '#admin-status'}, {field: 'lastLoginTime', title: '上次登录时间', minWidth: 100}, {field: 'createTime', title: '创建时间', minWidth: 180, sort: true}, {title: '操作', toolbar: '#user-option', minWidth: 140} -- Gitblit v1.9.1