Applies to version: 2020.1.x and above; author: Konrad Wojtycza
The following article describes an example of using the barcode functionality in a business scenario. The main features of using barcodes in WEBCON BPS are:
- Relating a PDF document with an existing workflow instance which allows you to automatically attach the received document to the workflow instance, after recognizing a barcode on the document received via e-mail or scanning.
- Automatically starting a workflow, after recognizing a barcode on the attachment added to the HotFolder.
An example where you can use the a) mechanism can be the contract conclusion process. Processing contracts prepared by the contractor in WEBCON BPS may require printing a PDF file and manually signing the document. The signed contract should be added to the same workflow instance.
In this situation, the automatic attachment of a scan of the signed contract is possible by adding the barcode on the contract received from the contractor. The service recognizes the contract with the barcode located in the HotFolder and attaches them to the appropriate workflow instance based on this barcode.
Configuration of the “Add a barcode” action
After adding the contract received from the contractor to the workflow instance, add the barcode to the received PDF document.
Fig. 1. A workflow instance containing the contract from the client
Adding the barcode it is a standard action available in WEBCON BPS Designer Studio. The following screenshot presents this configuration:
Fig. 2. The configuration of the “Add a barcode” action
- Document corner – a place to add the barcode
- Barcode type – standard, code 2D, standard and code 2D
- Instance ID, instance number and registration date
- Custom text – to be entered when this option is selected
By unchecking the “Search all attachments” field, in the “Attachment name template” field you can define to which attachments the barcodes should be added. The name template should be defined by using a regular expression e.g. an expression that selects the documents with a name beginning with the “Contract” or “contract” phrase.
The “Archive file before adding barcode” option allows you to archive the file without adding the barcode. In this situation, after adding the barcode in the attachment table (WFDataAttachments) an additional row will be added.
After going through the “Add a barcode” path, on the PDF document a barcode will appear in the defined corner.
Fig. 3. Added barcode
After signing and scanning the contract, the document stored in HotFolder will be processed and added to the workflow instance (based on the recognized barcode) in which was downloaded.
Fig. 4. The attachment containing the signed contract added to the workflow instance
The “Signed_” part was added to the scanned document by using the “Attachment name of created template” field in the HotFolder configuration.