From 36610480e94f293c3378dcba958d53a9ac754446 Mon Sep 17 00:00:00 2001 From: pushuo Date: Fri, 23 Sep 2022 17:48:23 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=9C=B0=E5=9D=80=E7=BC=96?= =?UTF-8?q?=E8=BE=91=E5=88=87=E6=8D=A2=E5=9B=BD=E5=AE=B6=E4=B9=8B=E5=90=8E?= =?UTF-8?q?=20=E7=9C=81=E4=BB=BDid=E6=B2=A1=E6=9C=89=E6=B8=85=E7=A9=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- themes/default/account/address.blade.php | 4 ++++ themes/default/checkout.blade.php | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/themes/default/account/address.blade.php b/themes/default/account/address.blade.php index 24ac995c..d3e8172d 100644 --- a/themes/default/account/address.blade.php +++ b/themes/default/account/address.blade.php @@ -201,6 +201,10 @@ hload: true }).then((res) => { this.source.zones = res.data.zones; + + if (!res.data.zones.some(e => e.id == this.form.zone_id)) { + this.form.zone_id = ''; + } }) }, } diff --git a/themes/default/checkout.blade.php b/themes/default/checkout.blade.php index fa4bd4ea..a1ddfea1 100644 --- a/themes/default/checkout.blade.php +++ b/themes/default/checkout.blade.php @@ -350,6 +350,10 @@ $http.get(`/countries/${e}/zones`).then((res) => { this.source.zones = res.data.zones; + + if (!res.data.zones.some(e => e.id == this.dialogAddress.form.zone_id)) { + this.dialogAddress.form.zone_id = ''; + } }) },