Hi Cyril,
Greetings from Syncfusion support.
Query : Disable persisted state for grid's filtering and
sorting functionality
From your query, we understand that you want to prevent
persisted state for column filtering and sorting. We prepared a sample to
remove the filterSettings and sortSettings from the persistence in the addOnPersist
method using dataBound event. Please refer the below code, documentation
and sample for more information
[App.vue]
dataBound:
function (args) {
var cloned =
this.$refs.grid.ej2Instances.addOnPersist;
this.$refs.grid.ej2Instances.addOnPersist = function (key) {
key =
key.filter(
(item) => item !== "filterSettings" && item !== "sortSettings"
);
return
cloned.call(this, key);
};
},
|
Sample : https://codesandbox.io/s/vue-template-forked-wedu9q?file=/src/App.vue
Documentation : https://ej2.syncfusion.com/vue/documentation/grid/state-persistence/prevent-to-persist/
https://ej2.syncfusion.com/vue/documentation/api/grid/#databound
Regards,
Vinitha Balasubramanian