This is version . It is not the current version, and thus it cannot be edited.
[Back to current version]   [Restore this version]

The CalendarListPlugin provides a view into a schedule of events. (x past days, y futures days)

Using this plugin you can have a calendar of the the year's events, recording them as you discover them, and the plugin will display a list of the most recent and upcoming events.

Here are two screen shots. The first shows the page with the complete schedule. The second shows a wiki page called 'HomePage' with a small section of the schedule displayed as a list.

The schedule pages uses wiki markup to build the schedule list. Currently the date format must be precise - exactly the date, or exactly the date, a space, and the time with leading zero if the hour is under 10. I'm working on making the formatting more flexible and the date/time entry lest strict. I'd also like to be able to show unscheduled events.

CalendarListPlugin syntax:#

[{INSERT com.hurlbert.jspwiki.plugin.CalendarList listpagename='SVSchedule' futuredays='15' format=WEEKLY}]

Parameters#

show (optional)
Default: UNDONE
This determines which tasks are displayed in the task list. Valid values are: UNDONE, DONE, or ALL
undoneicon (optional)
Default: '<img src="attach?page=pic/cb_off.png" />'
"UnDoneIcon" This is the html necessary to display whatever icon you would like in the first column of the list for tasks which are uncompleted. The default attempts to display a small unchecked checkbox icon (an unfilled square) that has been attached to the page 'pic' - as it is on the jspwiki.
doneicon (optional)
Default: '<img src="attach?page=pic/cb_on.png" />'
"DoneIcon" This is the html necessary to display whatever icon you would like in the first column of the list for tasks which have been completed. The default attempts to display a small checkbox icon (an unfilled square) with a checkmark in the center. It looks for this icon as an attachment to the page 'pic' - as it is on the jspwiki.
donetext (optional)
Default: done
This is the text used to determine whether the task has been completed or not. The default is the word, "done" - if a task begins with "done," such as "done: Buy Dog Food," then it will be considered as completed. If the task just says "Buy Dog Food" it will be considered as uncompleted.

When the list is displayed, the icon will point to the edit page link and the text of the task will point to the view page link of the task. This allows you to see the task by clicking the text or quickly edit the task by clicking the icon so you can mark the task as done (or update the description).


Using TodoListPlugin#

Display uncompleted tasks

[{INSERT com.hurlbert.jspwiki.plugin.TodoListPlugin show=UNDONE}]

Display completed tasks

[{INSERT com.hurlbert.jspwiki.plugin.TodoListPlugin show=DONE}]

Display uncompleted tasks preceded by smiley faces (path removed for brevity)

[{INSERT TodoListPlugin undoneicon='<img src=\"attach?page=pic/smile.png\" />'}]

The attached screenshot, 'TodoSample.jpg,' was created with this content:

[{INSERT com.hurlbert.jspwiki.plugin.TodoEntryPlugin}]

[{INSERT com.hurlbert.jspwiki.plugin.TodoListPlugin show=UNDONE}]
----
!Completed Items
[{INSERT com.hurlbert.jspwiki.plugin.TodoListPlugin show=DONE}]

Some possible enhancements (feel free to add others)#

  • Sorting
  • Date display
  • Filtering - for example, show tasks completed in the last two weeks
  • Properties file for icon locations, done text etc? KieronWilkinson
    • Yes, good suggestion. It's difficult to add a new property file because I run several wikis from a single jar. In this configuration, each wiki instance gets passed the location of it's jspwiki.properties at startup. Adding a second properties file would require sending another parameter or some method for the wiki to locate it's specific .properties file. When operating from a common jar request.getRealPath() does not work. It returns null, so the app has no idea where it's running. This makes getting to a properties file inside the WEB-INF file difficult. (If anyone knows a way around this, please share. I saw some solutions that use resourcebundles, but they looked 'hackish.') However, I will look into adding some properties to the jspwiki.properties file. Thanks for the idea. Scott
  • Add a listpagename parameter/property so that the todo list could be displayed anywhere, not just on a the parent page. I see this as handy for the completed items. You may not want those hanging out on the same page as your undone tasks. Adding this parameter would allow the plugin to live on any page, but generate it's content based on the 'parent' list page.

(Hmmm, seems that I'm getting enough ideas here that I'm going to have to get Janne to install the TodoListPlugin on the jspwiki so I can create a todo list to keep track of them. Ha!)

Enjoy - Scott Hurlbert

Add new attachment

Only authorized users are allowed to upload new attachments.

List of attachments

Kind Attachment Name Size Version Date Modified Author Change note
zip
CalendarListPlugin v2.zip.zip 11.6 kB 1 06-Jul-2006 14:13 24.4.113.204
jpg
CalendarListPlugin.JPG 75.2 kB 1 03-Feb-2004 12:42 24.4.112.168
zip
CalendarListPlugin.zip 29.8 kB 2 11-Oct-2011 19:53 Jerry Andrews version 3
jpg
SVSchedule.JPG 105.6 kB 1 03-Feb-2004 12:42 24.4.112.168
jpg
calendarplugin1.jpg 100.5 kB 1 08-Jun-2009 18:48 198.204.133.208
jpg
calendarplugin2.jpg 66.1 kB 1 08-Jun-2009 18:48 198.204.133.208
« This particular version was published on 03-Feb-2004 12:01 by 24.4.112.168.