You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
54 lines
1.7 KiB
54 lines
1.7 KiB
define(["jquery", "easy-admin"], function ($, ea) {
|
|
|
|
var init = {
|
|
table_elem: '#currentTable',
|
|
table_render_id: 'currentTableRenderId',
|
|
index_url: 'liveroom.index/index',
|
|
add_url: 'liveroom.index/add',
|
|
edit_url: 'liveroom.index/edit',
|
|
delete_url: 'liveroom.index/delete',
|
|
modify_url: 'liveroom.index/modify',
|
|
};
|
|
|
|
var Controller = {
|
|
|
|
index: function () {
|
|
|
|
ea.table.render({
|
|
init: init,
|
|
toolbar: [
|
|
'refresh',
|
|
'add',
|
|
'delete'
|
|
],
|
|
cols: [[
|
|
{type: "checkbox"},
|
|
{field: 'id', width: 80, title: '编号'},
|
|
{field: 'room_id', minWidth: 80, title: '房间号'},
|
|
{field: 'anchor_information', minWidth: 80, title: '主播信息'},
|
|
{field: 'link', minWidth: 80, title: '直播间链接'},
|
|
{field: 'status', title: '状态', width: 100, search: 'select', selectList: {0: '禁用', 1: '启用'}, templet: ea.table.switch},
|
|
{field: 'create_time', minWidth: 80, title: '创建时间', search: 'range'},
|
|
{
|
|
width: 250,
|
|
title: '操作',
|
|
templet: ea.table.tool,
|
|
operat: [
|
|
'edit',
|
|
'delete'
|
|
]
|
|
}
|
|
]],
|
|
});
|
|
|
|
ea.listen();
|
|
},
|
|
add: function () {
|
|
ea.listen();
|
|
},
|
|
edit: function () {
|
|
ea.listen();
|
|
}
|
|
};
|
|
return Controller;
|
|
});
|
|
|