From f4ddc7001beec3014cd9ee7a252ed62ea60d4741 Mon Sep 17 00:00:00 2001 From: Javier Segarra Date: Mon, 26 Feb 2024 10:38:03 +0100 Subject: [PATCH] refs #6722 perf: not fetch when id not exists --- src/components/ui/VnPaginate.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/ui/VnPaginate.vue b/src/components/ui/VnPaginate.vue index 2e3927871..509498eb9 100644 --- a/src/components/ui/VnPaginate.vue +++ b/src/components/ui/VnPaginate.vue @@ -96,7 +96,7 @@ watch( store.data = null; if (!arrayData.store?.filter?.where) { //Cuando el cambio viene por VnSearchbar - store.url = store.url.replace(/(\d+)/, route.params.id); + if (route.params.id) store.url = store.url.replace(/(\d+)/, route.params.id); } else { // Cuando el usuario cambia en la URL const claveFk = Object.keys(arrayData.store.filter.where).find((clave) =>