From 21f1e66d611b96206c43c524f26d2a2f7a288bb0 Mon Sep 17 00:00:00 2001 From: duanliangtao Date: Tue, 26 Sep 2023 09:41:38 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E8=A1=97=E9=81=93?= =?UTF-8?q?=E7=BA=A7=E5=88=AB=E7=9A=84=E7=94=A8=E6=88=B7=E6=97=A0=E6=B3=95?= =?UTF-8?q?=E9=80=9A=E8=BF=87=E7=BD=91=E6=A0=BC=E6=9F=A5=E6=89=BE=E5=88=B0?= =?UTF-8?q?=E5=AF=B9=E5=BA=94=E6=88=BF=E5=B1=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/components/resiSearch.vue | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/views/components/resiSearch.vue b/src/views/components/resiSearch.vue index 71f20f306..4208c951a 100644 --- a/src/views/components/resiSearch.vue +++ b/src/views/components/resiSearch.vue @@ -833,10 +833,13 @@ export default { } else { agencyIdTemp = this.form.agencyId[this.form.agencyId.length - 1] } + const lastIndex = this.form.agencyId.length - 1; + const gridIdQuery = this.form.agencyId[lastIndex - 1]; + const agencyIdQuery = this.form.agencyId[lastIndex]; this.$http .post('/actual/base/communityQuarters/listQuartersOptions', { - gridId: this.form.agencyId[1], - agencyId: this.form.agencyId[0], + gridId: gridIdQuery, + agencyId: agencyIdQuery, // agencyId: user.agencyId }) .then(({ data: res }) => { From 8bf1269a4c11eebfd6ba76368b677914cb10ec9b Mon Sep 17 00:00:00 2001 From: duanliangtao Date: Tue, 26 Sep 2023 09:46:02 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E8=A1=97=E9=81=93?= =?UTF-8?q?=E7=BA=A7=E5=88=AB=E7=9A=84=E7=94=A8=E6=88=B7=E6=97=A0=E6=B3=95?= =?UTF-8?q?=E9=80=9A=E8=BF=87=E7=BD=91=E6=A0=BC=E6=9F=A5=E6=89=BE=E5=88=B0?= =?UTF-8?q?=E5=AF=B9=E5=BA=94=E6=88=BF=E5=B1=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/components/resiSearch.vue | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/src/views/components/resiSearch.vue b/src/views/components/resiSearch.vue index 4208c951a..c8b6b9a07 100644 --- a/src/views/components/resiSearch.vue +++ b/src/views/components/resiSearch.vue @@ -833,9 +833,14 @@ export default { } else { agencyIdTemp = this.form.agencyId[this.form.agencyId.length - 1] } - const lastIndex = this.form.agencyId.length - 1; - const gridIdQuery = this.form.agencyId[lastIndex - 1]; - const agencyIdQuery = this.form.agencyId[lastIndex]; + const gridIdQuery = ''; + const agencyIdQuery = this.form.agencyId[0]; + if (this.form.agencyId.length >= 2) { + lastIndex = this.form.agencyId.length - 1; + agencyIdQuery= this.form.agencyId[lastIndex - 1]; + gridIdQuery = this.form.agencyId[lastIndex]; + } + this.$http .post('/actual/base/communityQuarters/listQuartersOptions', { gridId: gridIdQuery,