Skip to Content

Cloud Foundry - My Inbox - Cannot create component for smart template rendering

Hello Experts,

In Cloud Foundry using business application studio I am creating a Custom UI5 application to trigger the workflow. I am referring the following blogs-

https://blogs.sap.com/2020/08/27/starting-workflow-from-custom-fiori-application-in-cloud-foundry/

https://blogs.sap.com/2020/08/31/enhancing-custom-application-as-workflow-task-ui-in-cloud-foundry/

https://blogs.sap.com/2020/09/10/create-workflow-mtar-application-with-custom-ui-using-business-app-studio/

I have created 2 applications -
App1) Workflow

App2) Custom UI5 app using which I am able to successfully trigger the workflow from UI5 app and I can see that item in My Inbox as well. PFB-

However, once the item is selected in My Inbox it is throwing the following error:

PFB code from my custom UI5 application:
1) xs-security.json

2) xs-app.json

3) mta.yaml

4) Service Instances in Cloud Foundry

I am not sure why My Inbox is unable to load the component of the custom ui5 application, which as a standalone app is working fine.

The url which My Inbox is trying-https://xxxxxxxtrial.cockpit.workflowmanagement.cfapps.eu10.hana.ondemand.com/nsPOCCreateInvoice/Component-preload.js

Standalone app url-
https://xxxxxxxtrial-dev-myapp-cap-createinvoice-approuter.cfapps.eu10.hana.ondemand.com/nsPOCCreateInvoice/Component-preload.js

Can you please help.

Thanks & Regards,
Shubham

ftcp3.png (70.5 kB)
gvalu.png (23.1 kB)
zefcu.png (39.1 kB)
82lh6.png (66.2 kB)
tlnbo.png (93.5 kB)
zgyyt.png (57.7 kB)
48bhw.png (67.7 kB)
Add a comment
10|10000 characters needed characters exceeded

Related questions

2 Answers

  • Best Answer
    Posted on Oct 19, 2020 at 06:56 AM

    Hello Shubham,

    This is due to the existing restriction with Workflow Management SaaS application. You cannot view the user tasks based on SAPUI5 component from My Inbox application hosted in Workflow Management (see the restrictions here). For now only Forms are supported.

    For that you have to use create the Launchpad module and add the My Inbox tile in it. You can download the content for Workflow Management FLP from here, just build and deploy it. Then you can use My Inbox and it will show the tasks.

    Add a comment
    10|10000 characters needed characters exceeded

    • Hello Archana,

      Thank you for providing the clarification.

      I tried another way of integrating the UI5 application in My Inbox, this way I was able to load the UI5 app but as soon as I add any route in xs-app.json file, I face the same issue again.

      PFB the steps-

      Step1) Create a UI5 project using wizard
      (don't add authentication, hence no xs-security.json file will be created)
      (add a service, but then remove it from xs-app.json file)

      Step2) Create a Workflow and add the UI5 project

      Step3) Notice the My Inbox is now able to load the UI5 application

      Step4) Now as soon as I add any route to xs-app.json file, I get the same issue again, ie, My Inbox is unable to load the UI5 app

      "routes": [
          {
            "source": "^/bpmworkflowruntime/(.*)$",
            "target": "/$1",
            "service": "com.sap.bpm.workflow",
            "endpoint": "workflow_rest_url",
            "authenticationType": "xsuaa"
          },
          {
            "authenticationType": "none",
            "csrfProtection": false,
            "source": "^/sap/opu/odata/iwbep/GWSAMPLE_BASIC/",
            "destination": "ES5"
          },
          {
            "source": "^(.*)$",
            "target": "$1",
            "service": "html5-apps-repo-rt",
            "authenticationType": "xsuaa"
          }
      ]

      Can you please help.

      Thanks & Regards,
      Shubham

      step1.png (158.2 kB)
  • Posted on Oct 14, 2020 at 07:46 AM

    Hello Shubham Dehariya,

    this xs-app.json are from approuter or from that html5 module.

    I can see, that you are probably using standard portal site from workflow management and therefore you are effectively bypassing your app router.

    If that xs-app.json is defined on approuter level, then you are bypassing it also.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.