Ui_table formatting and cell input

Starting with the basics of table formatting - just trying to turn off table header in inject function on an existing table:

msg.ui_control = {};
msg.ui_control.tabulator = {
	"headerVisible": false
}
return msg.ui_control;

It doesn't turn off headers when I inject it into the existing table. I did read a post on issues with light vs dark theme - not sure if that was solved yet, but I tried dark theme and still the same issue. Debug on output of function node looks Ok.
image

Any ideas why its not working?

Secondly, I want to add a numeric input cell with a default value inot the table and then send the whole row data into an array after entry. I found some long threads/complicated looking solutions that feature this as part of it, and looked at tabulator docs, but just wonderd if there is a simple example somewhere I missed?

Hi,

try this:

msg.ui_control = {};
msg.ui_control = { tabulator: { headerVisible: false } };
return msg;

Regards

1 Like

Hi - thats worked thx very much! Whilst I've created some nice dashboards and bits of javascript in function nodes, still a lot to learn, especially about formatting...

If anyone has suggestions about how to make a cell editable, or a pointer to a concise solution already documented I'd appreciate that too. Thx.

If you are looking for a way to allow edits to the data inside a table, here is an example of an editable html table using the JSGrid library. It involves a lot more than just editing data cells, but it may give you some helpful ideas.

Apologies if I have misunderstood your request...

Thx Steve - I'll take a look and see if it helps my application.

Just a little note. Ui-table can let you edit cells too. If you like to continue with ui-table

Hi Christian - yes my pref would be to stick with ui_table as I now know how to format them :wink:
I did find various ui-table solutions posts which included cell editing, but the tables were a lot more complex than mine thus extracting just cell editing wasn't that staight forward. If you have a concise example in mind that makes it clear then pls post it. Thx.

Look here ... my ui-table handler could do the job for you ... and many other tasks.

I use it for ALL my tables ... the API is not perfect (who calls an argument "object"?) ... but at least there is a little documentation. If I rework the API I have to rework many flows .... and no time for that.

1 Like

Thx Christian - I'll take a look through and see if I can pick out the bits that will be useful for my tables.

Appreciate you taking time to help out :+1:

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.