define(["jquery", "easy-admin"], function ($, ea) { var init = { table_elem: '#currentTable', table_render_id: 'currentTableRenderId', index_url: 'withdraw.withdraw/index', export_url: 'withdraw.withdraw/export', }; var Controller = { index: function () { ea.table.render({ init: init, toolbar: ['refresh', 'export'], limits: [10, 15, 20, 25, 50, 100, 300, 500], cols: [[ {type: "checkbox"}, {field: 'id', width: 100, title: 'ID', search: false}, {field: 'w_ordersn', minWidth: 180, title: '提现商户订单号(我的内部)'}, { field: 'status', minWidth: 120, title: '提现状态', templet: function (d) { if (d.status == 0) { return '未提现'; } if (d.status == 1) { return '提现成功'; } if (d.status == 2) { return '提现失败'; } if (d.status == 3) { return '已取消'; } if (d.status == 4) { return '已经提交'; } }, selectList: {0: '提现中', 1: '提现成功', 2: '提现失败', 3: '已取消'} }, {field: 'uid', width: 120, title: '用户UID'}, // {field: 'total_withdraw', minWidth: 120, title: '待提现总金额'}, // {field: 'total_income', minWidth: 120, title: '总充值'}, // {field: 'with_draw_success', minWidth: 120, title: '提现成功金额'}, // {field: 'jianyi', minWidth: 120, title: '提现建议'}, {field: 'apply_money', minWidth: 120, title: '申请金额'}, {field: 'practical_money', minWidth: 120, title: '提现金额'}, {field: 'service_money', minWidth: 120, title: '手续费'}, {field: 'service_tz', minWidth: 120, title: '手续费JH个数'}, {field: 'tips_text', minWidth: 120, title: '标记'}, {field: 'channel', minWidth: 120, title: '申请平台', selectList: {1: '支付宝', 2: '银行卡'}}, {field: 'zfb_number', minWidth: 150, title: '支付宝账号'}, {field: 'zfb_name', minWidth: 120, title: '支付宝真实姓名'}, {field: 'real_name', minWidth: 120, title: '银行卡真实姓名'}, { field: 'bank_no', minWidth: 180, title: '银行卡账号', templet: function (d) { return '银行卡 ' + d.bank_no; } }, {field: 'bank_name', minWidth: 150, title: '银行卡名字'}, {field: 'mchid', minWidth: 120, title: '提现商户'}, {field: 'transfer_type', minWidth: 120, title: '申请提现方式', selectList: {1: '自动', 2: '手动', 3: '线下'}}, { field: 'final_transfer_type', minWidth: 120, title: '最终提现方式', selectList: {0: '#', 1: '自动', 2: '手动', 3: '线下'} }, {field: 'fail_log', minWidth: 150, title: '失败原因'}, {field: 'create_at', minWidth: 180, title: '申请时间'}, {field: 'update_at', minWidth: 180, title: '提现时间'}, // {field: 'tips_text', minWidth: 120, title: 'xb'}, { width: 250, title: '操作', templet: function (d) { var button = ''; // if (ea.checkAuth('tx', init.table_elem) && d.status == 0) { if (d.status == 0) { button += ''; } // if (ea.checkAuth('cancel', init.table_elem) && (d.status == 0)) { if ((d.status == 0)) { // if (d.channel != 1){ button += ''; // } } if ((d.status == 3) && (d.is_show == 0)) { button += ''; } return button; }, } ]], }); ea.listen(); }, add: function () { ea.listen(); }, edit: function () { ea.listen(); }, stock: function () { ea.listen(); }, tx: function () { ea.listen(); }, withdrawerror: function () { ea.listen(); }, }; return Controller; });