Font Size:

Merge PDF Datalist Action

Introduction

The Merge PDF Datalist Action plugin is designed to merge all uploaded PDFs in a file upload form element when the user clicks on the Merge button in a datalist.

Plugin information

  • Plugin Name: Merge PDF Datalist Action
  • Joget DX Compatibility: Joget DX 8

Get started

Where to get the plugin

You can download the latest release of the plugin from GitHub.

How to install

  1. Download the plugin JAR file from the releases page.
  2. Go to Settings > Manage Plugins > Upload Plugin.
  3. You can import the demo app or create the app from scratch.

How to use it

Importing the demo app
  1. Download the demo app (.jwa file) from GitHub.
  2. In Joget, go to Home or All Apps and click Import App to upload the .jwa file.
Creating an app from scratch
  1. Create a form with a File Upload field for uploading PDF files.
  2. Click Generate App > Generate CRUD.
  3. Go to the List Builder and drag the Merge PDF Datalist Action plugin into the datalist.
  4. Drag it to the column for individual record row downloads or to the bottom for downloads based on selected records. 
    See Merge PDF Datalist Action Properties for plugin configurations.
  5. Publish and run the UI. 
  6. Go to the CRUD and click New
  7. Add a new record and upload multiple PDF files.
  8. Add another record to showcase downloading the zip file of all PDFs when all records are selected.
  9. Click the Merge PDF button for the record1.

     The two PDFs on the left are the original PDFs, and the PDF on the right is the merged PDF that has just been downloaded.

  10. Click Download the merged PDF in Zip, which will download all the merged PDFs in each record as a zip file.
  11. The ZIP file will download. Extract the file to retrieve all merged PDFs.

Configure the merge PDF datalist action properties

Fields to configure:

  • Label: Datalist button label.
  • Form: Select the form containing the file upload field. Mandatory field.
  • Field: The file upload field where the PDF is uploaded. Mandatory field.
  • Record Id Column: Defaults to the primary key of the configured binder if not set.
  • Confirmation Message: Confirmation message before performing the action (e.g., "Are you sure?").
  • File Name: If not set, the default file name will be based on the record ID.
  • Zip File Name: The file name of the zip file. If not set, the default name will be the button label.

Configure Merge PDF Tool Plugin

Steps for configuring Merge PDF Tool

  1. Create a form with two file upload fields to upload PDF file.

You may upload multiple PDF files into a single File Upload field. In that case, make sure to enable the Enable Multiple file uploads option under the UI section in Advanced Options.

  1. Add one more File Upload field. This field will be used to store the merged PDF generated.
  2. Configure Post Form Submission Processing.  Navigate to Settings >  Advanced > Post Form Submission Processing, and select Merge PDF Tool as the post-processing tool.
  3. Configure the property fields for the Merge PDF Tool.
  4. Save the configuration and click Generate App. Check Generate CRUD for the form and click Generate.

Steps to run the Tool plugin

  1. At runtime, go to Manage Merge PDF Tool Form and click New. Upload PDF files into the File Upload fields and save the form.
  2. After submission, click Edit on the record to open the form and download the merged PDF file stored in the Merged PDF field.

Configure PDF Merge Tool properties

Fields to configure:

Source File: Header Field.

  • Choose Form (Source File): Select the form containing the PDF files you want to merge.
  • Choose Fields (Source File): Select one or more File Upload fields that store the PDF files to be merged.
  • Use the ➕ button in the grid to add multiple fields.

Output File: Header Field.

  • Choose Form (Output File): Select the form where the merged PDF file will be stored.
  • Choose Field (Output File): Select the target File Upload field where the merged PDF will be stored.
  • Rename File: Set the name for the merged PDF file. Use plain text for a fixed name, {fieldid} to insert values from form fields, or a Hash Variable. 
    For multiple files, use the first file's name or set a custom name in the configuration.

Expected outcome

After completing the configuration, you can merge PDFs directly from the datalist and download them individually or as a zip file.

Download plugin

Download sample app

Download the demo app for Merge PDF Datalist Action:
Created by Julieth Last modified by Debanraj on Jul 10, 2025