From 41669abfe39cf03eab8eaf47ab2d52fcee10b8d8 Mon Sep 17 00:00:00 2001 From: weipengfei <2187978347@qq.com> Date: Fri, 23 Feb 2024 15:51:41 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E4=BA=86=E7=BB=84=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/view/components/areaChose.vue | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/view/components/areaChose.vue b/src/view/components/areaChose.vue index a2398a6..c86fea5 100644 --- a/src/view/components/areaChose.vue +++ b/src/view/components/areaChose.vue @@ -46,6 +46,8 @@ const options = reactive([ const actIndex = ref(0) const townLists = ref([]) +const emit = defineEmits(['handTown', 'handArea']) + // 选择区/县 const handChose = (index) => { actIndex.value = index; @@ -53,6 +55,7 @@ const handChose = (index) => { options.forEach(item => { if (item.value == options[index].value) { sendFn('choserArea', { name: item.label, code: item.value }) + emit('handArea', options[actIndex.value].value,) } }) } @@ -67,6 +70,7 @@ const handTown = (index)=>{ townLists.value.forEach(item => { if (item.code == townLists.value[index].code) { sendFn('choseTown', { name: item.name }) + emit('handTown', options[actIndex.value].value, item.code) } }) }