The "Show more notifications..." link in the notifications dropdown now links to /my/notifications, which is a historical view of all notifications you have recieved. Notification history is loaded in blocks of 60 at a time. Admins can see others' notification history. (This was requested for 'debugging purposes', though that's what impersonation is for, IMO.)
20 lines
655 B
JavaScript
20 lines
655 B
JavaScript
export default Discourse.Route.extend({
|
|
model: function() {
|
|
var user = this.modelFor('user');
|
|
return Discourse.NotificationContainer.loadHistory(undefined, user.get('username'));
|
|
},
|
|
|
|
setupController: function(controller, model) {
|
|
this.controllerFor('user').set('indexStream', false);
|
|
if (this.controllerFor('user_activity').get('content')) {
|
|
this.controllerFor('user_activity').set('userActionType', -1);
|
|
}
|
|
controller.set('model', model);
|
|
controller.set('user', this.modelFor('user'));
|
|
},
|
|
|
|
renderTemplate: function() {
|
|
this.render('user-notification-history', {into: 'user', outlet: 'userOutlet'});
|
|
}
|
|
});
|