Full Calendar

  • Tags: /
  • Latest: 1.5.1.0
  • Last Updated: 09 June 2011
  • Grails version: 1.3.1 > *
  • Authors: null
6 votes
Dependency:
compile ":full-calendar:1.5.1.0"

 Documentation

Summary

Installation

grails install-plugin full-calendar

Description

Adam Shaw has written a full page javascript calendar component using jQuery: http://arshaw.com/fullcalendar/ See the page above and the Screenshots tab for more.

Usage

Add the following tag to the head to include the fullcalendar javascript and css, as well as jquery and jquery-ui resources.

<fullcal:resources/>

To use the unminimised version of fullcalendar.js add the debug option:

<fullcal:resources debug="true"/>

Then you can either use the javascript directly in the page, as specified at http://arshaw.com/fullcalendar/docs/usage/:

$(document).ready(function() {

// page is now ready, initialize the calendar...

$('#calendar').fullCalendar({ // put your options and callbacks here })

});

Or there is a very simple tag to output the javascript above, with the body of the tag being output into the 'put your options and callbacks here' line above:

<fullcal:calendar id="cal">
    header: { left: "", center: "", right: "prev, today, next" },
    columnFormat: { week: 'ddd d/M' },
    timeFormat: 'HH:mm{ - HH:mm}'
</fullcal:calendar>

There is comprehensive documentation about all the available options at http://arshaw.com/fullcalendar/docs/

If you check out the plugin source from https://svn.codehaus.org/grails-plugins/grails-full-calendar/tags/LATEST_RELEASE/ and run it with

grails run-app
there's a demo page at http://localhost:8080/full-calendar/index.gsp showing some of the javascript options in action - such as how to add events, which is not initially obvious.