Zimlet JavaScript API Reference - ZmCalendarApp

Class ZmCalendarApp


Extends ZmApp.

The calendar application manages the creation and display of appointments.

Defined in: ZmCalendarApp.js.

Class Summary
Constructor Attributes Constructor Name and Description
 
ZmCalendarApp(container, parentController)
Creates and initializes the calendar application.
Method Summary
Method Attributes Method Name and Description
<static>  
ZmCalendarApp.addCalViewMenu(parent)
Adds an invite actions submenu for accept/decline/tentative.
<static>  
ZmCalendarApp.addInviteReplyMenu(parent)
Adds an invite actions submenu for accept/decline/tentative.
<static>  
ZmCalendarApp.createMiniCalButton(parent, buttonId, dateButtonListener, dateCalSelectionListener, reparent)
Creates a new button with a DwtCalendar as the menu.
<static>  
ZmCalendarApp.createReminderButton(parent, buttonId, buttonListener, menuSelectionListener)
Creates a new button with a reminder options as its menu.
 
Gets the appointment compose controller.
 
getCalController(sessionId, searchResultsController)
Gets the calendar controller.
 
Gets the name of the calendar with specified id.
 
getCheckedCalendarFolderIds(localOnly, includeTrash)
Gets the list of checked calendar ids.
 
Gets a list of equipment.
 
Gets the free busy cache.
 
Gets the list controller.
 
Gets a list of locations.
 
Gets the list of calendar ids for reminders.
 
Gets the reminder controller.
<static>  
ZmCalendarApp.getReminderSummary(reminderMinutes)
Gets the summary of reminder info from the reminder minutes.
<static>  
Returns the reminder warning time display options formatted for preferences we create preferences reminder button here .
<static>  
Client side mapping of never is -1 and 'at time of event' is 0.
<static>  
ZmCalendarApp.setDefaultReminderTimePrefValueOnSave(pref, value, list)
On doing save, we modify the request and map zimbraPrefCalendarApptReminderWarningTimevalue so that the value of never, 0, is not changed at server.
 
showMiniCalendar(show, delay)
Shows the mini-calendar.
Methods borrowed from class ZmApp:
activate, addDeferredFolder, createView, deleteSessionController, disposeTreeControllers, getDisplayName, getInitialSearchType, getLimit, getName, getNumSessionControllers, getOverview, getOverviewContainer, getOverviewId, getOverviewPanelContent, getRemoteFolderIds, getSearchParams, getSessionController, getTypeFromController, isActive, launch, popView, pushView, reset, resetOverview, resetWebClientOfflineOperations, setAppView, setOverviewPanelContent, setView, stageView, startAlert, stopAlert, toString
Class Detail
ZmCalendarApp(container, parentController)
Creates and initializes the calendar application.
Author: Conrad Damon.
Parameters:
{DwtControl} container
the container
{ZmController} parentController
the parent window controller (set by the child window)
Method Detail
<static> {ZmActionMenu} ZmCalendarApp.addCalViewMenu(parent)
Adds an invite actions submenu for accept/decline/tentative.
Parameters:
{ZmButtonToolBar|ZmActionMenu} parent
the parent widget
Returns:
{ZmActionMenu} the action menu

<static> {ZmActionMenu} ZmCalendarApp.addInviteReplyMenu(parent)
Adds an invite actions submenu for accept/decline/tentative.
Parameters:
{ZmButtonToolBar|ZmActionMenu} parent
the parent widget
Returns:
{ZmActionMenu} the action menu

<static> ZmCalendarApp.createMiniCalButton(parent, buttonId, dateButtonListener, dateCalSelectionListener, reparent)
Creates a new button with a DwtCalendar as the menu.
Parameters:
{DwtComposite} parent
the parent
{String} buttonId
the button id to fetch inside DOM and append DwtButton to
{AjxListener} dateButtonListener
the listener to call when date button is pressed
{AjxListener} dateCalSelectionListener
the listener to call when date is selected in DwtCalendar
reparent

<static> ZmCalendarApp.createReminderButton(parent, buttonId, buttonListener, menuSelectionListener)
Creates a new button with a reminder options as its menu.
Parameters:
{DwtComposite} parent
the parent
{String} buttonId
the button id to fetch inside DOM and append DwtButton to
{AjxListener} buttonListener
the listener to call when date button is pressed
{AjxListener} menuSelectionListener
the listener to call when date is selected in DwtCalendar

{ZmApptComposeController} getApptComposeController(sessionId)
Gets the appointment compose controller.
Parameters:
sessionId
Returns:
{ZmApptComposeController} the controller

{ZmCalViewController} getCalController(sessionId, searchResultsController)
Gets the calendar controller.
Parameters:
sessionId
searchResultsController
Returns:
{ZmCalViewController} the controller

{String} getCalendarName(id)
Gets the name of the calendar with specified id.
Parameters:
{String} id
the id of the calendar
Returns:
{String} the name

{Array} getCheckedCalendarFolderIds(localOnly, includeTrash)
Gets the list of checked calendar ids. If calendar packages are not loaded, gets the list from deferred folder ids.
Parameters:
{Boolean} localOnly
if true, use local calendar only
includeTrash
Returns:
{Array} an array of ids

{ZmResourceList} getEquipment()
Gets a list of equipment.
Returns:
{ZmResourceList} the resource list

{ZmFreeBusyCache} getFreeBusyCache()
Gets the free busy cache.
Returns:
{ZmFreeBusyCache} free busy cache object

{ZmCalViewController} getListController()
Gets the list controller.
Returns:
{ZmCalViewController} the controller
See:
#getCalController

{ZmResourceList} getLocations()
Gets a list of locations.
Returns:
{ZmResourceList} the resource list

{Array} getReminderCalendarFolderIds()
Gets the list of calendar ids for reminders. If calendar packages are not loaded, gets the list from deferred folder ids.
Returns:
{Array} an array of ids

{ZmReminderController} getReminderController()
Gets the reminder controller.
Returns:
{ZmReminderController} the controller

<static> {String} ZmCalendarApp.getReminderSummary(reminderMinutes)
Gets the summary of reminder info from the reminder minutes.
Parameters:
{int} reminderMinutes
the number of minutes before which reminder should be shown
Returns:
{String} the summary

<static> ZmCalendarApp.getReminderTimeWarningDisplayOptions()
Returns the reminder warning time display options formatted for preferences we create preferences reminder button here .

<static> ZmCalendarApp.postLoadSetDefaultReminderValue()
Client side mapping of never is -1 and 'at time of event' is 0. If never is chosen in default reminder dropdown, user saves his preferences. We then modify the request and set the pref zimbraPrefCalendarApptReminderWarningTimevalue value to 0, to make the behaviour backward compatible, as earlier never was mapped to 0. Now, after reload, the value of pref zimbraPrefCalendarApptReminderWarningTimevalue in client side i.e ZmSetting.CAL_REMINDER_WARNING_TIME, is 0 as the server returns me this value. This was causing issue in the view of reminder option in pref section and while composing a new appt. So, here we map default reminder pref to its client side mapping. Same thing with 'at time of event'.

<static> ZmCalendarApp.setDefaultReminderTimePrefValueOnSave(pref, value, list)
On doing save, we modify the request and map zimbraPrefCalendarApptReminderWarningTimevalue so that the value of never, 0, is not changed at server. If never is selected in reminder dropdown, we map never value -1 to previous value, 0 and if 'at time of event' is chosen, we map 0 to -1 while constructing request.
Parameters:
pref
value
list

showMiniCalendar(show, delay)
Shows the mini-calendar.
Parameters:
{Boolean} show
if true, show the mini-calendar
{int} delay
the delay (in seconds)

Documentation generated by JsDoc Toolkit 2.3.0 on Tue Jun 28 2016 21:01:34 GMT-0400 (EDT)