Chad Lou, Brett Morris
This is Part II of our research into using non-Dojo toolkit assets in IBM Content Navigator and IBM Case Manager.
What we did in Part I:
• Loaded jQuery from Dojo
• Mixed Dojo and jQuery
• Made IBM Content Navigator API calls from Dojo and jQuery
Limitations in Part I:
• It is a standalone web page, and not integrated with IBM Content Navigator
• It only utilized the jQuery library, not the jQuery UI widgets
The standalone web page provides a good playground and a good starting point for enabling jQuery in IBM Content Navigator. However, the only supported mechanism for extending IBM Content Navigator is via an IBM Content Navigator plug-in. In this article, we will describe how to leverage jQuery UI assets within an IBM Content Navigator plug-in.
(The article covers the additional sections below, which can be found in the pdf file at the end of this post.)
Creating an IBM Content Navigator Plug-in
Packaging of jQuery and jQuery UI
Loading jQuery and jQuery UI
Loading the jQuery CSS resource
Showing the jQuery UI widget
Using jQuery for IBM Content Navigator/IBM Case Manager Mobile
Calling jQuery API from Dojo
Calling Dojo API from jQuery
Creating an IBM Content Navigator Feature plug-in
Feature Pane – JQueryFeaturePane.js
The associated template file for the Feature Pane
The corresponding css style definition for the Feature Pane
Enabling the new feature
The jQuery plug-in loads both jQuery and jQuery UI, as well as jQuery UI CSS. Through a combination of Dojo and jQuery calls, it retrieves the available actions in IBM Content Navigator, and displays the top 5 actions, using the menu widget from jQuery UI.
What we did in Part II:
• Packaged the functionality in an IBM Content Navigator feature plug-in
• Separated Dojo and jQuery modules
• Utilized a jQuery UI widget in IBM Content Navigator
• Packaged jQuery inside the IBM Content Navigator plug-in, so that no separate setup is needed
• Made it easier to upgrade to latest jQuery and jQuery UI
• Load jQuery library during the initialization stage of the jQuery plug-in
• Execute the jQuery UI feature when the feature icon is activated
The plug-in demonstrates that jQuery can be safely mixed with Dojo. jQuery can co-exist with Dojo, and jQuery UI widgets can be used in or to extend IBM Content Navigator or IBM Case Manager widget. The plug-in is attached. jQuery library and jQuery UI library do not need to be downloaded separately , they have already been included in the JQueryPlugin.jar. No separate setup is needed on IBM Content Navigator server. The plug-in works on the Navigator mobile app in the ICM feature as well.
The full details of the article can be downloaded as a PDF file. The plugin jar file is available as a ZIP file.