|
|
@@ -77,18 +77,6 @@ export default {
|
|
|
url: "/pages/selfCenter/my_fix",
|
|
|
isShow:true,
|
|
|
},
|
|
|
- // {
|
|
|
- // icoin: "/static/selfCenter/collection.png",
|
|
|
- // name: "我的收藏",
|
|
|
- // url: "/pages/selfCenter/collection",
|
|
|
- // isShow:true,
|
|
|
- // },
|
|
|
- // {
|
|
|
- // icoin: "/static/selfCenter/collection.png",
|
|
|
- // name: "工业经济指标",
|
|
|
- // url: "/pages/metrics/index",
|
|
|
- // isShow:true,
|
|
|
- // },
|
|
|
{
|
|
|
icoin: "/static/selfCenter/back.png",
|
|
|
name: "退出登录" ,
|
|
|
@@ -117,8 +105,54 @@ export default {
|
|
|
});
|
|
|
},
|
|
|
goWithHouse(){
|
|
|
- uni.navigateTo({
|
|
|
- url: "/pages/selfCenter/with_house",
|
|
|
+ if (this.isWith == 0)
|
|
|
+ {
|
|
|
+ uni.navigateTo({
|
|
|
+ url: "/pages/selfCenter/with_house",
|
|
|
+ });
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ //解除绑定
|
|
|
+ let md5Sign = md5(
|
|
|
+ "method=" +
|
|
|
+ "user" +
|
|
|
+ "×tamp=" +
|
|
|
+ getApp().globalData.globalTimestamp +
|
|
|
+ "&secret=" +
|
|
|
+ getApp().globalData.secret
|
|
|
+ );
|
|
|
+ let url =
|
|
|
+ getApp().globalData.shareUrl +
|
|
|
+ "api/api.php" +
|
|
|
+ "?method=user&action=unband_owner×tamp=" +
|
|
|
+ getApp().globalData.globalTimestamp +
|
|
|
+ "&sign=" +
|
|
|
+ md5Sign;
|
|
|
+ uni.request({
|
|
|
+ url: url,
|
|
|
+ method: "POST",
|
|
|
+ header: {
|
|
|
+ "content-type": "application/x-www-form-urlencoded",
|
|
|
+ },
|
|
|
+ data: {
|
|
|
+ openId: getApp().globalData.open_id,
|
|
|
+ },
|
|
|
+ success: (res) => {
|
|
|
+ if (res.data.code === 200) {
|
|
|
+ this.isWith = 0;
|
|
|
+ this.houseInfo.address = "";
|
|
|
+ this.houseInfo.master = "";
|
|
|
+ this.houseInfo.area = "";
|
|
|
+ uni.showToast({
|
|
|
+ title: "已解除绑定",
|
|
|
+ duration: 2500,
|
|
|
+ icon: "none",
|
|
|
+ });
|
|
|
+ }
|
|
|
+ },
|
|
|
+ fail: () => {
|
|
|
+ console.log("连接失败");
|
|
|
+ },
|
|
|
});
|
|
|
},
|
|
|
goDetailFn(index, url) {
|
|
|
@@ -238,6 +272,15 @@ export default {
|
|
|
if(res.data.data.stat_user){
|
|
|
this.list[3].isShow = true;
|
|
|
}
|
|
|
+
|
|
|
+ if (res.data.data.owner_info){
|
|
|
+ let wi = res.data.data.owner_info;
|
|
|
+ this.houseInfo.address = wi.estate_name + wi.building_name + wi.unit + wi.room;
|
|
|
+ this.houseInfo.master = wi.owner_name;
|
|
|
+ this.houseInfo.area = wi.area;
|
|
|
+ this.isWith = 1;
|
|
|
+ }
|
|
|
+
|
|
|
} else {
|
|
|
this.isAuth = false;
|
|
|
getApp().globalData.globalAuth = false;
|