// This script MUST remain dynamic since the generated HTML is modified with a URL parameter
request.element.isStatic = 0;
configStruct = application.ptCalendar.getAppConfig();
UItheme = application.ptCalendar.getUItheme();
currentDate = Now();
currentMonth = month(currentDate);
currentYear = year(currentDate);
maxDisplayMonths = 12;
currentView = application.ptCalendar.defaultView;
currentViewURL = cgi.script_name;
viewParamName = application.ptCalendar.viewParamName;
qParamDelimiter = "?";
viewLinkData = StructNew();
// Get the view link data structure
if ( application.ptCalendar.viewPageMode EQ "Single" )
{
viewLinkData = application.ptCalendar.calRenderViewService.getCalViewPageStruct();
qParamDelimiter = "&";
// update the nextPrevLink URL ... for the Small Grid Calendar keep the current calendar view
if ( StructKeyExists(request.params,viewParamName) )
currentView = request.params[viewParamName];
// Make currentView safe for output in HTML and JS Links
currentView = application.ptCalendar.calRenderViewService.makeViewParamValueSafe(paramValue=currentView);
currentViewURL = currentViewURL & "?" & viewParamName & "=" & currentView;
}
else
{
viewLinkData = application.ptCalendar.calPageMapDAO.getCalPageMapStruct();
}
detailPageURL = "";
if( StructKeyExists(viewLinkData, "detailPage") and LEN(TRIM(viewLinkData.detailPage)) )
detailPageURL = viewLinkData.detailPage;
// Set Nav Dropdown display default
showNavDropdown = true;
// Check to see if we are in a single veiw displaying the event details... if so... do NOT show the category checkboxes
viewParamName = application.ptCalendar.viewParamName;
if ( application.ptCalendar.viewPageMode EQ "Single" ) {
if ( StructKeyExists(request.params,viewParamName) AND request.params[viewParamName] EQ "eventdetails" )
showNavDropdown = false;
}
// Make sure we have dates in the request.ptCalendar
if ( !StructKeyExists(request,"ptCalendar") )
application.ptCalendar.calRenderController.processSelectedDate();
// load jQuery headers
application.ptCalendar.scripts.loadJQuery(noConflict=1);
// load header for jQuery UI
application.ptCalendar.scripts.loadJQueryUI(themeName=UItheme);
// Load the inline JavaScript after the libraries have loaded
application.ptCalendar.scripts.addFooterJS(navDropDownFooterJS, "TERTIARY"); // PRIMARY, SECONDARY, TERTIARY