Event Calendar
' +
'{{/webcast}}'
),
event: function(){
return (
''+
'{{#items}}' +
'
' +
'
{{{date}}} {{timeZone}}
' +
'
' +
'- ' +
'' +
this.location +
this.speakers +
this.webcast +
this.addToCal +
this.news +
this.docs +
this.presentations +
this.financials +
'
' +
'
' +
'
' +
'{{/items}}'
);
},
presentations: (
'{{#presentations}}' +
'
' +
'
' +
'
Q4 Presents at Morgan Stanley Conference
' +
'
' +
'
' +
'
' +
'{{/presentations}}'
)
},
calendar: {
clickEvents: {
click: function(target) {
var events = {
date: null,
items: []
}, o = $.q4.calendar._proto.options;
if (target.events.length) {
$.each(target.events, function(i, e){
var event = e.items;
events.items.push({
date: moment(event.StartDate).format(o.dateFormat),
timeZone: event.TimeZone == "0" ? "" : event.TimeZone,
docs: event.Attachments,
id: new Date(event.StartDate) > new Date() ? event.EventId : !!0,
location: event.Location,
news: event.EventPressRelease,
presentations: event.EventPresentation,
speakers: event.EventSpeaker,
title: event.Title,
url: event.LinkToDetailPage,
webcast: event.WebCastLink,
financials: event.EventFinancialReport
});
});
$(o.popupCls).addClass('open').html( Mustache.render( o.eventTemplates.event(), events ));
}
}
},
daysOfTheWeek: ['Sun','Mon','Tue','Wed','Thu','Fri','Sat'],
ready: function() {
var $events = $('#latest-events');
$events.on('click', '.q4-atc-button', function(e){
e.preventDefault();
$.fancybox.open( $(this).parent().find('.q4-atc-wrapper').clone() );
$('.q4-atc-links a').on('mouseenter', function () {
var $tooltip = $(this).parents('.q4-atc-inner').find('.q4-atc-tooltip');
$tooltip.children('.q4-atc-tooltip-text').html( $(this).children('span').html() );
$tooltip.stop(true, true).fadeIn(100);
}).on('mouseleave', function () {
$(this).parents('.q4-atc-inner').find('.q4-atc-tooltip').stop(true, true).fadeOut(100);
});
});
$events.on('click','.popup-close',function(){
$events.removeClass('open');
});
}
}
});