1 ##master-page:HelpTemplate 2 ##master-date:Unknown-Date 3 #format wiki 4 #language en 5 6 == EventAggregator == 7 8 The !EventAggregator macro for !MoinMoin can be used to display event calendars or listings which obtain their data from pages belonging to specific categories (such as CategoryEvents). 9 10 == Creating Events == 11 12 Before creating any events, create a category for those events. You can do this by filling out and submitting this form: 13 14 <<NewPage(CategoryTemplate,Add a new category,,Category%s)>> 15 16 Each event must be created on a new page belonging to the appropriate event category. For CategoryEvents, you can do this by filling out and submitting this form: 17 18 <<NewPage(EventTemplate,Add an event)>> 19 20 The event page describes the event in more detail, and the start and end dates of the event must be specified in a definition list so that they can be read from the page and displayed by the !EventAggregator. The EventTemplate provides some guidance, and all you need to do is to replace the `YYYY-MM-DD` placeholders with actual year, month and day values. For example: 21 22 {{{ 23 Start:: 2009-06-28 24 End:: 2009-07-04 25 }}} 26 27 You can add text which is more readable for humans provided that the `YYYY-MM-DD` format values are present somewhere in each entry. For example: 28 29 {{{ 30 Start:: Sunday 28th June 2009 (2009-06-28) 31 End:: Saturday 4th July 2009 (2009-07-04) 32 }}} 33 34 Obviously, duplicating the date information introduces a risk of this information becoming inconsistent, so beware! 35 36 === Supported Event Properties === 37 38 As well as the start and end dates of an event, the following properties are also recognised as being part of an event description: 39 40 Title:: the preferred name of the event in the calendar 41 Summary:: a synonym for title 42 Topics:: a list of topics related to the event - use a comma (`,`) to separate topic names 43 Categories:: a synonym for topics 44 Location:: the location of the event 45 46 These properties may be incorporated into representations or summaries of events. 47 48 Textual properties can be quoted in a limited way using the verbatim or monospaced text Wiki syntax. For example: 49 50 {{{ 51 Summary:: <<Verbatim(EuroPython)>> 2009 52 Topics:: Python, <<Verbatim(EuroPython)>>, Zope 53 }}} 54 55 == Showing Event Calendars == 56 57 To show a calendar, use the !EventAggregator macro with a list of event categories. For example: 58 59 {{{ 60 ## Show Events and Training categories. 61 <<EventAggregator(CategoryEvents,CategoryTraining)>> 62 }}} 63 64 The calendar, shown by default, is automatically filled out with the details of each event in the specified category (or categories), colouring each event period in an automatically generated colour. 65 66 Specific periods can be defined using the `start` and `end` parameters. For example: 67 68 {{{ 69 ## Show June and July 2009. 70 <<EventAggregator(CategoryEvents,start=2009-06,end=2009-07)>> 71 }}} 72 73 By using specific month values, a fixed window of time can be presented, displaying only events occurring within that period. It is possible to omit `start` or `end` in order to show all events up to (by omitting `start`) or starting from (by omitting `end`) a particular month. 74 75 There are special values which are significant. The `current` value refers to the current month and can be used with the minus and plus operators to refer, respectively, to months before and after the current month: 76 77 {{{ 78 ## Show this and next month. 79 <<EventAggregator(CategoryEvents,start=current,end=current+1)>> 80 ## Show this and last month. 81 <<EventAggregator(CategoryEvents,start=current-1,end=current)>> 82 }}} 83 84 In addition, the `yearstart` and `yearend` values refer to the first and last months of the current year: 85 86 {{{ 87 ## Show this year's events. 88 <<EventAggregator(CategoryEvents,start=yearstart,end=yearend)>> 89 ## Show events from last December to next January. 90 <<EventAggregator(CategoryEvents,start=yearstart-1,end=yearend+1)>> 91 }}} 92 93 == Showing Event Lists == 94 95 A more plain view of events can be displayed by specifying the `mode` parameter as follows: 96 97 {{{ 98 <<EventAggregator(CategoryEvents,mode=list)>> 99 }}} 100 101 The `list` value causes a list view to be employed; the `calendar` value causes the default calendar view to be employed. 102 103 == See Also == 104 105 * HelpOnEventAggregatorSummary - an action producing iCalendar event summaries