Vulcan/packages/telescope-notifications/lib/server/routes.js
2014-12-03 08:45:43 +09:00

16 lines
No EOL
410 B
JavaScript

Meteor.startup(function () {
// Notification email
Router.route('/email/notification/:id?', {
name: 'notification',
where: 'server',
action: function() {
var notification = Herald.collection.findOne(this.params.id);
var notificationContents = buildEmailNotification(notification);
this.response.write(notificationContents.html);
this.response.end();
}
});
});