mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-06 22:15:48 +01:00
removed debug
This commit is contained in:
@@ -58,7 +58,7 @@ define('notifications', ['sounds'], function(sound) {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
var updateNotifCount = function(count) {
|
function updateNotifCount(count) {
|
||||||
if (count > 0) {
|
if (count > 0) {
|
||||||
notifIcon.removeClass('fa-bell-o').addClass('fa-bell');
|
notifIcon.removeClass('fa-bell-o').addClass('fa-bell');
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -56,39 +56,6 @@ module.exports = function(app, middleware, controllers) {
|
|||||||
});
|
});
|
||||||
|
|
||||||
router.get('/test', function(req, res) {
|
router.get('/test', function(req, res) {
|
||||||
//res.redirect('404');
|
res.redirect('404');
|
||||||
var notifications = require('../notifications');
|
|
||||||
var nconf = require('nconf');
|
|
||||||
|
|
||||||
var username = 'julian';
|
|
||||||
var topicTitle = 'testing tags';
|
|
||||||
var topicSlug = '1748/testing-tags';
|
|
||||||
var postIndex = 1;
|
|
||||||
var tid = 1748;
|
|
||||||
var fromUid = 2;
|
|
||||||
|
|
||||||
notifications.create({
|
|
||||||
bodyShort: '[[notifications:user_posted_to, ' + username + ', ' + topicTitle + ']]',
|
|
||||||
bodyLong: 'asdasd khajsdhakhdakj hdkash dakhdakjdhakjs',
|
|
||||||
path: nconf.get('relative_path') + '/topic/' + topicSlug + '/' + postIndex,
|
|
||||||
uniqueId: 'topic:' + tid + ':uid:' + fromUid,
|
|
||||||
tid: tid,
|
|
||||||
from: fromUid
|
|
||||||
}, function(err, nid) {
|
|
||||||
notifications.push(nid, [1]);
|
|
||||||
res.json('done');
|
|
||||||
});
|
});
|
||||||
});
|
|
||||||
|
|
||||||
router.get('/dailyunread', function(req, res) {
|
|
||||||
//var userNotifs = require('./user');
|
|
||||||
user.notifications.getDailyUnread(1, function(err, data) {
|
|
||||||
if (err) {
|
|
||||||
res.json(500, err.message);
|
|
||||||
}
|
|
||||||
|
|
||||||
res.json(data);
|
|
||||||
|
|
||||||
});
|
|
||||||
})
|
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user