From 3f1abfa35fadb7363562705e41161ad147877f28 Mon Sep 17 00:00:00 2001 From: shikong <919411476@qq.com> Date: Wed, 6 Nov 2024 23:22:42 +0800 Subject: [PATCH] =?UTF-8?q?=E7=99=BB=E5=BD=95=E4=BF=A1=E6=81=AF=E8=8E=B7?= =?UTF-8?q?=E5=8F=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/my-info/my-info.vue | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/src/pages/my-info/my-info.vue b/src/pages/my-info/my-info.vue index 28e523c..703a54d 100644 --- a/src/pages/my-info/my-info.vue +++ b/src/pages/my-info/my-info.vue @@ -2,6 +2,14 @@ 页面内容 + + + + + + @@ -23,13 +31,20 @@ import {reactive, watchEffect} from "vue" import {useI18n} from "vue-i18n" import {onReady} from "@dcloudio/uni-app"; const {t, locale} = useI18n() +const defaultAvatarUrl = 'https://mmbiz.qpic.cn/mmbiz/icTdbqWNOwNRna42FI242Lcia07jQodd2FJGIYQfG0LAJGFxM4FbnQP6yfMxBgJ0F3YRqJCJ1aPAK2dQagdusBZg/0' const ctx = reactive({ lang: { switchTo: '' - } + }, + avatarUrl: defaultAvatarUrl, }) +function onChooseAvatar(e) { + const { avatarUrl } = e.detail + ctx.avatarUrl = avatarUrl +} + function switchLanguage(){ if(uni.getLocale().startsWith("en")){ uni.setLocale("zh-Hans")