|
|
@ -532,7 +532,7 @@ |
|
|
|
<text style="font-weight: bold;font-size: 36rpx;">{{item.goods_price_max}}</text> |
|
|
|
<text style="font-weight: bold;font-size: 36rpx;">{{item.goods_price_max}}</text> |
|
|
|
<text style="font-size: 20rpx;margin-left:10rpx;">到手价</text> |
|
|
|
<text style="font-size: 20rpx;margin-left:10rpx;">到手价</text> |
|
|
|
<text |
|
|
|
<text |
|
|
|
style="color: #949494;font-size: 22rpx;text-decoration: line-through;">¥{{item.line_price_max}}</text> |
|
|
|
style="color: #949494;font-size: 22rpx;text-decoration: line-through;">¥{{item.line_price_min}}</text> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
<!-- <view class="comment"> |
|
|
|
<!-- <view class="comment"> |
|
|
|
<text>{{item.goods_sales}}条评论</text> |
|
|
|
<text>{{item.goods_sales}}条评论</text> |
|
|
@ -611,6 +611,7 @@ |
|
|
|
}, |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
methods: { |
|
|
|
onChooseAvatar(e) { |
|
|
|
onChooseAvatar(e) { |
|
|
|
|
|
|
|
let that = this |
|
|
|
uni.getUserProfile({ |
|
|
|
uni.getUserProfile({ |
|
|
|
desc: 'Wexin', // 这个参数是必须的 |
|
|
|
desc: 'Wexin', // 这个参数是必须的 |
|
|
|
success: res => { |
|
|
|
success: res => { |
|
|
@ -618,9 +619,49 @@ |
|
|
|
this.userInfo.avatar_url = rawData.avatarUrl; |
|
|
|
this.userInfo.avatar_url = rawData.avatarUrl; |
|
|
|
this.userInfo.nick_name = rawData.nickName; |
|
|
|
this.userInfo.nick_name = rawData.nickName; |
|
|
|
console.log("用户信息", JSON.parse(res.rawData)) |
|
|
|
console.log("用户信息", JSON.parse(res.rawData)) |
|
|
|
|
|
|
|
if (rawData) { |
|
|
|
|
|
|
|
that.headImgUpload(rawData.avatarUrl, rawData.nickName) |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
return that.$toast('获取失败') |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
}) |
|
|
|
}) |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
nickSubmit(avatar_id,nick_name) { |
|
|
|
|
|
|
|
UserApi.editUser({ |
|
|
|
|
|
|
|
avatar_id: avatar_id, |
|
|
|
|
|
|
|
nick_name: nick_name |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
.then(res => { |
|
|
|
|
|
|
|
if (res.status == 200) { |
|
|
|
|
|
|
|
uni.showToast({ |
|
|
|
|
|
|
|
title: '获取成功', |
|
|
|
|
|
|
|
icon: 'none', |
|
|
|
|
|
|
|
duration: 2000 |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
this.getUserInfo() |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
uni.showToast({ |
|
|
|
|
|
|
|
title: '获取失败', |
|
|
|
|
|
|
|
icon: 'none', |
|
|
|
|
|
|
|
duration: 2000 |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
.finally() |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
headImgUpload(avatarUrl, nickName) { |
|
|
|
|
|
|
|
// 获取推荐商品 |
|
|
|
|
|
|
|
const that = this |
|
|
|
|
|
|
|
UserApi.wxHeadImgUpload({ |
|
|
|
|
|
|
|
headImg: avatarUrl, |
|
|
|
|
|
|
|
checkLogin: 1 |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
.then(res => { |
|
|
|
|
|
|
|
that.nickSubmit(res.data.fileInfo.file_id, nickName) |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
}, |
|
|
|
goShopOrderList() { |
|
|
|
goShopOrderList() { |
|
|
|
uni.navigateTo({ |
|
|
|
uni.navigateTo({ |
|
|
|
url: '/pages/news3/shopOrder?delivery_type=10' |
|
|
|
url: '/pages/news3/shopOrder?delivery_type=10' |
|
|
|