SP Calendar Pro

stonehenge

I have created this JavaScript library in order to facilitate operations involving SharePoint calendars. I was inspired to create this because I have dealt with several calendar related projects at work that require collecting and filtering of calendars based on user provided datetimes. I realized how incredibly painstaking it was to collect calendar events from a list (especially recurring events), convert date/time values on a SharePoint form into date objects, and do the necessary filtering. This small library will greatly facilitate common operations involving SharePoint calendars.

This library has zero dependencies, not even jQuery. The ajax requests are done using SOAP, because as far as I know expanded recurring calendar events can only be returned with SOAP (not JSOM or REST, for whatever reason).

SP Calendar Pro key features:

  • Collects single and/or recurring calendar events.
  • Easily converts datetime information from a SharePoint list form into JS date objects.
  • Provides convenient methods to process various datetime comparison operations. Easily checks for whether user provided datetimes pose time conflicts, match datetimes, same dates, etc.
  • Basic ‘where’ operator to make simple comparisons.
  • Returns calendar events that occur after a specific date.
  • Collects regular list items in a similar manner as calendar events.
  • Has option to disable the often unwanted drag and drop feature on calendars.
  • Allows the user to specify which list field items should be returned.

SP Calendar Pro is hosted on GitHub, here.

Full Documentation

Source code: