| | |
| | | table.on('tool(userTable)', function (obj) {
|
| | | var data = obj.data,
|
| | | layEvent = obj.event;
|
| | | if (layEvent === 'disagree') {
|
| | | febs.modal.confirm('禁止', '确认禁止平仓功能?', function () {
|
| | | disagree(data.id);
|
| | | });
|
| | | }
|
| | | if (layEvent === 'agree') {
|
| | | febs.modal.confirm('开启', '确认开启平仓功能?', function () {
|
| | | agree(data.id);
|
| | | });
|
| | | }
|
| | |
|
| | | if (layEvent === 'edit') {
|
| | | febs.modal.open('身份认证', 'modules/member/memberDetail/' + data.id, {
|
| | |
| | | });
|
| | | }
|
| | | });
|
| | | function disagree(id) {
|
| | | febs.get(ctx + 'tradeManage/disagreePositionSetting/' + id, null, function () {
|
| | | febs.alert.success('禁止成功');
|
| | | $query.click();
|
| | | });
|
| | | }
|
| | | function agree(id) {
|
| | | febs.get(ctx + 'tradeManage/agreePositionSetting/' + id, null, function () {
|
| | | febs.alert.success('开启成功');
|
| | | $query.click();
|
| | | });
|
| | | }
|
| | |
|
| | |
|
| | | // 查询按钮
|
| | |
| | | return ''
|
| | | }
|
| | | }, minWidth: 80,align:'center'},
|
| | | {field: 'refererId', title: '账号状态',
|
| | | {field: 'accountStatus', title: '账号状态',
|
| | | templet: function (d) {
|
| | | if (d.accountStatus === 1) {
|
| | | return '<span style="color:green;">正常</span>'
|
| | |
| | | return ''
|
| | | }
|
| | | }, minWidth: 80,align:'center'},
|
| | | {field: 'refererId', title: '审核状态',
|
| | | {field: 'certifyStatus', title: '审核状态',
|
| | | templet: function (d) {
|
| | | if (d.certifyStatus === 0) {
|
| | | return '<span style="color:red;">未通过</span>'
|
| | |
| | | return ''
|
| | | }
|
| | | }, minWidth: 80,align:'center'},
|
| | | {field: 'pcState', title: '是否可平仓',
|
| | | templet: function (d) {
|
| | | if (d.pcState === 1) {
|
| | | return '<span style="color:#ff0000;">否</span>'
|
| | | } else {
|
| | | return '<span style="color:green;">是</span>'
|
| | | }
|
| | | },minWidth: 100,align:'center'},
|
| | | {field: 'createTime', title: '注册时间', minWidth: 180,align:'center'},
|
| | | {title: '操作',
|
| | | templet: function (d) {
|
| | | if (d.certifyStatus === 1) {
|
| | | return '<a lay-event="edit" shiro:hasPermission="user:update">审核认证</a>'
|
| | | +'<i class="layui-icon febs-edit-area febs-blue"></i>'
|
| | | +'<a lay-event="addCoin" shiro:hasPermission="user:update">拨币</a>'
|
| | | if(d.pcState === 1){
|
| | | return '<button className="layui-btn layui-btn-normal layui-btn-xs" lay-event="edit" shiro:hasPermission="user:update">审核认证</button>'
|
| | | +'<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="addCoin" shiro:hasPermission="user:update">拨币</button>'
|
| | | +'<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="agree" shiro:hasPermission="user:update">开启</button>'
|
| | | }else{
|
| | | return '<button className="layui-btn layui-btn-normal layui-btn-xs" lay-event="edit" shiro:hasPermission="user:update">审核认证</button>'
|
| | | +'<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="addCoin" shiro:hasPermission="user:update">拨币</button>'
|
| | | +'<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="disagree" shiro:hasPermission="user:update">禁止</button>'
|
| | | }
|
| | | }else if(d.certifyStatus === 2){
|
| | | return '<a lay-event="see" shiro:hasPermission="user:update">'
|
| | | +'<i class="layui-icon febs-edit-area febs-blue"></i></a>'
|
| | | +'<a lay-event="addCoin" shiro:hasPermission="user:update">拨币</a>'
|
| | | if(d.pcState === 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="addCoin" shiro:hasPermission="user:update">拨币</button>'
|
| | | +'<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="agree" 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="addCoin" shiro:hasPermission="user:update">拨币</button>'
|
| | | +'<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="disagree" shiro:hasPermission="user:update">禁止</button>'
|
| | | }
|
| | | }else {
|
| | | return '<a lay-event="addCoin" shiro:hasPermission="user:update">拨币</a>'
|
| | | if(d.pcState === 1){
|
| | | return '<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="addCoin" shiro:hasPermission="user:update">拨币</button>'
|
| | | +'<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="agree" shiro:hasPermission="user:update">开启</button>'
|
| | | }else{
|
| | | return '<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="addCoin" shiro:hasPermission="user:update">拨币</button>'
|
| | | +'<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="disagree" shiro:hasPermission="user:update">禁止</button>'
|
| | | }
|
| | | }
|
| | | },minWidth: 200,align:'center'}
|
| | | ]]
|