HISTORY.txt CalendarX 0.5.3(dev) March 26 2005 (last modified for CalendarX 0.5.3) by +lupa+ (lupaz on sf.net, lupa at zurven dot com) Released under the GPL (see LICENSE.txt) CalendarX by Lupa Zurven (lupa at zurven dot com) A calendar for Plone. History: v0.5.3(dev) Code base: v0.5.2(dev) Status (development): Works for me, known issue with portal_factory is noted below. List of changed code files: helpcx.pt, CX_props_macros.pt, cxCreateEvent.cpy, weekbyhour.pt, weekbyday.pt, month.pt, portlet_calendarxp.pt, calendarPrint.css. Overview of changes: Fixed helpcx.pt so that it works properly with 0.5 branch. Fixed the +link bug for datestrings in the URL query that were not properly quoted for use in query strings. Fixed portlet_calendarxp bug that displayed wrong events in overlapping dates (march 1 and april 1 in the same view). Fixed calendarPrint problem: now removing subjectlinks properly. Added new property to cx_props_addeventlink to turn on/off the +links, and made mods to utilize this property. Attempted but did NOT fix the problem with addNewEvent links not using portal_factory when Events are selected there: current status is that portal_factory is bypassed, but with a documented one-line change in cxCreateEvent.py, you can allow portal_factory to be used even though the proper date, time, Title and Description parameters will NOT be passed in to the temporary event. mod: helpcx.pt: removed xpub and added CXsheetlist code, and moved/fixed CSS/JS calls up into the HEAD tag for XHTML compatibility, and added a few other changes for XHTML too. And added a small bit of new text to describe the +links for adding new events. Anyone using the Help tabs for their users should consider rewriting the Help to make it more applicable to their specific portal use. mod: CX_props_macros.pt: hoursdisplay: added url_quote to the date strings in the URL query for use in the day template. NOTE: ONLY url_quote the dates, not the entire query string. Can't do the '?', maybe other parts. Be careful. mod: cxCreateEvent.cpy: added url_unquote because we now use url_quote on the datestrings because they can be very complex ("GMT+1" needs this because without quoting it, the + signs turn to spaces). mod: weekbyhour.pt, weekbyday.pt, month.pt: added url_quote in the date strings for +links. mod: portlet_calendarxp.pt: fixed the bug in the popups that was bringing wrong info in for overlapping date numbers (march 1 and april 1 in same month view). mod: CX_props_macros.pt: added class="subjectlinksrow" to tag in all the subjectlinks macros to fix Printing problem (subjectlinks was showing up when it should have been not). Also took HR tag out of the copyright macro. mod: calendarPrint.css: added these lines to visualNoPrint: TABLE.caltabs TR.subjectlinksrow, /* subjectlinks */ DIV.calxcopyright, /* the copyright macro */ to get rid of them in print mode. Left alone the earlier, but apparently unproductive line where SPAN.subjectlinks was used. mod: cxCreateEvent.cpy: many changes inside to try and fix it so that portal_factory can be used... but it doesn't work. As of this release, portal_factory use with Events DOES NOT put in the proper date, time as it does with non-use of portal_factory. Can't seem to get it right, but that seems to be because you CAN'T change a temporary object because it is just sitting in the REQUEST object, and portal_factory doesn't seem to have tools for making these changes BEFORE it goes into the REQUEST. I can envision some deep voodoo ways of doing this (monkeypatch), but am hoping there is a simpler means. This is a first priority for the next release, and I would love to hear from anyone with ideas. mod: cx_props_addeventlink.props: changed default Command string to use cxCreateEvent instead of default Plone createObject script. See docs for detail. mod: cx_props_addeventlink.props: added showAddEventPlusLinks boolean property to turn on and off the +links inside the calendar cells. Updated the docs file to reflect this change. mod: CX_props_macros.pt, month.pt, weekbyday.pt, weekbyhour.pt: modded to use the new showAddEventPlusLinks boolean property. History: v0.5.2(dev) Code base: v0.5.1(dev) plus changes in 0.4.13 and 0.4.14(stable) Status (development): Works for me, no/few known bugs. Overview of changes: XHTML compatible code for calendar and portlets. Fixed the Daylight Savings Time bug. Fixed the tuple index bug in subjecttitles. Added code to show Title, Description and print, email action icons, if desired. Mod to show Location in JS popup text block. New portlet (portlet_calendarxp) that is a near duplicate of portlet_calendar Plone standard, but works with a CalendarX instance. Create New Event links (plus signs) now show up in every cell on all the views for appropriate users. Fixed another DST bug in month.pt. mod: CX_props_macros.pt, day.pt, month.pt, weekbyday.pt, weekbyhour.pt: added a "headstuff" macro and calls that put it into each view template. headstuff adds title, description and action icons (email, print, etc.). mod: CX_props_calendar.props: added a showHeaderTitleAndIcons property that turns on/off the headstuff macro. Default is ON (show these). Condition is tested in headerstuff macro in CX_props_macros. mod: CX_props_macros_portlet.pt, CX_props_macros.pt, portlet_cx_choices.pt, day.pt, month.pt, weekbyday.pt, weekbyhour.pt: changes to make XHTML valid code throughout. Seems to be ok. Not tested with all manner of interesting options for event display added. Test your site for validity and report any problems to lupa (http://validator.w3.org). bugfix: CX_props_macros.pt, CX_props_macros_portlet.pt: subjectlinks: changed TWO lines to fix a bug if there are more Subjects than Subject Titles. Added a python script (below) to retrieve list of titles safely instead of directly calling it via getCXAttributes.py. new: getListOfSubjectTitles.py. Script that safely retrieves the titles from listOfSubjectTitles property. If there are too many Subjects, the script appends blank titles to the end of the list to avoid a tuple indexing error. modded from the version in 0.4 branch to use CXsheetlist. bugfix: getNumOfDays.py: Display bug in April 2005 was recognized where all events starting between April 3-30, 2005 and displayed on the April month view would display their rollover (mouseover) highlighting for the proper number of days, but shifted one day too early... for single day events, the day before the event would be highlighted. This was traced to a problem calculating the number of days from the start of the month when crossing the boundary for Daylight Savings Time. I think this fix is only important for servers set to adjust for DST... but you never know, and the the fix will not cause any problems if DST is ignored on your site. mod: CX_props_popup.props: added a showPOPLocation property (default=false) mod: getDictCommon: gather, pass showPOPLocation property in Dict mod: CX_props_macros.pt: use showPOPLocation property in popuptextbox macro new: portlet_calendarxp.pt: clone of portlet_calendar (Plone default) that reads data from a CalendarX instance. Slight differences like this one includes the dates of preceding, trailing months. Otherwise similar. mod: getDaysOfTheWeekAbbreviated.py: added a "len" parameter that specifies the number of characters in the abbreviation [must be integer 1, 2, or 3]. mod: getDictMonth.py: fixed a spurious comment, no code change. bugfix: mod: getEventDictMonth.py: I didn't follow my own convention. In CalendarX I've been showing events to end on the previous day if their end time is midnight: e.g., if an event ends at midnight on Saturday (12am Saturday), then CalendarX stops the highlighting on Friday (not extending it to Saturday). THE BUG is that the date displayed was still extending to the following day. THE FIX is I added a couple lines to tell the datestring to back up one day if the end time was at midnight on a multi-day event. Same code change as fixed in branch 0.4.13. mod: CX_props_macros.pt, day.pt, month.pt, weekbyday.pt, weekbyhour.pt: made changes to create (+) plus sign links on all the views to allow addition of a new event on that day or at that hour in the calendar. THANKS SCOTT!! bugfix: month.pt. After Daylight Savings Time changes, the start DateTime would be miscalculated. Use a getStartOfDay() wrapped around the startDate call fixes this. Seems to be no related (too long a day) problem in October when DST begins. v0.5.1(dev) Code base: v0.5.0(dev) plus changes in 0.4.12(stable) Status (development): Works for me, no/few known bugs, but many new features and little or no thorough testing yet. new: here's a list of new scripts, templates, etc. calendar_portlet.css.dtml: css for portlet_calendarx.pt calendarPrint.css.dtml: css for Print version of calendarx CX_props_macros_portlet.pt: macros for the two portlets getContLaterEventsWBH.py: speeds up weekbyhour view by minimizing queries. getCXPortletContext.py: sets the context for portlet_calendarx to match that of the referred CalendarX instance. getCXSheetlist.py: speeds up attribute gathering by reducing skins usage month_portlet.css.dtml: css for portlet_calendarx.pt mod: here's a list of heavily modified scripts, templates, etc. month.pt: many changes to accommodate CXSheetlist day.pt: many changes to accommodate CXSheetlist weekbyday.pt: many changes to accommodate CXSheetlist weekbymonth.pt: many changes to accommodate CXSheetlist CX_props_macros.pt: many changes to accommodate CXSheetlist portlet_calendarx.pt: many changes to make it work better. you still have to configure it by adding a path to the CalendarX instance that it uses for determining which events it should show. mod: A bit of explanation on the speed optimizations that took place for this release. #1: SPEED UP THE PROPERTY SHEETS The getCXAttribute script was slow because it was used very often, even inside of loops where it would get called repeatedly, and it was expensive because it utilized the Plone skins methods to find the appropriate property sheet. To fix this, I did two things: A) took it out of all loops where it needn't be repeatedly called... just call it once before the loop starts, and B) introduce a new list object called CXSheetlist that is generated once at the beginning of each view, and consists simply of a list of references to the property sheet objects. Then I modified all the calls to getCXAttribute to include the CXSheetlist which allows getCXAttribute to bypass the skinning mechanism and go directly to the property sheets to get the information. Nothing is sacrificed but simplicity; the skinning mechanism is only hit once instead of dozens or hundreds of times. #2 SPEED UP THE QUERIES A query to the catalog is fairly fast, but the original design required at least one and sometimes multiple queries FOR EACH CELL displayed. So a month view would have up to 42 day cells, each getting two queries. I found that a list comprehension is about 10 times faster than a new query, so I went through all the code and do a minimum number of queries to the catalog at the beginning of each view, and then use list comprehensions to parse the catalog results over and over for each cell. Now the CalendarX views are much faster than before, and faster than the 0.4 branch queries even though much more complicated work is being performed in 0.5. v0.5.0(dev) Code base: v0.4.10(stable) Status (development): Works for me, no known bugs, but many new features and no thorough testing yet. new: here's a list of new scripts, templates, etc. CX_props_eventstoallow.props: what events to allow on the calendar CX_props_eventstorestrict.props: what events to restrict from the calendar CX_props_macros_portlet.pt: macros for the new cx_choices portlet getBaseDisallowQuery.py: sets up the query for disallowed events getBaseQuery.py: sets up the query for allowed events getCreatorList.py: gets a list of Creators to populate the new user picker getDaysOfTheWeekAbbreviated.py: abbreviations for new portlet_calendarx getGroupList.py: gets a list of groups for a new group picker widget (soon) getMonthName.py: abbreviations for JumpToDate widget portlet_calendarx.pt: portlet for a month calendar view portlet_cx_choices.pt: portlet with controls for calendar options mod: here's a list of heavily modified scripts, templates, etc. CX_props_calendar.props: a couple new properties, then removed all the properties related to allowing certain classes of events for all users and put them in the new CX_props_eventstoallow.props sheet. getEventsBeforeAQ.py getEventsBeforeZC.py getEventsBetweenAQ.py getEventsBetweenZC.py: many changes to make these queries more sane and manageable, and better documented internally. mod: there are a few other changes here and there that I didn't keep proper track of. It's a significantly new release branch. [for pre-v0.5.0 History, see HISTORY.txt files with those releases.]