cancel
Showing results for 
Search instead for 
Did you mean: 

SAP Build Apps - How to do Data Refresh for Marketplace installed component?

Sathees_P
Participant
0 Kudos

One of SAP Build App's page development, using marketplace installed component "Basic list with selection on right" and bound to SAP standard OData service /API_PRODUCT_SRV/A_Product. How to do based on search condition or button click to refresh data shown in the list? List bound directly to data source via Data Adapter instead of data variable. Unable to reload data in the list and tried with list component's template editor, added 'Fired from "Trigger event"' and connected to the "Data | Get record collection" in component's internal flow logic. But this event neither visible outside of component in a page nor other components in a page to consume.

Sathees_P_0-1710774119871.png   

SAP Build 

View Entire Topic
Dan_Wroblewski
Developer Advocate
Developer Advocate

Why not in the component editor create a new property called "Refresh" that is true/false and anytime you want to refresh the data you change its value (making it the opposite). Then hook up that property's change event to the existing logic for updating the data.

Dan_Wroblewski_0-1714017622763.png

Instead of having a visual UI that you click, you can as part of your logic flow simply update the bound variable to that property.

You could make it slightly more elegant by resetting the refresh to false within the above logic and then if you want to refresh you set the property to true each time, though this might lead to double refresh each time. To solve that you could check the variable in the logic.

Here I have Northwind's product entity bound to the Basic List with Selection on Right control, to which I added a true/false property called Refresh. I have an app variable of text that is bound to the filter, as well as to the input box. When I change the text, I can then click the Refresh checkbox to refresh he data retrieval.

 2024-04-25_07-04-15.gif

Sathees_P
Participant
0 Kudos
This idea worked out for me Basic List with selection and Basic table 🙂