|
@@ -3,6 +3,16 @@
|
|
|
<view class="topBody">
|
|
|
<view class="header">
|
|
|
<view class="topBg"></view>
|
|
|
+ <view class="top_num">
|
|
|
+ <view class="num_1">
|
|
|
+ <text>M币</text>
|
|
|
+ <text>{{myinfo.num_gmd}}</text>
|
|
|
+ </view>
|
|
|
+ <view class="num_2">
|
|
|
+ <text>彩豆</text>
|
|
|
+ <text>{{myinfo.num_gmd}}</text>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
<view class="infoBg">
|
|
|
<view class="top_row">
|
|
|
<view class="left" @click="goPage('/pages/my/editInfo')">
|
|
@@ -11,30 +21,36 @@
|
|
|
<view class="right" @click="goPage('/pages/my/editInfo')">
|
|
|
<view class="nickname">
|
|
|
<text>{{myinfo.nickname}}</text>
|
|
|
- <image src="../../static/icon/man.png" mode="widthFix" />
|
|
|
- <view class="level">Lv99</view>
|
|
|
+ <image src="../../static/icon/man.png" mode="widthFix" v-if="myinfo.sex_id == 1" />
|
|
|
+ <image src="../../static/icon/man.png" mode="widthFix" v-else-if="myinfo.sex_id == 2" />
|
|
|
+ <view class="level">Lv{{myinfo.my_level}}</view>
|
|
|
</view>
|
|
|
<view class="tags_list">
|
|
|
- <uni-tag class="tag" type="primary" :inverted="false" text="标签1" size="mini" />
|
|
|
- <uni-tag class="tag" type="primary" :inverted="false" text="标签2" size="mini" />
|
|
|
- <uni-tag class="tag" type="primary" :inverted="false" text="标签3" size="mini" />
|
|
|
+ <block v-for="(item,index) in aihao_tags">
|
|
|
+ <uni-tag class="tag" type="primary" :inverted="false" :text="item" size="mini" />
|
|
|
+ </block>
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
|
|
|
<view class="bottom_row">
|
|
|
<view class="intro_row">
|
|
|
- <text class="intro_text">添加简介</text>
|
|
|
- <image src="../../static/icon/add.png" mode="widthFix" class="add_icon" />
|
|
|
+ <block v-if="myinfo.content == ''">
|
|
|
+ <text class="intro_text">添加简介</text>
|
|
|
+ <image src="../../static/icon/add.png" mode="widthFix" class="add_icon" />
|
|
|
+ </block>
|
|
|
+ <block v-else>
|
|
|
+ <text class="intro_text">{{myinfo.content}}</text>
|
|
|
+ </block>
|
|
|
</view>
|
|
|
<view class="follow_info">
|
|
|
- <text class="num">378</text>
|
|
|
+ <text class="num">{{myinfo.num_attention}}</text>
|
|
|
<text class="label">关注</text>
|
|
|
<text class="separator"></text>
|
|
|
- <text class="num">29</text>
|
|
|
+ <text class="num">{{myinfo.num_fans}}</text>
|
|
|
<text class="label">粉丝</text>
|
|
|
<text class="separator"></text>
|
|
|
- <text class="num">528</text>
|
|
|
+ <text class="num">{{myinfo.num_like}}</text>
|
|
|
<text class="label">获赞</text>
|
|
|
</view>
|
|
|
</view>
|
|
@@ -100,6 +116,7 @@
|
|
|
num_history: 0,
|
|
|
num_collection: 0,
|
|
|
},
|
|
|
+ aihao_tags: [],
|
|
|
menu_list: [],
|
|
|
data_list: [{
|
|
|
url: 'https://e.zhichao.art/AI_images/a_1112_10.png',
|
|
@@ -159,6 +176,7 @@
|
|
|
// this.loadAge();
|
|
|
// this.loadData();
|
|
|
// this.loadMenu();
|
|
|
+ this.loadInfo();
|
|
|
},
|
|
|
methods: {
|
|
|
onBack() {},
|
|
@@ -200,13 +218,13 @@
|
|
|
})
|
|
|
}
|
|
|
},
|
|
|
- loadData() {
|
|
|
+ loadInfo() {
|
|
|
console.log({
|
|
|
uuid: getApp().globalData.uuid,
|
|
|
skey: getApp().globalData.skey
|
|
|
});
|
|
|
uni.request({
|
|
|
- url: this.$apiHost + '/Web/getinfo',
|
|
|
+ url: this.$apiHost + '/User/getinfo',
|
|
|
data: {
|
|
|
uuid: getApp().globalData.uuid,
|
|
|
skey: getApp().globalData.skey
|
|
@@ -220,22 +238,14 @@
|
|
|
if (res.data.need_login == "yes") {
|
|
|
// getApp().globalData.skey = "";
|
|
|
// getApp().globalData.uuid = "";
|
|
|
- uni.removeStorageSync("wapptoken");
|
|
|
- uni.redirectTo({
|
|
|
- url: '/pages/login/login'
|
|
|
- });
|
|
|
- return;
|
|
|
- }
|
|
|
- if (res.data.need_edit == "yes") {
|
|
|
- uni.navigateTo({
|
|
|
- url: '/pages/my/step'
|
|
|
- });
|
|
|
- return;
|
|
|
+ // uni.removeStorageSync("wapptoken");
|
|
|
+ // uni.redirectTo({
|
|
|
+ // url: '/pages/login/login'
|
|
|
+ // });
|
|
|
+ // return;
|
|
|
}
|
|
|
- if (res.data.avator != "") {
|
|
|
- uni.setStorageSync("my_avator", res.data.avator);
|
|
|
- } else {
|
|
|
- uni.setStorageSync("my_avator", "/static/logo.png");
|
|
|
+ if (res.data.aihao) {
|
|
|
+ this.aihao_tags = res.data.aihao.split(",");
|
|
|
}
|
|
|
this.myinfo = res.data;
|
|
|
},
|
|
@@ -247,42 +257,6 @@
|
|
|
}
|
|
|
});
|
|
|
},
|
|
|
- loadMenu() {
|
|
|
- console.log({
|
|
|
- uuid: getApp().globalData.uuid,
|
|
|
- skey: getApp().globalData.skey
|
|
|
- });
|
|
|
- uni.request({
|
|
|
- url: this.$apiHost + '/User/getinfo',
|
|
|
- data: {
|
|
|
- uuid: getApp().globalData.uuid,
|
|
|
- skey: getApp().globalData.skey
|
|
|
- },
|
|
|
- header: {
|
|
|
- "content-type": "application/json",
|
|
|
- 'sign': getApp().globalData.headerSign
|
|
|
- },
|
|
|
- success: (res) => {
|
|
|
- console.log("----:", res.data);
|
|
|
- if (res.data.need_login == "yes") {
|
|
|
- // getApp().globalData.skey = "";
|
|
|
- // getApp().globalData.uuid = "";
|
|
|
- uni.removeStorageSync("wapptoken");
|
|
|
- uni.redirectTo({
|
|
|
- url: '/pages/login/login'
|
|
|
- });
|
|
|
- return;
|
|
|
- }
|
|
|
- this.menu_list = res.data.list01;
|
|
|
- },
|
|
|
- complete: (com) => {
|
|
|
- // uni.hideLoading();
|
|
|
- },
|
|
|
- fail: (e) => {
|
|
|
- console.log("----e:", e);
|
|
|
- }
|
|
|
- });
|
|
|
- },
|
|
|
onLogout() {
|
|
|
let that = this;
|
|
|
this.$refs['DialogBox'].confirm({
|
|
@@ -321,12 +295,20 @@
|
|
|
});
|
|
|
})
|
|
|
},
|
|
|
- loadAge() {
|
|
|
- let that = this;
|
|
|
+ switchTab(index) {
|
|
|
+ this.activeTab = index;
|
|
|
+ this.loadData();
|
|
|
+ },
|
|
|
+ loadData() {
|
|
|
+ console.log({
|
|
|
+ uuid: getApp().globalData.uuid,
|
|
|
+ skey: getApp().globalData.skey
|
|
|
+ });
|
|
|
uni.request({
|
|
|
- url: this.$apiHost + '/Member/checkAge',
|
|
|
+ url: this.$apiHost + '/My/getdata',
|
|
|
data: {
|
|
|
- uuid: getApp().globalData.uuid
|
|
|
+ uuid: getApp().globalData.uuid,
|
|
|
+ skey: getApp().globalData.skey
|
|
|
},
|
|
|
header: {
|
|
|
"content-type": "application/json",
|
|
@@ -334,15 +316,10 @@
|
|
|
},
|
|
|
success: (res) => {
|
|
|
console.log("----:", res.data);
|
|
|
- if (res.data.need_xiuxi == "yes") {
|
|
|
- uni.redirectTo({
|
|
|
- url: '/pages/AboutUs/xiuxi'
|
|
|
- });
|
|
|
- return;
|
|
|
- }
|
|
|
- if (res.data.need_show_yong == 'yes') {
|
|
|
- that.showYong = true;
|
|
|
+ if (res.data.success == 'yes') {
|
|
|
+
|
|
|
}
|
|
|
+ // this.myinfo = res.data;
|
|
|
},
|
|
|
complete: (com) => {
|
|
|
// uni.hideLoading();
|
|
@@ -352,9 +329,6 @@
|
|
|
}
|
|
|
});
|
|
|
},
|
|
|
- switchTab(index) {
|
|
|
- this.activeTab = index;
|
|
|
- },
|
|
|
}
|
|
|
}
|
|
|
</script>
|