From 1ae987d882c1d67c0ee11c40af05d311df9e214b Mon Sep 17 00:00:00 2001 From: zxl <763096477@qq.com> Date: 星期三, 23 七月 2025 15:25:55 +0800 Subject: [PATCH] 需求改动 --- pages/tabbar/user/my.vue | 27 +++++++++++++++++++++++---- 1 files changed, 23 insertions(+), 4 deletions(-) diff --git a/pages/tabbar/user/my.vue b/pages/tabbar/user/my.vue index 2bbfdd4..4ae3257 100644 --- a/pages/tabbar/user/my.vue +++ b/pages/tabbar/user/my.vue @@ -6,7 +6,8 @@ </view> <view class="header" @click="userDetail"> <view class="head-1"> - <image :src="userInfo.face || userImage"></image> + <image v-if="userInfo.face" :src="endpoint + '/' + userInfo.face"></image> + <image v-else :src="userImage"></image> </view> <view class="head-2" v-if="userInfo.id"> <view class="user-name">{{ userInfo.nickName }}</view> @@ -96,6 +97,12 @@ </view> <view>鎴戠殑娲诲姩</view> </view> + <view class="order-item" @click="navigateTo('/pages/mine/myTracks')"> + <view> + <text class="iconfont"></text> + </view> + <view>娴忚璁板綍</view> + </view> </view> </div> @@ -109,8 +116,9 @@ </view> </template> <script> -import '@/components/uview-components/uview-ui'; +import '@/pages/subComponents/uview-components/uview-ui'; import tool from "@/pages/tabbar/user/utils/tool.vue"; +import { getSTSToken } from "@/api/common.js"; import { getCouponsNum, getFootprintNum } from "@/api/members.js"; import { getUserWallet } from "@/api/members"; import configs from '@/config/config' @@ -121,6 +129,7 @@ }, data() { return { + endpoint: '', configs, userImage:configs.defaultUserPhoto, coverTransform: "translateY(0px)", @@ -132,7 +141,9 @@ walletNum: "", }; }, - onLoad() { }, + onLoad() { + this.initCOS() + }, onShow() { this.userInfo = this.$options.filters.isLogin() || {}; if (this.$options.filters.isLogin("auth")) { @@ -158,6 +169,14 @@ mounted() { }, methods: { + // 鍒濆鍖栬吘璁簯cos瀹㈡埛绔� + initCOS() { + // 璋冪敤鍚庣鑾峰彇sts涓存椂璁块棶鍑瘉 + getSTSToken().then(res => { + this.endpoint = res.data.data.endpoint + }) + }, + // 璺宠浆瑙嗛涓婚〉 jumpToVideoHome() { uni.navigateTo({ url: '/pages/video/home-page?authorId=' + storage.getUserInfo().id @@ -215,7 +234,7 @@ background-size: cover; border-bottom-left-radius: 30rpx; border-bottom-right-radius: 30rpx; - background-image: url("/static/img/main-bg.png"); + background-image: url("/pages/subComponents/static/img/main-bg.png"); background-position: bottom; background-repeat: no-repeat; color: #ffffff; -- Gitblit v1.8.0