mirror of
https://github.com/vale981/Vulcan
synced 2025-03-06 10:01:40 -05:00
fixed keyboard date switching
This commit is contained in:
parent
e2d164d593
commit
8b7421b0d2
2 changed files with 3 additions and 3 deletions
|
@ -33,10 +33,10 @@ Template.posts_digest.helpers({
|
||||||
Template.posts_digest.created = function(){
|
Template.posts_digest.created = function(){
|
||||||
var currentDate=moment(Session.get('currentDate')).startOf('day');
|
var currentDate=moment(Session.get('currentDate')).startOf('day');
|
||||||
var today=moment(new Date()).startOf('day');
|
var today=moment(new Date()).startOf('day');
|
||||||
$(document).bind('keydown', 'left', function(){
|
$(document).bind('keyup', 'left', function(){
|
||||||
Meteor.Router.to($('.prev-link').attr('href'));
|
Meteor.Router.to($('.prev-link').attr('href'));
|
||||||
});
|
});
|
||||||
$(document).bind('keydown', 'right', function(){
|
$(document).bind('keyup', 'right', function(){
|
||||||
if(isAdmin(Meteor.user()) || today.diff(currentDate, 'days') > 0)
|
if(isAdmin(Meteor.user()) || today.diff(currentDate, 'days') > 0)
|
||||||
Meteor.Router.to($('.next-link').attr('href'));
|
Meteor.Router.to($('.next-link').attr('href'));
|
||||||
});
|
});
|
||||||
|
|
|
@ -7,7 +7,7 @@ trackEvent = function(event, properties){
|
||||||
if(typeof mixpanel.track !== 'undefined'){
|
if(typeof mixpanel.track !== 'undefined'){
|
||||||
mixpanel.track(event, properties);
|
mixpanel.track(event, properties);
|
||||||
}
|
}
|
||||||
if(typeof GoSquared.DefaultTracker !== 'undefined'){
|
if(typeof GoSquared !== 'undefined' && typeof GoSquared.DefaultTracker !== 'undefined'){
|
||||||
GoSquared.DefaultTracker.TrackEvent(event, JSON.stringify(properties));
|
GoSquared.DefaultTracker.TrackEvent(event, JSON.stringify(properties));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue