0 Replies Latest reply on Jul 30, 2008 9:42 AM by Felipe Leite

    Accessing CalendarDataModelItem in boundary dates

    Felipe Leite Newbie

      Hi,

      I am trying to use rich:calendar to create show a schedule of appointments. I am using CalendarDataModel and CalendarDataModelItem to populate each dayCell of the month being shown.

      The only problem is that I would like to show this info for all the dates being rendered, and rich:calendar is only showing for the days of the selected month. For example, if the month rendered is July/2008, I would like to show data for June 29th and August 1st as these days are rendered.

      It seems to me that there are two problems here:

      1 - The method CalendarDataModel.getData(Date[] dates) is called with only dates between 2008-07-01 and 2008-07-31 (if the selected month is July). It would be better to have some way of configure the calendar component to call this method with all dates rendered (from 2008-06-29 to 2008-08-09, in this case).

      2 - I can set the preloadRange to contain the boundary dates, then CalendarDataModel.getData(Date[] dates) is called with the preload range. But it doesn't matter, because the CalendarDataModelItem instance related to that boundaryDate is not called.

      I would suggest a new boundaryDates mode. Today we have inactive, scroll and select modes. What about an "active" mode? So the boundary dates would behave exactly the same of the current month dates. Is there a problem with this approach?

      Just clarifying: I want some way of boundary date calling its to CalendarDataModelItem.getData() to work, rendering its output.

      I am sorry if there is already some way of achieving what I want, but I couldn't find it. If there is such a way, please tell me.

      I am using RichFaces 3.2.1.GA.