|
|
@@ -1,62 +0,0 @@
|
|
|
-define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefined, Backend, Table, Form) {
|
|
|
-
|
|
|
- var Controller = {
|
|
|
- index: function () {
|
|
|
- // 初始化表格参数配置
|
|
|
- Table.api.init({
|
|
|
- extend: {
|
|
|
- index_url: 'user/team_rewards/index' + location.search,
|
|
|
- add_url: 'user/team_rewards/add',
|
|
|
- edit_url: 'user/team_rewards/edit',
|
|
|
- del_url: 'user/team_rewards/del',
|
|
|
- multi_url: 'user/team_rewards/multi',
|
|
|
- import_url: 'user/team_rewards/import',
|
|
|
- table: 'team_rewards',
|
|
|
- }
|
|
|
- });
|
|
|
-
|
|
|
- var table = $("#table");
|
|
|
-
|
|
|
- // 初始化表格
|
|
|
- table.bootstrapTable({
|
|
|
- url: $.fn.bootstrapTable.defaults.extend.index_url,
|
|
|
- pk: 'id',
|
|
|
- sortName: 'id',
|
|
|
- fixedColumns: true,
|
|
|
- fixedRightNumber: 1,
|
|
|
- columns: [
|
|
|
- [
|
|
|
- {checkbox: true},
|
|
|
- {field: 'id', title: __('Id')},
|
|
|
- {field: 'user_id', title: __('User_id')},
|
|
|
- {field: 'address', title: __('Address')},
|
|
|
- {field: 'date_time', title: __('Date_time'), operate:'RANGE', addclass:'datetimerange', autocomplete:false},
|
|
|
- {field: 'team_power', title: __('Team_power'), operate:'BETWEEN'},
|
|
|
- {field: 'level_id', title: '当日等级', operate:'BETWEEN'},
|
|
|
- {field: 'team_power_bonus_rate', title: '发放比例', operate:'BETWEEN'},
|
|
|
- {field: 'smh_team', title: '当日团队产币量', operate:'BETWEEN'},
|
|
|
- {field: 'commission', title: '当日收益', operate:'BETWEEN'},
|
|
|
- {field: 'team_commission', title: '当日伞下收益', operate:'BETWEEN'},
|
|
|
- {field: 'send_commission', title: '当日实际收益', operate:'BETWEEN'},
|
|
|
- {field: 'update_time', title: __('Update_time'), operate:'RANGE', addclass:'datetimerange', autocomplete:false},
|
|
|
- ]
|
|
|
- ]
|
|
|
- });
|
|
|
-
|
|
|
- // 为表格绑定事件
|
|
|
- Table.api.bindevent(table);
|
|
|
- },
|
|
|
- add: function () {
|
|
|
- Controller.api.bindevent();
|
|
|
- },
|
|
|
- edit: function () {
|
|
|
- Controller.api.bindevent();
|
|
|
- },
|
|
|
- api: {
|
|
|
- bindevent: function () {
|
|
|
- Form.api.bindevent($("form[role=form]"));
|
|
|
- }
|
|
|
- }
|
|
|
- };
|
|
|
- return Controller;
|
|
|
-});
|