Can we set edtiable by dynamic-column-settings

as description in Working with tables
we can do some dynamic-column-settings, but there is not editable option in that.
have any solutions?

Hey @AnsonHwang!

This is something we're looking into including and we'll let you know here if/when we do!

As for workarounds, there aren't any great ones that come to mind... You may be able to use something like a listview to dynamically generate input fields based on the columns you'd like to edit then have your update query reference those fields instead:

What do you think?

Thanks for your reply. I think the editable option is important. Because I use module, there is different fields in different app.
I show a complex relationship data(neo4j/graphql) in table component. So I need an flexible dynamic config.
The listView can't fit my case, thanks any way.

I believe this functionality can be achieved with dynamic column settings using the restrictedEditingMapper property. Setting this to "true" should disable edit. If all columns are set to be editable on the table component this may have the desired effect.

Unfortunately, this does not enable cell modifications ^

Hey @ericcheong! You should actually be able to set it to false to enable editing.

You can even dynamically enable/disable this setting with something like: => {
  return {
    name: c,
    restrictedEditingMapper: false

This is currently what im doing, stateful_cols_render_validate comes from another input selection where users can choose to display what existing column to display

But its still not editable :frowning: any recommendation?

Oh darn. Let me play around with this some some more to see how we can get this to work

After doing some digging, I believe this property is supposed to make an editable column non-editable when set to true.

Ideally, it also makes a column editable when set to false.

However, the only thing this property seems to do is make a manually-set editable column (manually set with the Editable checkbox) no longer editable when set to {{true}} or "\{\{true\}\}". Setting it to true doesn't work.

I filed this as a bug internally! In the meantime, it seems your best bet is to set all columns to editable and use something like the logic I sent in the screenshot above.

1 Like

Thank you