OverviewSince 4.2 The ace:schedule component displays a month, week or day view of scheduled events as well as specific details about each of them. The event details can be displayed on a popup, on the sidebar or on a tooltip. It also has built-in functionality to add, edit and delete events. Individual days can be selected to look more closely at them when changing to the week or day views. The component can work in a lazy-loading mode, only loading the events that are visible in the current view for a given date. The component can be configured with a specific time zone for each user, so that international events can be displayed in the local user's time. There's ajax support for nine different actions within the component, and there are multiple other ways to configure the component for a more custom user experience.
Getting StartedIn its simplest form, an ace:schedule component only requires to have a list of ScheduleEvent objects bound to it.
<ace:schedule id="schedule" value="#{bean.events}"/>
private List<ScheduleEvent> events = new ArrayList<ScheduleEvent>() {{ ScheduleEvent event = new ScheduleEvent(); event.setStartDate(getDate()); event.setTitle("My Event"); event.setLocation("My Location"); add(event); }}; Attributes
The value should be a List, Array, DataModel or a type that can be adapted into a DataModel (java.sql.ResultSet, javax.servlet.jsp.jstl.sql.Result, and java.util.Collection). It must contain the org.icefaces.ace.model.schedule.ScheduleEvent objects to be displayed on the schedule. Alternatively, the value can be an implementation of org.icefaces.ace.model.schedule.LazyScheduleEventList to work in a lazy-loading mode, month per month. The viewMode attribute specifies the range of days that should be displayed at a time in the calendar. Possible values are 'month', 'week', 'day'. The default value is 'month'. The viewDate property holds a Date object specifying the date that is currently displayed in the client. This attribute can be used to set an initial date to display or to programmatically set a date to display. This attribute will be automatically updated with the current date being displayed in the client as the user interacts with the component. If the current view mode is set to 'month', this Date object will be automatically changed to the first day of the given month. If the current view mode is set to 'week', this Date object will be automatically changed to the previous Sunday, when the week starts. If the current view mode is set to 'day', this Date object will not change. The time values are irrelevant for this attribute. If this attribute is not specified, the current date is going to be used. This Date object is assumed to be in the time zone specified by the 'timeZone' attribute. The timeZone attribute is used to specify a time zone ID String (matching an element of java.util.TimeZone.getAvailableIDs()) or a java.util.TimeZone instance to specify the time zone used for date conversion to and from UTC time. If not specified, the default value is TimeZone.getDefault(), which is the default time zone on the system. The sideBar attribute specifies the location of the sidebar or whether it should be hidden. Possible values are 'right', 'left', and 'hidden'. The default value is 'right'. The showEventDetails attribute specifies where to display the event details after clicking on an event tag on the calendar. Possible values are 'sidebar', 'popup', 'tooltip', and 'disabled'. The default value is 'popup'. Client Behavior Events
JavaScript APIsICEfaces 4+The "widgetVar" attribute on the ACE components has been removed in ICEfaces 4 and in its place a new "ice.ace.instance()" client JavaScript object lookup API has been introduced. The reason for this change is to enable lazy-initialization of the ACE component JavaScript objects to improve runtime performance and reduce browser memory use. var widget = ice.ace.instance('frm:componentId);
Keyboard and ARIA SupportNot supported at the moment. Known IssuesOn IE8, when changing to the week or day views a javascript error is produced sometimes. Tips
|
Schedule
© Copyright 2021 ICEsoft Technologies Canada Corp.