| | |
| | | maxmin: true,
|
| | | });
|
| | | }
|
| | | if (layEvent === 'addIsTrader') {
|
| | | febs.modal.confirm('设置合伙人', '设置成为合伙人?', function () {
|
| | | addIsTraderOn(data.id);
|
| | | });
|
| | | }
|
| | | if (layEvent === 'delIsTrader') {
|
| | | febs.modal.confirm('设置合伙人', '取消合伙人资格?', function () {
|
| | | delIsTraderOn(data.id);
|
| | | });
|
| | | }
|
| | | });
|
| | | function addIsTraderOn(id) {
|
| | | febs.get(ctx + 'yd/addIsTraderOn/' + id, null, function () {
|
| | | febs.alert.success('操作成功');
|
| | | $query.click();
|
| | | });
|
| | | }
|
| | | function delIsTraderOn(id) {
|
| | | febs.get(ctx + 'yd/delIsTraderOn/' + id, null, function () {
|
| | | febs.alert.success('操作成功');
|
| | | $query.click();
|
| | | });
|
| | | }
|
| | | function disagree(id) {
|
| | | febs.get(ctx + 'tradeManage/disagreePositionSetting/' + id, null, function () {
|
| | | febs.alert.success('禁止成功');
|
| | |
| | | //{field: 'realName', title: '姓名', minWidth: 100,align:'left'},
|
| | | {field: 'inviteId', title: '邀请码UID', minWidth: 80,align:'center'},
|
| | | {field: 'refererId', title: '上级邀请码UID', minWidth: 80,align:'center'},
|
| | | // {field: 'accountType', title: '账号类型',
|
| | | // templet: function (d) {
|
| | | // if (d.accountType === 2) {
|
| | | // return '<span style="color:green;">测试账号</span>'
|
| | | // } else if (d.accountType === 1) {
|
| | | // return '<span style="color:red;">正常账号</span>'
|
| | | // }else{
|
| | | // return ''
|
| | | // }
|
| | | // }, minWidth: 80,align:'center'},
|
| | | {field: 'isTrader', title: '状态',
|
| | | templet: function (d) {
|
| | | if (d.isTrader === 1) {
|
| | | return '<span style="color:green;">合伙人</span>'
|
| | | } else{
|
| | | return ''
|
| | | }
|
| | | }, minWidth: 80,align:'center'},
|
| | | // {field: 'accountStatus', title: '账号状态',
|
| | | // templet: function (d) {
|
| | | // if (d.accountStatus === 1) {
|
| | |
| | | // }
|
| | | // },minWidth: 100,align:'center'},
|
| | | {field: 'createTime', title: '注册时间', minWidth: 180,align:'center'},
|
| | | {title: '操作', |
| | | templet: function (d) {
|
| | | return '<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="addCoin" shiro:hasPermission="user:update">拨币</button>'
|
| | | },minWidth: 300,align:'center'}
|
| | | {title: '操作', templet: function (d) {
|
| | | if(d.isTrader === 2){
|
| | | 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="addIsTrader" shiro:hasPermission="user:update">成为合伙人</button>'
|
| | | }else if(d.isTrader === 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="delIsTrader" 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>'
|
| | | }
|
| | | },minWidth: 300,align:'center'}
|
| | | ]]
|
| | | });
|
| | | }
|