Skip to main content

Hello,

I am looking for some guidance on how to implement a view which is based on the API results of another internal application.

To give you some context, we have a Document Management System (DMS) which offers an API layer. Based on a selected record in Universal, a query parameter is filled and the corresponsing documents are returned in the response. I want to show these filenames in a grid as a detail of the selected record.

I tried the following:

  1. In a tree menu, add a task instead of a table/view
  2. This task is a start task of a process flow:
    1. Calls the API endpoint and writes the result in a table
    2. Opens a document (a view which is based on the most recent call to the endpoint)

This method works for my basic example, with a slightly longer loading time than a normal view (because of the API call).

However, we would like to implement this solution in the menu where it belongs. This menu has the following structure:

Menu structure​​​​​

In Tab 1, a record is selected. Tab 2 is a detail of this. 1 Of the subtabs should be the view which lists all of the files. As far as I know, I cannot implement my basic example in this menu structure, because I cannot activate a task when clicking the subtab in this menu. I don’t think a background system flow which syncs the files to the database is a nice solutions for this usecase, but I do not think I have an alternative solution?

 

All suggestions are welcome, thanks in advance!

@NickJanssen assuming the Subtab is a Detail tab (of Tab 2) I would assume you can invoke a Process Flow with Activate Detail that then triggers the Task to fill the Table/View data and refreshes the Detail tab afterwards. Would that work or is something off with my assumption?

https://docs.thinkwisesoftware.com/docs/sf/process_flows_actions#activate-detail


Hi ​@Arie V ,

This indeed works for triggering the API call when clicking the detail tab, so thanks for this!

Unfortunately, I stumbled on another problem. I need the reference value of the parent tab for the API call (in the query parameters) to filter the results. I can see that the process flow action “Activate detail” has some output columns which correspond to the columns of the detail tab. Unfortunately, I do not have any values here which I can use in the API call.

The only solution I can think of at the moment is to call the API endpoint to get all the results (without filtering the results by means of the query parameter). By means of the detail from Tab 1 to this subtab, only the relevant records are shown in the view. However, as the result set behind this API endpoint will grow quickly, this solution will not work for us …

Any help for this problem is appreciated!


Reply