From fae93baa6458e7fad94a567876ea9eb4539276af Mon Sep 17 00:00:00 2001 From: lzx_win <2602107437@qq.com> Date: Wed, 26 Mar 2025 12:50:38 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- common/config.js | 4 ++-- manifest.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/common/config.js b/common/config.js index a8ce1c1..50f6373 100644 --- a/common/config.js +++ b/common/config.js @@ -1,6 +1,6 @@ export default { // baseUrl : 'http://127.0.0.1:8000', // baseUrl: 'https://api.book118.com', - // baseUrl:'https://houserent-admin.hhlm1688.com' - baseUrl:'http://h5.xzaiyp.top' + baseUrl:'https://houserent-admin.hhlm1688.com' + // baseUrl:'http://h5.xzaiyp.top' } \ No newline at end of file diff --git a/manifest.json b/manifest.json index f37dbac..704440e 100644 --- a/manifest.json +++ b/manifest.json @@ -1,6 +1,6 @@ { "name" : "tenancy-wechat-uniapp", - "appid" : "__UNI__09A45BC", + "appid" : "__UNI__D597D2A", "description" : "", "versionName" : "1.0.0", "versionCode" : "100", From 94e79252a75a76403dfcd02f473e9897ac83840c Mon Sep 17 00:00:00 2001 From: "1263428893@qq.com" Date: Wed, 26 Mar 2025 22:37:50 +0800 Subject: [PATCH 2/3] 1 --- App.vue | 3 --- pages_subpack/detail/index.vue | 2 -- 2 files changed, 5 deletions(-) diff --git a/App.vue b/App.vue index be62cf0..fc8a91d 100644 --- a/App.vue +++ b/App.vue @@ -6,9 +6,6 @@ }, onShow: function() { - - - }, onHide: function() { console.log('App Hide') diff --git a/pages_subpack/detail/index.vue b/pages_subpack/detail/index.vue index 9eeebe5..42f264a 100644 --- a/pages_subpack/detail/index.vue +++ b/pages_subpack/detail/index.vue @@ -13,8 +13,6 @@ - - - + @@ -75,6 +75,11 @@ this.userYsObj = this.$utils.getkeyContent('user_ys') }, methods: { + onJump(){ + uni.switchTab({ + url:"/pages/home/index" + }) + }, open(){ this.$refs.popup.open(); }, @@ -128,7 +133,7 @@ let userInfo =response.result.userInfo if(!userInfo.nickName - || !userInfo.phone){ + || !userInfo.phone || !userInfo.headImage){ uni.navigateTo({ url:"/pages/login/index" }) diff --git a/pages/login/index.vue b/pages/login/index.vue index 12f931c..abc5ce6 100644 --- a/pages/login/index.vue +++ b/pages/login/index.vue @@ -53,10 +53,10 @@ } }, onLoad(options) { + this.imagUrl = uni.getStorageSync('userInfo').headImage + this.nameUser = uni.getStorageSync('userInfo').nickName + this.phone = uni.getStorageSync('userInfo').phone if(options.back==1){ - this.imagUrl = uni.getStorageSync('userInfo').headImage - this.nameUser = uni.getStorageSync('userInfo').nickName - this.phone = uni.getStorageSync('userInfo').phone this.back = options.back } }, @@ -78,12 +78,11 @@ code : detail.code, encryptedData: detail.encryptedData, iv:detail.iv, - sessionKey: uni.getStorageSync('sessionKey'), - openid:uni.getStorageSync('userInfo').appletOpenid } bindPhone(params).then((response) => { console.info(response) - that.phone = response.result + let data = JSON.parse(response.result) + that.phone = data.phone_info.phoneNumber }).catch(error=>{ }) diff --git a/pages/tourGuide/tourGuide.vue b/pages/tourGuide/tourGuide.vue index 38e1b9c..bf9ed3e 100644 --- a/pages/tourGuide/tourGuide.vue +++ b/pages/tourGuide/tourGuide.vue @@ -123,7 +123,7 @@ export default { return markers; }, }, - created() { + mounted() { this.getCurrentLocation() this.onHouseType() // 获取房源类型 this.onHousePageList() // 加载房源列表 diff --git a/pages/user/index.vue b/pages/user/index.vue index fdc51b7..f247f41 100644 --- a/pages/user/index.vue +++ b/pages/user/index.vue @@ -15,7 +15,8 @@ font-size: 24rpx; align-items: center; border-radius: 20rpx; - padding: 4rpx 10rpx;"> + padding: 4rpx 10rpx; + margin-left: 10rpx;"> item.url).join(','),//图片 iconImage:"",//左上角图标 homeImage:that.form.houseList.map(item => item.url).join(','),//产权证照片 - homeMp4:that.form.mp4List.map(item => item.url).join(','),//视频 + homeMp4:that.form.mp4List ? that.form.mp4List.map(item => item.url).join(',') : "",//视频 latitude:that.form.latitude, longitude:that.form.longitude } - console.log(that.form); - console.log(params); + // console.log(that.form); + // console.log(params); if(this.$utils.verificationAll(params, { image : '请上传房屋照片', diff --git a/util/request/responseInterceptors.js b/util/request/responseInterceptors.js index 8c37eec..96046ae 100644 --- a/util/request/responseInterceptors.js +++ b/util/request/responseInterceptors.js @@ -21,9 +21,18 @@ export const responseInterceptors = (vm) => { return Promise.reject(data) } - }, (response) => { /* 对响应错误做点什么 (statusCode !== 200)*/ - - console.info('interceptors.response---------',data) - return Promise.reject(response) + }, (response) => { + const data = response.data + console.info('responseresponse',data) + if(data.code === 401){ + uni.removeStorageSync('token') + uni.removeStorageSync('userInfo') + uni.removeStorageSync('sessionKey') + uni.navigateTo({ + url:"/pages/auth/index" + }) + return; + } + return Promise.reject(response) }) } \ No newline at end of file