That was the first thing I tried. However what I’m finding is that, when I am dynamically loading different tables with different columns, the manualMoveColumn array cache does not get reset between them.
For example. I load table A. I move column 4 to column 3. It does persist and works.
Now, I click to load table B…however in this table Column 4 has been moved to Column 3 as well. Basically, any table I load thereafter has this column moved.
I have tried extensively to research the API and other ways I can “Reset” the column cache when I load a new table…but have not been able to.If there is a way, I would much prefer to use this PersistState method.
My work around is that I use the action/movement of the column change to get the column data, but then I update column order in my DB…and block the actual internal action of move column by return false on the beforeColumnMove hook.
This works…but again, if I’m missing something, let me know.