# Introduction

Products.CalendarX is an add-on for Plone that displays Events [1] in monthly, weekly and daily views. There is also localization for various languages included.

Note

The codebase is old (i.e. Archetypes content and RestrictedPython scripts) and does not conform to modern Plone development best practices.

Note

Version 0.9.7 and higher are Plone 4+ compatible. For Plone 3.x, please use an older release.

Other similar add-ons:

- http://plone.org/products/solgema.fullcalendar

Source code and issue tracker:

- https://github.com/collective/Products.CalendarX/

[1] | I.e. event-ish content, e.g. events created with the default Plone event content type.

## Changelog

# 1.0.1 (2012-11-05)

- Add missing event_icon.gif [aclark]
- Remove entry points causing install_requires to fail [aclark]

# 1.0.0 (2012-10-09)

- Plone 4.1 compatibility [miohtama, aclark, nteixeira, kteague] - for Plone 3.x releases use older version
- Fixed bad portal_catalog query syntax in get events scripts - was returning no results on P4.1 [miohtama]
- Fixed URL escaping issues in month view links [miohtama]
- Fixed syntax errors in getEventDictWeekbyday.py, getEventDictWeekbyhour.py [miohtama]
- Finnish translations [miohtama]

# v0.9.6(stable)

- bugfixes for getEventsXXX scripts (all four, for ZCatalog and Advanced Query) to handle properly the options for restrictToThisListOfPaths, restrictToThisListOfSubjects, and the Show Public/Private link that only shows events by the logged in Creator. [lupa]

# v0.9.5(stable)

- Refactored documentation to ReST, with help from glenfant. [lupa]

# v0.9.3(stable)

- Code base: v0.9.2(stable)
- Status: Stable release. All tested features work, one outstanding bug reported in the tracker (at Plone.org), some minor display bugs listed in docs/TODO.txt
- eggification: thanks to glenfant!

# v0.9.2(stable)

- Code base: v0.9.1(dev)
- Status: Stable release. All tested features work, one outstanding bug reported in the tracker (at Plone.org), some minor display bugs listed in docs/TODO.txt
- why: 0.9 branch is to introduce Plone 3 compatibility. Period.
- bugfix: CX_props_macros.pt: PrevNextCurrentLinks has JumpToDateWidget that was hardcoded to range(2000:2010) ending soon! Now this runs -4 to +6 years from current year instead.
- bugfix: CX_props_macros.pt: eventlister, mMeventlister macros: The class: defaulted to "eventPublished" instead of to classstate, fixed.
- bugfix: CalendarXFolder.py: added 'createObject?type_name=Event' as default value for createObjectOnClickCommand.
- improvement: CalendarXFolder.py: added as default the following values: 'published,external,internal,internally_published' for the listOfReviewStatesDisplayed properties.
- docs: updated INSTALL.txt to include buildout instructions for pulling CalendarX from SVN at plone.org. An egg is in the future.

# v0.9.1(alpha)

- Code base: v0.9.0(dev)
- Status: Alpha release. All tested features work, one outstanding bug reported in the tracker (at Plone.org), some minor display bugs listed in docs/TODO.txt
- why: 0.9 branch is to introduce Plone 3 compatibility. Period.
- bugfix: Events with NO category (subject) are shown when you show a calendar for the first time (where View All is checked, but none of the other categories are checked), but after that it is nearly impossible to display events with NO category chosen. This is an OLD bug.
- thefix: getDictCommon.py: checks to see if xsubALL is in the request and set to 'ALL' -- if it is, it sets xsub to 'ALL' before sending xsub to the query. Now by default, the View All checkbox WILL display events with NO category chosen. To see ONLY those events with selected categories, you must hit the Refresh button when all the categories are selected, but the View All is not selected. This makes intuitive sense to me. View All means ALL (including those with NO selected category).
- new: CalendarXFolder.py: Added a new attribute listOfSubCalendarIDs that is necessary in order to properly use subcalendars.
- mod: CalendarXFolder.py: Fixed several mislabeled attributes, and changed the order of some of them to more closely match the order and descriptions in the 0.6.6 release. Dropped "Topic" from schemata name for subcalendars, now is "Sub Calendar Properties".
- mod: CX_props_macros.pt: Bugfix. i18n msgid mislabeled as label_sublinks_show_backtoresources changed to label_sublinks_backtoresources (around line 475).
- mod: CX_props_macros.pt: Bugfix. Wrapped several more tal:conditions around spans to eliminate possible "tuple index out of range" errors coming from the python:test() usage. Needed to get the subcalendars working properly.
- mod: CX_props_macros.pt: Significant rewriting needed down in the subjectlinks macro to get the subcalendars working. Sheesh.
- mod: getDictCommon.py: checks for nameOfSubCalendar, uses that instead of the id if it is available for the header at the top of subcalendars.
- mod: CX_props_macros.pt: Bugfix. useMultiSubjects attribute works fine, but if you unchecked it, the subjectlinks macro broke. Fixed.
- new: CalendarXFolder.py: Added a new attribute listOfReviewStatesDisplayed where you can add other review states (such as 'pending' or 'external') and these will be appended onto the other states to display in your calendar.
- mod: getEventsBeforeZC.py, getEventsBetweenZC.py, getEventsBeforeAQ.py, getEventsBetweenAQ.py: modified the review_state query to accommodate the new listOfReviewStatesDisplayed attribute.
- mod: CalendarXFolder.py: TYPO, bugfix: memberSubfolderPath attribute in the Add Event Link Properties schemata was misspelled as memberSubFolderPath. Also updated the description to point out that if there is no member home folder, but this attribute is selected, then it will default back to a folder of this name but in the PORTAL ROOT, not in a member home folder.
- mod: getAddNewEventURL.py: bugfix. There is no member home folder now by default, and so the call to getHomeUrl() returned None, but was not trapped for that. Now it is, and so if there is no member home folder, but this attribute is selected, then it will default back to a folder of this name but in the PORTAL ROOT, not in a member home folder.
- new: added i18n/calendarx-sv.po file, contributed over a year ago by Martin Eliasson. I added (probably very wrongly) a guestimate of the translation of "manage" for the new manage tab, which didn't exist when Martin originally sent this to me.

# v0.9.0(dev)

- Code base: v0.6.6(stable)
- Status: Pre-alpha dev release. Seems to work, at least enough to test.
- why: 0.9 branch is to introduce Plone 3 compatibility. Period.
- mod: CalendarXFolder.py: Much reworking here to convert it to Archetypes. Pushed all the CX_props sheets into schemata (the hard work of this was done by folks at the PSU CalendarX Patch Sprint in Dec 2007 and checked into the Collective as the /plone3-compatibility branch). I added the CSS properties to finish it. Also fixed default from False to 0 for earlyDayEventHour attribute, which fixed some day and weekbyhour view errors.
- mod: CX_props_macros.pt: Bugfix. i18n bug shows up in Plone 3 because having tal:content and an i18n string together produces a conflict. Now only has i18n call (around line 472).
- mod: weekbyhour.pt: Bugfix. Found that the i18n for the bottom day titles was incompletely setup, causing them to remain i18n-less. Line 245 call to display month was missing a suffix '_3'. Fixed.
- mod: weekbyday.css: Bugfix. Removed CSS rule for TD class="hour" that was both wrong and superfluous (no such usage in the weekbyday template).
- new: showDefaultView.py. This simple script simply redirects to the view specified in the defaultView attribute. Used when you head toward the calendar without adding /month or /day or whatever view you want at the end.
- mod: CalendarXFolder.py: added aliases to point default view to the new showDefaultView.py redirector script.
- mod: CX_props_macros.pt: added a "manage" tab that gives easy access to editing the calendar properties. only shows up for logged-in users with "Manage portal content" permission for the calendar instance.
- mod: po files, added "label_managetab" msgid and (my own, doubtful) translations for each language, except for Japanese (I didn't translate that one). Write me with better ones, or better yet, check them into svn at the collective and email me that you've done so.
- mod: CX_props_macros.pt: Something has changed, probably in Zope 2.10 or possibly more recent Python versions. I used to be able to do this `tal:content="python:test(usesubtitles,subtitles[n-1],`subby)"` and it would NOT evaluate subtitles[n-1] unless usesubtitles was True. However, now it throws a tuple index out of range error, even if usesubtitles is False. So I'm reworking all the tal:content calls that use this sort of testing. The main ones are fixed, allowing us to use the Subject Bar again :-).
- still to do: fix more darned tuple index errors... I'm not seeing any of them show up, but I know that the code doesn't have the checks that it needs yet.
- still to do: fix the damned mouseover highlighting errors
- still to do: Possible problems with restrictToThisListOfSubjects, where View All categories highlights all subjects, but doesn't then display events with subject other than those checked, or does if it isn't restricted? Check pls.
- still to do: find the other po files given to me long ago, and put them in. Don't forget the "label_managetab" msgid.
- still to do: explore the new /tests added by the Sprinters. I haven't learned the use of testing in Plone yet, although I did learn it this summer in some other systems. I'll get to that next and maybe soon we'll actually have a meaningful test suite for CalendarX!