Breadcrumbs resit pres funkce

This commit is contained in:
Michal Kváček
2024-03-13 06:35:26 +01:00
parent 5cff3580b0
commit 48f57cde0d
28 changed files with 152 additions and 172 deletions
+3 -7
View File
@@ -11,13 +11,9 @@ import {onMounted} from "vue";
useAppStore().setPageTitle("Moje lety");
const {loadPage, paginationLimit} = usePagination();
const loadNextPage = (appendItems) => loadPage({
fetchFunc: useFlightsStore().fetch, appendItems
});
const {loadPage, paginationLimit} = usePagination({fetchFunction: useFlightsStore().fetch});
onMounted(() => {
loadNextPage(false);
loadPage(false);
});
const {flights, totalItemsCount, isQueryRunning} = storeToRefs(useFlightsStore());
</script>
@@ -40,7 +36,7 @@ const {flights, totalItemsCount, isQueryRunning} = storeToRefs(useFlightsStore()
:is-query-running="isQueryRunning"
:items-per-page="paginationLimit"
:total-items-count="totalItemsCount"
@load-more="loadNextPage(true)"
@load-more="loadPage(true)"
/>
<FAB mode="add" :router-link="{name: 'addFlight'}"/>