feat: poll groups/servers, timed polls, features sort+filter by group
This commit is contained in:
@@ -9,6 +9,8 @@ const App = {
|
||||
{ id: 'templates', label: '邮件模板', icon: 'fa-envelope', roles: ['owner','admin'] },
|
||||
{ id: 'settings', label: '系统设置', icon: 'fa-cog', roles: ['owner','admin'] },
|
||||
{ id: 'export', label: '数据导出', icon: 'fa-download', roles: ['owner'] },
|
||||
{ id: 'polls', label: '投票', icon: 'fa-poll', roles: ['owner','admin','player'] },
|
||||
{ id: 'features', label: '更新内容', icon: 'fa-lightbulb', roles: ['owner','admin','player'] },
|
||||
],
|
||||
|
||||
async init() {
|
||||
@@ -76,6 +78,8 @@ const App = {
|
||||
case 'templates': this.renderMain('邮件模板', TemplatesPage, param); break;
|
||||
case 'settings': this.renderMain('系统设置', SettingsPage, param); break;
|
||||
case 'export': this.renderMain('数据导出', ExportPage, param); break;
|
||||
case 'polls': this.renderMain('投票', PollsPage, param); break;
|
||||
case 'features': this.renderMain('更新内容', FeaturesPage, param); break;
|
||||
default: this.renderMain('控制台', Dashboard, param);
|
||||
}
|
||||
},
|
||||
@@ -98,6 +102,7 @@ const App = {
|
||||
const u = Auth.user();
|
||||
el.innerHTML = `<span class="tm ts">${U.esc(u.game_name||u.username)}</span>
|
||||
<a href="#/dashboard" class="btn btn-p btn-sm"><i class="fas fa-chart-simple"></i> 控制台</a>
|
||||
<a href="#/polls" class="btn btn-o btn-sm"><i class="fas fa-poll"></i></a>
|
||||
${Auth.isAdmin() ? `<a href="#/unclaimed" class="btn btn-o btn-sm">待处理</a>`:''}
|
||||
<button class="btn btn-o btn-sm" onclick="App.logout()"><i class="fas fa-sign-out-alt"></i> 退出</button>`;
|
||||
} else {
|
||||
@@ -144,6 +149,8 @@ window.TemplatesPage = TemplatesPage;
|
||||
window.NotificationsPage = NotificationsPage;
|
||||
window.SettingsPage = SettingsPage;
|
||||
window.ExportPage = ExportPage;
|
||||
window.PollsPage = PollsPage;
|
||||
window.FeaturesPage = FeaturesPage;
|
||||
window.LoginPage = LoginPage;
|
||||
window.RegisterPage = RegisterPage;
|
||||
window.HomePage = HomePage;
|
||||
|
||||
Reference in New Issue
Block a user