From 835ad28709eda562cb0f9407e5ff052e827e3ac0 Mon Sep 17 00:00:00 2001 From: cagataycivici Date: Fri, 3 Jul 2020 14:38:39 +0300 Subject: [PATCH] Fixed #356 - DataView should reset paginator on sort --- src/components/dataview/DataView.vue | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/components/dataview/DataView.vue b/src/components/dataview/DataView.vue index 943d6de7c..36941c2ee 100755 --- a/src/components/dataview/DataView.vue +++ b/src/components/dataview/DataView.vue @@ -114,6 +114,12 @@ export default { }, rows(newValue) { this.d_rows = newValue; + }, + sortField(newValue) { + this.resetPage(); + }, + sortOrder(newValue) { + this.resetPage(); } }, methods: { @@ -153,6 +159,10 @@ export default { else { return null; } + }, + resetPage() { + this.d_first = 0; + this.$emit('update:first', this.d_first); } }, computed: {