From bfca340b72eafae338b666d6de835e27f347e859 Mon Sep 17 00:00:00 2001 From: haoyuntao Date: Tue, 7 May 2024 17:26:26 +0800 Subject: [PATCH] =?UTF-8?q?AI=E5=AF=B9=E8=AF=9D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/avatar-upload/avatar-upload.vue | 5 +++-- .../chat-scroll-view/chat-scroll-view.vue | 3 ++- src/packages/pages/ai_talk/ai_talk.vue | 1 - .../pages/ai_talk/components/session-item.vue | 6 ++++++ .../pages/ai_talk/components/session-popup.vue | 14 +++++++++----- src/packages/pages/user_set/user_set.vue | 10 +++++++++- src/pages/login/login.vue | 4 ++-- 7 files changed, 31 insertions(+), 12 deletions(-) diff --git a/src/components/avatar-upload/avatar-upload.vue b/src/components/avatar-upload/avatar-upload.vue index 02d588d..441cd07 100644 --- a/src/components/avatar-upload/avatar-upload.vue +++ b/src/components/avatar-upload/avatar-upload.vue @@ -56,6 +56,7 @@ const props = defineProps({ const emit = defineEmits<{ (event: 'update:modelValue', value: string): void (event: 'upload', value: string): void + (event: 'update', value: string): void }>() const styles = computed(() => { @@ -73,6 +74,7 @@ const styles = computed(() => { const chooseAvatar = async (e: any) => { console.log(props.modelValue) + props.modelValue && emit('update', props.modelValue) // #ifdef APP-PLUS if (client == 6) { // const res = await uni.showModal({ @@ -90,13 +92,12 @@ const chooseAvatar = async (e: any) => { // #endif // #ifndef MP-WEIXIN - console.log(props) router.navigateTo({ path: '/uni_modules/vk-uview-ui/components/u-avatar-cropper/u-avatar-cropper?destWidth=300&rectWidth=200&fileType=jpg' }) // #endif // #ifdef MP-WEIXIN - console.log(props) + const path = e.detail?.avatarUrl if (path) { uploadImageIng(path) diff --git a/src/components/chat-scroll-view/chat-scroll-view.vue b/src/components/chat-scroll-view/chat-scroll-view.vue index b30f0cf..01db046 100644 --- a/src/components/chat-scroll-view/chat-scroll-view.vue +++ b/src/components/chat-scroll-view/chat-scroll-view.vue @@ -69,7 +69,7 @@