ericrsmith35 / DatatableV2

28 stars 24 forks source link

When using Apex-Defiend Object, it is only return back the first option #29

Closed wilsonwong13 closed 4 years ago

wilsonwong13 commented 4 years ago

Currently following this guide - https://ericsplayground.wordpress.com/how-to-use-an-apex-defined-object-with-my-datatable-flow-component/

When I select any choice, it is currently only returning the first option as outputselectedrows.

wilsonwong13 commented 4 years ago

I figure out the issue. The way the code works is that it will look at the Id field between the selected row and the datatable. Just add an Id Field and have that as unique characters for each data

pyao-bwc commented 4 years ago

Hi @wilsonwong13 , thanks for figuring this out, it saved me a lot of time!

In case others run into it, I found that the Key Field is case sensitive. So my field is defined in my Apex type as this:

    public Id id;

And it wouldn't work if this configuration was Id, it has to be like this (and has to be set): image