Mobile Calendar Application shows the way how to use the FullCalendar (http://arshaw.com/fullcalendar/) in xPages environment. Provided database is full-featured, standalone application that works as is to allow quick adoption but is also as clear as much in design to help developer understand how the things work like and how to use it in his own application.
a) kudos to FullCalendar authors .. really - it really great calendar product with huge documentation and localization options <a href="http://arshaw.com/fullcalendar/">http://arshaw.com/fullcalendar/</a></div>
b) calendar looks nice on mobile devices (tested Blackberry, iPhone/iPad and Android phones) as well as in desktop browsers
c) calendar has a great localization options so its very easy to adapt for the other languages ... ( we speak czech :-) )
d) uses JSON for data sources so its very easy to integrate with LN
e) support for multiple calendars listed in the one calendar view (calendars have different colors)
a) JQuery & JQuery Mobile for mobile user interface <a href="http://jquerymobile.com/">http://jquerymobile.com/</a><br/>
-(we prefer it for great compatibility, documentation and easy usage in xPages) - this app is also the proof how easy it is to integrate with xPages<br/>
b) datasource is created in JAVA (we prefer it as better option than SSJS for larger codes<br/>
- honestly we use JAVA for almost everything in xPages as better option)</div>
c) JODD utility library <a href="http://jodd.org">http://jodd.org</a><br/>
- we use this library as the source of many helpers when working with Strings, Arrays, Dates and many, many others. And they have really great documentation that allows fast adoption. (formerly we were using well known Apache Commons libraries but we have encoutered some issues with xPages see here <a href="http://www-10.lotus.com/ldd/xpagesforum.nsf/topicThread.xsp?documentId=FD4D84A98FD9E23E8525791700338154&action=openDocument">http://www-10.lotus.com/ldd/xpagesforum.nsf/topicThread.xsp?documentId=FD4D84A98FD9E23E8525791700338154&action=openDocument</a> )</div>
d) GSON <a href="http://code.google.com/p/google-gson/">http://code.google.com/p/google-gson/</a> - easy to use JSON converter</div>
e) managed bean is being involved<br/>
- its just an option we made to show, how easy it is in xPages to use this mechanism :-)</div>
Q: Why to use another calendar when we have Traveler or iNotes?
A: I can see many situations where the custom calendar is great and easy to use option for xPages application
a) you want to integrate data not coming from user calendar into your application
b) you want to show users calendar entries in your custom application
Q: Why you don't package this calendar app into the one, easy to use, standalone xPages control?
A: I believe, that there are situations, where mixing GUI, code and some glue code into one control is not the good practice. This app wants to make things clear so user/developer can easy adopt this into own application with having the full control over the result.
1. xPages used in application
a) calendar_user.xsp - shows items from users calendar (requires used is logged into application)
b) calendar_demo.xsp - shows items dynamically generated - its just and showcase how to view calendar options gathered/created in java code</div>
c) calendar_data.xsp - its the agent-like xpage that works as a glue between calendar in browser(that uses ajax to gather data) and backing bean that returns the data</div>
2. Managed bean in action (use package explorer here)
There is a managed bean involved in process. There are probably easier ways(e.g. using static methods) to access calendar bean but its so easy in Domino to use managed bean ... so why not to use it here ...
You can find Managed bean configuration in package explorer here:
Application contains script library called 'calendar.js'
This file uses all required JS code with options easy to use in localization process. And when not sure, look at <a href="http://arshaw.com/fullcalendar/docs/text/">http://arshaw.com/fullcalendar/docs/text/</a></div>
3. Calendar backing bean (use package explorer here)
JAVA class name: calendar.CalendarServices
<span style="font-family:courier new,courier,monospace;">public String getUserCalendarAsJSON(String start, String end)<br/>
- lists entries from user's calendar and converts them to JSON</span></div>
<span style="font-family:courier new,courier,monospace;">public String getDemoItemsInJSON(String start, String end)<br/>
- generates demo entries for requested date interval - its very easy to adopt this method for your own purposes</span></div>
<strong>HOW TO USE IT: </strong>(requires Domino 8.5.2 and higher)</div>
a) download the database
c) sign it
d) update the ACL
e) open in browser