do that thing what i said for [#577]

This commit is contained in:
reality 2013-08-31 12:17:06 +00:00
parent c09e9de9f9
commit 9e67c94074
4 changed files with 7 additions and 25 deletions

View File

@ -5,13 +5,7 @@ var _ = require('underscore')._,
var pages = function(dbot) {
var pages = {
'/notify': function(req, res) {
res.render('servers', {
'servers': _.keys(dbot.config.servers)
});
},
'/notify/:server': function(req, res) {
var server = req.params.server,
var server = req.user.server,
userCount = {},
users = [],
channelCount = {};
@ -74,8 +68,8 @@ var pages = function(dbot) {
}
},
'/notify/:server/:item': function(req, res) {
var server = req.params.server,
'/notify/:item': function(req, res) {
var server = req.user.server,
notifies = [];
if(req.params.item.charAt(0) == '#') {

View File

@ -3,14 +3,14 @@ extends ../layout
block content
h3 Browse by Channel on #{server}
div#backlink
a(href='/notify') « Server List
a(href='/') « Home
ul#quotelist
-each count, name in channels
a(href='/notify/'+server+'/'+encodeURIComponent(name))
a(href='/notify/'+encodeURIComponent(name))
li.quotes #{name} (#{count})
h3 Browse by User on #{server}
ul#quotelist
-each nUser in users
a(href='/notify/'+server+'/'+encodeURIComponent(nUser.name))
a(href='/notify/'+encodeURIComponent(nUser.name))
li.quotes #{nUser.name} (#{nUser.count})

View File

@ -2,7 +2,7 @@ extends ../layout
block content
div#backlink
a(href='/notify/'+server) « Server
a(href='/notify') « Server
p
div#controls
input(type="text", name="search", id="search-text", oninput="searchNotifies(this.value)")

View File

@ -1,12 +0,0 @@
extends ../layout
block content
h3 Servers
div#backlink
a(href='/') « Home
div
a(href='/notify/'+user.server+'/missing') My Missed Notifications
ul#quotelist
-each server in servers
a(href='/notify/'+server)
li.quotes #{server}