How to track changes on jqGrid columns/layout/order?
I have a jqGrid that can be开发者_运维知识库 sorted by different columns both in ascending and descending order. Columns may be added or removed, and the order of the columns may be changed too. I need to detect when any of these properties have changed, in order to save the users preference.
Is there a way to catch these events? I've been looking at the problem for a few days but cant seem to find a way to do it without a "Save" button.. but I dont really like that solution..
Thanks!
You can use the onSortCol
event to detect if columns have been re-sorted.
Regarding adding/removing columns, event on selecting columns in jqGrid may be a good place to start.
精彩评论