Introduction

The Report Builder introduces the simple drag-and-drop principle like the Form Builder, as a no-code/low-code alternative to create your own customized reports for Joget apps. This provides a seamless experience for users to create reports instead of using external report building softwares.

You can download the plugin from Joget Marketplace.

New Feature

The Report Builder is a plugin created for the Addon Builders. This is a new feature in Joget DX Enterprise and Professional editions.



PDF Report Generation

Joget PDF generation is only performed on the server-side, hence any JavaScript will not be executed because JavaScript is only executed on the client-side browser.
This means you cannot use JavaScript to modify the HTML for PDF. You will need a different approach where the form HTML modification is performed entirely on the server-side.
Ensure that your data source in Joget contains fields for image URLs or binary data, depending on how your images are stored. Should there are any need to run JavaScript, please do so on the server-side.

1. Ability to Run JavaScript:

Web View:

  • JavaScript can be executed in the web view as it runs in the browser. You can use JavaScript to manipulate the DOM, handle user interactions, and perform various client-side tasks.

PDF Generated Report:

  • PDFs typically do not execute JavaScript. Therefore, if your web view relies heavily on client-side JavaScript for dynamic behavior, those aspects may not be reflected in a static PDF generated from the same data.

2. Image Handling, PDF Parser, and URL Calls:

Web View:

  • In the web view, you can directly include images using HTML <img> tags or dynamically load them using JavaScript. If images are hosted externally, the browser will make URL calls to fetch them.

PDF Generated Report:

  • To include images in a PDF generated report, you need to handle the image data server-side. If the images are hosted externally, you may need to fetch them using a PDF generation library compatible with Joget. The process involves downloading the image data, embedding it in the PDF, and setting up the report layout.

3. Convert to Base64 to Prevent Server Call:

Web View:

  • In a web view, you can convert binary data (such as images) to Base64 directly in the client-side code. This can be useful for reducing server calls and improving performance.

PDF Generated Report:

When generating a PDF report in Joget, you can use server-side scripts (e.g., Groovy or Java) to convert binary data to Base64 before embedding it in the PDF. This can be part of the PDF generation process

  • Always consider the size and efficiency of handling large amounts of data, especially when converting binary data to Base64.
  • Be aware that Base64 encoding can increase the size of the data.

Ensure that you adapt the code to your specific use case, and consult Joget's documentation or community forums for the latest information and best practices.

Report Element & Report Properties

Click on each link for detailed explanations and documentation of each Report Builder Elements.

Report Hash Variables

  • The API IP/Domain Whitelist setting in General Settings needs to be configured in order for reportLink hash variable to work. If a request is from a non-whitelisted IP/domain, the response will be a HTTP 400 Bad Request.
  • For security purposes, the direct URL parsed from Report Link Hash Variable is dependent on user session (including Anonymous users where the parsed link will differ).
    For example, if user admin obtains the parsed URL and expose it to anonymous users, the link will be invalid.
  • #reportLink.id# - To attach reports in email tool.
  • #reportLink.id[param1=value1&param2=value2]# - To attach reports in email tool with parameters passing.
  • #reportParam.name# - To populate dynamic report parameter values ( for example parameters set in report menu, subreport, etc. ).

Example hash variable:

#reportLink.rp_report1[id=5c3daa8c-b8e7-4e04-8119-e31be53d6232]#



Download Demo App

APP_tutorial_ReportBuilder.jwa



  • No labels