Clemens,
Your suggestion gets me part of the way there but still having some problems
(in steps 11 and 12 below). I thought maybe my earlier futzing around trying
to get it working on my own screwed things up. So I created a clean instance
on a VM and made the mods you suggested. Here are the steps I followed and
the results.
1. Created new XWiki 7.4 instance - distribution wizard doesn't start for
some reason so I installed the default pages using
xwiki-enterprise-ui-mainwiki-all-7.4.xar.
2. Installed MoccaCalendar extension and verified that version is 2.5 (full
calendar macro is version 2.0.2)
3. Logged in as Admin and created a new calendar (first to verify behaviour
without your suggested mods to JSON Service).
4. In the new calendar created an event - event is displayed as expected.
5. In the new calendar, tried to create another event with the same title -
event form displays 'An event with this name already exists.' under the
title field.
6. In the new calendar, tried to create another event with no title - event
form displays 'Title field is required'.
7. Deleted event created in step 4.
8. In class editor MoccaCalendarEvent class added new field 'Test' of type
String.
9. Navigated to /xwiki/bin/view/MoccaCalendar/JSONService -> Edit -> Source
and replaced $itemdoc.getPlainTitle() with $itemdoc.getValue('Test') in two
places as you suggested.
10. Returned to new calendar created in Step 3.
11. Invoked form to create an event - event form is displayed with new Test
field (blank). But the Title field is populated with a random string and the
Calendar drop down field where you can select which calendar the event
belongs to is missing from the form.
12. Entered a value in the Test field and saved the event - the form
disappears but the event is not displayed on the new calendar.
13. Navigated to Calendar Overview and observed that new event is displayed
there with the content of the Test field instead of the Title. Here the
event is displayed on the Month view the way I want it.
--
View this message in context:
http://xwiki.475771.n2.nabble.com/Mocca-calendar-display-short-description-…
Sent from the XWiki- Users mailing list archive at
Nabble.com.