Enhancing Custom Application as Workflow Task UI in Cloud Foundry
A task UI in a workflow could be a Form or SAPUI5 component. For latter, you have two choices:
note: only SAPUI5 based applications, deployed in the cloud platform are supported for Task UI.
If you do want to build the UI from scratch instead want to reuse any existing SAPUI5 application, then you can do so with slight adjustments in the Component.js and View.xml files. These adjustments are mandatory to upgrade your UI to have task properties like task-name, task-subject, task-priority etc.
Step 1: Update xs-app.json file
Add the route in xs-app-json of your custom application. This router is needed as you will be calling workflow APIs. Read Step 3 of the documentation to know more.
Step 2: Update Component.js file
Let us see code-snippets you need to add in Component.js. For this I have an empty Component.js as seen in screenshot below.
In few simple steps, you can bring your own UI to reuse it as Task UI. If you want to build the Task UI from scratch then you have to completely design your component.js and view.xml files.
For your reference I have uploaded the sample code in GitHub that you can use for your reference while building your own application.
In the final chapter of the series, I will show you how to call external APIs in Task UI.
- starting workflow from custom task UI
- how to add start workflow custom UI as a tile in Portal Fiori Launchpad
- calling external API from custom task UI