Implementation Guide for Oracle Self-Service E-Billing > Using the Reporting Engine > Customizing the Reporting Engine >

Write Your Own Action Classes and ReportBean


Write your own Action class and action bean for your reports. Use the ReportActionHelper class to take care of common issues such as sorting and paging.

When writing your own action class, you must call the ReportActionHelper.execute() method. See Integration with Struts and Tiles for details about how to invoke this method.

When defining your own Struts ActionForm, you can make the form map-based, which allows you to pass any parameter into the Reporting Engine without explicitly adding a set of get and set methods. The only downside to this method is that a map-based property cannot be passed into JavaScript for client side validation.

For example, you can define two map methods: public Object getParameter(String name) and void setParameter(String name, Object value). To use these parameters in an HTML form or URL, use a notion similar to the following:

"parameter(contractNumber)=123456"

This expression passes the contract number to struts, which calls setParameter() on your Action Bean to put the contractNumber into the map. This parameter can either be used as an SQL data source input binding or used in template.

To retrieve the parameter as an inputBinding, use:

<inputBinding object="form" property="parameter(contractNumber)" />

To retrieve the parameter from the template, use:

$form.getParameter("contractNumber").

Implementation Guide for Oracle Self-Service E-Billing Copyright © 2014, Oracle and/or its affiliates. All rights reserved. Legal Notices.