From 41e1bad44d5c6e41718444cb0f8cb07bc74bf704 Mon Sep 17 00:00:00 2001 From: wbuezas Date: Wed, 13 Mar 2024 10:15:32 -0300 Subject: [PATCH] Handle more watchs route changes bugs --- src/pages/Customer/Card/CustomerAddress.vue | 1 + src/pages/Customer/Card/CustomerUnpaid.vue | 1 + src/pages/Customer/Card/CustomerWebPayment.vue | 1 + 3 files changed, 3 insertions(+) diff --git a/src/pages/Customer/Card/CustomerAddress.vue b/src/pages/Customer/Card/CustomerAddress.vue index 1c96adbf5..432ac1b2f 100644 --- a/src/pages/Customer/Card/CustomerAddress.vue +++ b/src/pages/Customer/Card/CustomerAddress.vue @@ -56,6 +56,7 @@ onBeforeMount(() => { watch( () => route.params.id, (newValue) => { + if (!newValue) return; getAddressesData(newValue); getClientData(newValue); } diff --git a/src/pages/Customer/Card/CustomerUnpaid.vue b/src/pages/Customer/Card/CustomerUnpaid.vue index 265780517..513333c72 100644 --- a/src/pages/Customer/Card/CustomerUnpaid.vue +++ b/src/pages/Customer/Card/CustomerUnpaid.vue @@ -38,6 +38,7 @@ onBeforeMount(() => { watch( () => route.params.id, (newValue) => { + if (!newValue) return; getData(newValue); } ); diff --git a/src/pages/Customer/Card/CustomerWebPayment.vue b/src/pages/Customer/Card/CustomerWebPayment.vue index 6fba29499..b1c45aa6c 100644 --- a/src/pages/Customer/Card/CustomerWebPayment.vue +++ b/src/pages/Customer/Card/CustomerWebPayment.vue @@ -98,6 +98,7 @@ onBeforeMount(() => { watch( () => route.params.id, (newValue) => { + if (!newValue) return; getData(newValue); } );