From 9b5b01088fe60b75ebde56bceb7ebf9034b3abf3 Mon Sep 17 00:00:00 2001 From: John Cardinal Date: Wed, 29 Jan 2020 19:33:42 +0000 Subject: [PATCH] --- ayanova/src/components/gz-data-table.vue | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/ayanova/src/components/gz-data-table.vue b/ayanova/src/components/gz-data-table.vue index f84c528b..6626f460 100644 --- a/ayanova/src/components/gz-data-table.vue +++ b/ayanova/src/components/gz-data-table.vue @@ -105,16 +105,11 @@ export default { Limit: 100, Offset: 0 }; - //fixup paging based on settings + //calculate paging based on settings const { page, itemsPerPage } = that.options; - if ( - this.localFormSettings.pagination.itemsPerPage && - this.localFormSettings.pagination.itemsPerPage > 0 - ) { - listOptions.offset = - (this.localFormSettings.pagination.page - 1) * - this.localFormSettings.pagination.itemsPerPage; - listOptions.limit = this.localFormSettings.pagination.itemsPerPage; + if (itemsPerPage && itemsPerPage > 0) { + listOptions.Offset = (page - 1) * itemsPerPage; + listOptions.Limit = itemsPerPage; } //is there a filter?