Sun Worklist Manager Service Engine User's Guide

Correcting the Task Output Data Display

To customize the display and, potentially, the behavior of the task output data field, you need to perform the following steps:

  1. Create the JSP file that will display the output data field and place it in the /web/WEB-INF/handlers/output/ directory.

  2. Edit the /web/WEB-INF/includes/output-handler.jsp file. You need to update the if-else statement to make sure the newly created JSP file is included if the current task (represented by the oha_task variable) has the desired type (the oha_task.getTaskDefId() method).

In the actual JSP file that renders the task output data field, the following context is available through request attributes. Following are the attribute names, their types, and their meaning:

The task output data handler is much more complex than the one for the input data. First it should be able to operate in two modes, and instructions on which mode to use are passed in with the corresponding request attribute. It should either render the output data in HTML, or parse the updated output data. There is no standard way to do this, as the customized handler prepares the input form itself and is the only entity that knows what the request parameter names are and how to use them. Second it should be able to store it into the request attribute. In the latter case the output data handler is expected to prepare the org.w3c.dom.Element object and place it in the com.sun.glassfishesb.wlm.console.task-output-data request attribute.

When in rendering mode, the output handler should watch out for two flags:

In rendering mode, the handler JSP file is expected to output the HTML code suitable for display in the web browser. You can also consult these files to get a better understanding of the logic that needs to be defined: