Display data from sub-table in Table

Hello Wapplers,

I’m quite confused with some basic task.
I have API output which contains some sub-table output:

{
"query": [
{
"departure_id": 1,
"departure_date": "08.09.2022",
"prices": [
{
"price_id": 556,
"price_amount": 22,
"price_date": "2022-09-16T00:00:00.000Z",
"price_depended_departure_id": 1
},
{
"price_id": 1,
"price_amount": 22,
"price_date": "2022-09-15T00:00:00.000Z",
"price_depended_departure_id": 1
},
{
"price_id": 555,
"price_amount": 44,
"price_date": "2022-09-07T00:00:00.000Z",
"price_depended_departure_id": 1
}
]
},
{
"departure_id": 2,
"departure_date": "11.09.2022",
"prices": [
{
"price_id": 2,
"price_amount": 99,
"price_date": "2022-09-07T00:00:00.000Z",
"price_depended_departure_id": 2
}
]
}
]
}

On the page I’m creating Table via BS5 Table generator and setting parametr for the query like this:

When table is displayed in prices columns it displays: [object Object],[object Object],[object Object]
From Data Binding I’m trying to display specific value, but the select Windows just keeps showing: Loading

I even tried to enter code manually: prices.values('price_amount') but this won’t work either.

So is it I’m doing something wrong or this is a bug?

P.S.
In addition to that I need to display in the table minimum value of 'price_amount'

You need to add a repeat area for Prices. Here I have an example where I have Categories and Items instead of Departure_dates and Prices.

1 Like

Thank you @ben

1 Like