View source | View content page | Page history | Printable version   
Toolbox
Main Page
Upload file
What links here
Recent changes
Help

PDF Books
Show collection (0 pages)
Collections help

Search

Projects:Process Definition Reports/TechnicalSpecs

Contents

Process Defintion Reports - Technical Specs

Introduction

This project is delivered as a patch to be included in core. All the developments belong to core's module org.openbravo.client.application.

Application Dictionary

New Tab Reports based on new OBUIAPP_Report table.

Columns:

This table has a unique constraint on obuiapp_process so each Process Definintion can only have 1 record.

The report definition must belong to the same module than the header. The sourcedata datasource has been modified accordingly and a trigger has been created to avoid modifications when the module is not in development.

New Files

BaseReportActionHandler.java

Generic Action Handler to be used for reports. It can be used on any report if no additional requirements are needed.

In case that a report needs to to additional validations or it is desired to send to the jasper report additional parameters not defined as filter parameters it is possible to extend this class. Extra validations can be done overriding the doValidations empty method. Extra parameters can be defined in the addAdditionalParameters method adding them to the parameters Map.

The print process is done in a static synchronize method preventing multiple executions in parallel.

The Report is printed in 2 calls to the server. On the first call the report is generated and the file is stored in the tmp folder in the Openbravo Source folder. The response JSONObject includes a responseActions object to call the OBUIAPP_downloadReport action with the name and path of the temporary file.

The OBUIAPP_downloadReport does a new call to the ActionHandler using the GlobalHiddenForm to download the file. Once the file is downloaded it is deleted from the temporary folder.

ReportingUtils

New java utils class. It implements all the logic to print a report with all the parameters values set in the Process Definition window.


ob-reporting-action.js

New js file to define the OBUIAPP_downloadReport action that it is called on the response of the main report print to download the generated file.

Modified Files

ob-parameter-window-view.js

It adds the definition of the Export to PDF and Export to XLS buttons and the logic to show them.

ob-parameter-window-view.js and ob-pick-and-execute-grid.js

Modify the logic to enable or disable the export buttons when all required parameters are set.

ob-pick-and-execute-view-window.js.ftl and ParameterWindowComponent.java

It adds new properties to OBParameterWindowView for the reports based on the Report that it is being loaded.

Retrieved from "http://wiki.openbravo.com/wiki/Projects:Process_Definition_Reports/TechnicalSpecs"

This page has been accessed 447 times. This page was last modified on 20 January 2015, at 17:33. Content is available under Creative Commons Attribution-ShareAlike 2.5 Spain License.