mirror of
https://github.com/vale981/Vulcan
synced 2025-03-09 20:16:39 -04:00
38 lines
No EOL
812 B
JavaScript
38 lines
No EOL
812 B
JavaScript
// Controller for post digest
|
|
|
|
PostsSingledayController = RouteController.extend({
|
|
|
|
template: getTemplate('singleDay'),
|
|
|
|
data: function() {
|
|
var currentDate = this.params.day ? new Date(this.params.year, this.params.month-1, this.params.day) : Session.get('today');
|
|
Session.set('currentDate', currentDate);
|
|
},
|
|
|
|
getTitle: function () {
|
|
return i18n.t('single_day') + ' - ' + getSetting('title', 'Telescope');
|
|
},
|
|
|
|
getDescription: function () {
|
|
return i18n.t('posts_of_a_single_day');
|
|
},
|
|
|
|
fastRender: true
|
|
|
|
});
|
|
|
|
Meteor.startup(function () {
|
|
|
|
// Digest
|
|
|
|
Router.route('/day/:year/:month/:day', {
|
|
name: 'postsSingleDay',
|
|
controller: PostsSingledayController
|
|
});
|
|
|
|
Router.route('/day', {
|
|
name: 'postsSingleDayDefault',
|
|
controller: PostsSingledayController
|
|
});
|
|
|
|
}); |