Textfield Autocomplete

Actions & Logic

I need a little help as chatgpt couldn't answer my question.

I'm using a textfield autocomplete that is mapped to a a supabase query filtered by an onchange event (ie when you type in the field it filters the query).

When a user selects the autocomplete option (which displays the name field of the record) I'd like to add the Id of that record to a list.

How do I capture the Id field of that selection? I've only been able to map the name (which is not unique for these records).

The high level concept for this is that I want a text box someone can type in, see their selection and either press enter or click the button to the right to add it to a list (page state)

What have you tried so far?

I've tried queries onChange (which is preference) then filtering by action output map to name.

I've tried a Supabase query on the parent container, but that doesn't seem to work.

Did you check FlutterFlow's Documentation for this topic?
Yes
2
2 replies