Colreorder and table data structure
Colreorder and table data structure
Description of problem: Hi, I am loving datatables, first of all I have a question regarding data structure after drag & drop with Colreorder plugin. On the screen you can see the change in column order when drag & drop is completed but I cannot see the same change being applied to dt structure -> column order is not changed as data source is not changed, I guess? I am using a charting api to visualize data and I want to push changed data order to charting service but I don't know how to get new column order?
This question has an accepted answers - jump to answer
Answers
There are a couple of API calls that should get you going - take a look at
colReorder.order()
andcolReorder.transpose()
. Those two will give you the info you're after,Colin
Colin, thank you for your prompt reply. The transpose option should be exactly what I was looking for.