I've found this How to use run a query on an expanded row - #8 by Tess but seems it has workarounds to use non-table data in the expanded rows.. but I'm looking for what I think is a normal/simple use case I can't seem to nail down.
Basic ask is:
Table populated w/ a query on the orders
table that returns the order data, from a query like select order_id, order_date from orders
etc
Enable Expandable Rows for this table, and on each order
row, click to expand and see the products and quantity ordered - which comes from DB like select product_id, quantity from order_detail where order_id = 1234
I really need the expanded rows functionality in the use case, versus a solution that would show the order details in another component on the side of the order list, for example.
I tried a few options, and what I really want is to be able to have a query fire where my where clause can be something like:
select * from order_detail where order_id = {{ ordersTable.currentRow.data.order_id }}