diff --git a/src/components/VnTable/VnTable.vue b/src/components/VnTable/VnTable.vue index a3c439cc7..3e982919b 100644 --- a/src/components/VnTable/VnTable.vue +++ b/src/components/VnTable/VnTable.vue @@ -69,10 +69,7 @@ const $props = defineProps({ type: Boolean, default: false, }, - disableInfiniteScroll: { - type: Boolean, - default: false, - }, + hasSubToolbar: { type: Boolean, default: null, @@ -373,9 +370,7 @@ function handleOnDataSaved(_) { ref="CrudModelRef" @on-fetch="(...args) => emit('onFetch', ...args)" :search-url="searchUrl" - :disable-infinite-scroll=" - $attrs['disableInfiniteScroll'] ? isTableMode : !disableInfiniteScroll - " + :disable-infinite-scroll="isTableMode" @save-changes="reload" :has-sub-toolbar="$props.hasSubToolbar ?? isEditable" :auto-load="hasParams || $attrs['auto-load']" @@ -395,7 +390,7 @@ function handleOnDataSaved(_) { card-container-class="grid-three" flat :style="isTableMode && `max-height: ${tableHeight}`" - :virtual-scroll="!isTableMode" + :virtual-scroll="isTableMode" @virtual-scroll=" (event) => event.index > rows.length - 2 && diff --git a/src/pages/Customer/components/CustomerSummaryTable.vue b/src/pages/Customer/components/CustomerSummaryTable.vue index 374769a57..946296e67 100644 --- a/src/pages/Customer/components/CustomerSummaryTable.vue +++ b/src/pages/Customer/components/CustomerSummaryTable.vue @@ -35,6 +35,7 @@ const filter = { ], where: { clientFk: route.params.id }, order: ['shipped DESC', 'id'], + limit: 30, }; const columns = computed(() => [ @@ -149,7 +150,6 @@ const setShippedColor = (date) => { auto-load order="shipped DESC, id" :disable-option="{ card: true, table: true }" - limit="5" class="full-width" :disable-infinite-scroll="true" >