Issues with Custom list component rendering data from External collections

Hi there, I’ve a problem showing data fetched via External collections.

I’ve 2 External Collections, Orders and LineItem. When fetching the data from the external API, I’m able to render a list of differents Order objects, showing for each the current order_id. The problem is that when I do the same for the LineItem object, I just see the last LineItem element of my returned json array a number of times that is equal to the length of the array.

This is the json returned for the LineItem collection (the one not working - the other one is the same but its rendered properly)

{
    "lineItems": [
        {
            "ordine_id": 300,
            "isAvailable": true,
            "qty": 100,
            "productName": "Pizza Bianca",
            "productPrice": 3
        },
        {
            "ordine_id": 300,
            "isAvailable": true,
            "qty": 100,
            "productName": "Pizza Rossa",
            "productPrice": 4
        },
        {
            "ordine_id": 300,
            "isAvailable": true,
            "qty": 100,
            "productName": "Pizza Gialla",
            "productPrice": 5
        }
    ]
}

Any help ?

I’ve also noticed that REST calls are made even if there is no component in the app related to the external collection. In my case, trying to figuring out what may cause the mentioned behavior, I’ve removed all List component that were related to the LineItem collection, but GET calls at related url were still going on .

Anyone knows something about this?

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.