The select input and the dropdown options are all good. I just need to pass the selected value (which is the ID) to the data detail component which I cannot do. The bindings inside the data detail component are for testing purposes and are not showing any values. I put in there {{inp_position.value}} for testing purposes too, and it is showing in the page correctly.
Hi @Teodor, I already have the query results downloaded and I just need to get the values from that. It is already being used by the input select and being passed down to the dropdown list (options). I need to get a value that is associated to the option that is selected.
Is there any other way I can get it to work without sending another request back to the server just to get those values which I already have? Will Data View help here?
As I explained, you just need to filter a database query by the value of the input.
So, one server action with a query for your input values and another one for the results on the page.
Data View can also be used with client side filtering if your records are no more than about 3k.
I found a workaround/solution within the forum. Thanks to @nshkrsh.
With this, it is possible to pass the ID to the Data Detail. But there is no use for the Data Detail any longer for I can now get the "name" of the selection. I haven't tried using it with the Data Detail yet though.
The point of using this is so I don't need to send another request back to the server to get the information which is already on the page.
Take note that dmx-on:updated gets the latest value. The dmx-on:change seems to be always getting only the last value and not the new one (upon selecting). This means onchange is one value behind onupdated.
Thanks also to @Teodor for the solution. It is much easier with his solution and send back a GET request for the value required.
The one from @nshkrsh is a workaround. But it satisfies my requirement to not to send back anything to the server.