Column settings possibilities (type - autocomplete)

Tags: #<Tag:0x00007f34388cd138>

Hello,

It’s possible to put in the source (column prop, type autocomplete) array, a list of objects?
I saw the behavior with nested data: https://handsontable.com/docs/9.0.0/tutorial-data-sources.html#page-nested, and I try to do something like this:


Rewrite the label format of the displayed options, and map the selected element in a specific field.

Thanks.

Hi @Vadim

columns do not have any option similar to labelFormat. Can you describe what exactly you would like to achieve with the label? I see that you already have type, data, and source so at the first glance the column looks completed.

Hello @aleksandra_budnik,

Basically, I want to connect a handsontable instance to an API.
And for a field, I need to send to the backend an id but in the select, I should display some label.

I know that the labelFormat method doest exists, my question is, if we can manipulate/formatting the data from source.

To display not the objects…but an object field, the name or description…:
08

Thank you.

so it’s more like a key-value dropdown. Here https://jsfiddle.net/handsoncode/f0b41jug/ I have an example that works in most basic cases when you want to show a different value than the one that has to be sent to the server.

1 Like

Nice, that is exactly what I need.
Thank you!