How to design a customized form using the workflow UI form designer for an MDM workflow task (deprecated)
Basic concepts and working principles of a human task in a workflow
- Once a workflow is initiated, the pool variable mdm_context is populated, which must be included in each task in the workflow. If needed, you can add Pool variables and/or Local variables in a task to transfer data from Talend MDM to the form designer. In addition, there must be a Contract that defines the information a task requires to execute.
- An MDM REST API extension is configured automatically when the MDM workflow is
deployed to the MDM server, which can be used to fetch data from Talend MDM directly and conveniently. For more
information, check the REST API extensions listed under the Resources tab after logging into the Bonita BPM web portal as a Bonita
administrator.
For further information, see the Talend Studio User Guide.
- Correspondingly, in the workflow UI form designer, variables must be defined, which will be used to store data fetched from Talend MDM or user inputs, process the data if needed, and finally send the data back to Talend MDM through the contract variables.
- When a user of the form submits, the Operations (actions) defined in the workflow will be executed, so that values entered or modified by the user or other aggregated data are submitted to Talend MDM to fulfill the Contract.
An example of how to design a customized form for a workflow task using the workflow UI form designer
Based on the MDM demo project in Talend Studio, this scenario aims to create a customized Web form for non-technical users responsible for product pricing. With the fit-for-purpose form, the non-technical users can post a price modification request without having to access the complete Talend MDM Web UI.
In this scenario, a web form contains one title New Price Request and four fields Product Name, Enter Product Price, Request Reason and Request Date will be designed. In the form, the original values of product name and product price are fetched from Talend MDM through the REST API extension. Authorized users (price requester) can then enter a new price for the product, enter the new price request reason, and select the new price request date before finally submitting the new price request.
- The MDM server is up and running.
- The Bonita BPM bundles have been installed in Talend Studio.
- The Bonita BPM server is up and running.
- You have been assigned roles with the appropriate user authorization and access rights.
- The information about MDM users has been synchronized to the Bonita BPM server.
Defining contract variables and operations in Talend MDM
Designing a customized form for a workflow task
Creating a form
Editing the form to fetch data from Talend MDM
Editing the form to receive data directly from user inputs
Procedure
- Name the other two widgets to be Request Reason and Request Date respectively.
- Click Create a new variable to open a new page and define a new variable in the form designer to receive data from user inputs.
- Enter requestReason in the Name field.
- Select String from the Type list.
- Click Save to save your changes.
- On the right panel, in the Value field of the Request Reason INPUT, enter requestReason.value.
- Remove the original Request Date INPUT, then drag a new DATE PICKER widget and drop it in the central design area.
- Follow the similar procedure to create a new variable requestDate of String type, and edit the Value field for the Request Date DATE PICKER to be requestDate.value.