From f6bd08cd318ac1a3e90725bf8a030634bb9673e8 Mon Sep 17 00:00:00 2001 From: weipengfei <2187978347@qq.com> Date: Wed, 31 Jan 2024 14:30:32 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/index/massif.vue | 9 ++++----- pages/index/personal.vue | 2 +- unpackage/dist/build/app-plus/app-service.js | 4 ++-- 3 files changed, 7 insertions(+), 8 deletions(-) diff --git a/pages/index/massif.vue b/pages/index/massif.vue index 345cd21..38e2ecf 100644 --- a/pages/index/massif.vue +++ b/pages/index/massif.vue @@ -280,7 +280,7 @@ const userInfo = ref({}); onLoad(() => { - uni.hideTabBar() + uni.hideTabBar(); // console.log(store.state.userInfo) if (!store.state.userInfo) { uni.redirectTo({ @@ -330,7 +330,7 @@ const houseInfo = ref({}); onShow(() => { getlist2() - + initFarmLists(); }) const bgc = (icon) => { return `/static/main/index/${icon}.png` @@ -385,6 +385,7 @@ const farm_lists = ref([]); const house_lists = ref([]); const farm_types_lists = ref([]); + const initFarmLists = ()=>{ farmTypeLists().then(res=>{ farm_types_lists.value = res.data @@ -411,6 +412,7 @@ id: step.id, }; })); + if(houseInfo.value.id) return ; //如果已经选择过将不再重新选择 if(res.data.length>0) houseInfo.value = res.data[1]; else houseInfo.value = {}; store.commit('setHouse', houseInfo.value); @@ -419,7 +421,6 @@ console.log(err); }) } - initFarmLists(); const farm_type = computed(()=>{ return farm_types_lists.value.find(item=>item.value==dataobj.value.farm_type)?.name || '' @@ -462,13 +463,11 @@ } const confirm2 = (e) => { showPicker.value = false - uni.navigateTo({ url: e.value[0].route + '?id=' + palntId.value }) } const confirm1 = (e) => { - palntId.value = e.value[0].id showPicker1.value = false if (e.value[0].status == 2) { diff --git a/pages/index/personal.vue b/pages/index/personal.vue index a74e53e..cf2e683 100644 --- a/pages/index/personal.vue +++ b/pages/index/personal.vue @@ -54,7 +54,7 @@ -