dev
haoyuntao 7 months ago
parent 60762f9175
commit bfca340b72
  1. 5
      src/components/avatar-upload/avatar-upload.vue
  2. 1
      src/components/chat-scroll-view/chat-scroll-view.vue
  3. 1
      src/packages/pages/ai_talk/ai_talk.vue
  4. 6
      src/packages/pages/ai_talk/components/session-item.vue
  5. 14
      src/packages/pages/ai_talk/components/session-popup.vue
  6. 10
      src/packages/pages/user_set/user_set.vue
  7. 4
      src/pages/login/login.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<CSSProperties>(() => {
@ -73,6 +74,7 @@ const styles = computed<CSSProperties>(() => {
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)

@ -822,6 +822,7 @@ defineExpose({
position: relative;
padding: 20rpx 30rpx;
background-color: #fff;
box-shadow: 2px -3px 2px #f1f1f1;
.float-btn {
position: absolute;
left: 50%;

@ -137,7 +137,6 @@ const getProblemExample = async () => {
problem.value = await getSamplesLists()
}
const handlerback=()=>{
console.log(popup.value,'=====popup.value')
popup.value.showPopup()
}
const getDecorateFunc = async () => {

@ -132,6 +132,12 @@ watch(
}
.line-clamp-1{
font-size:28rpx;
width:100%;
word-break:break-all;
display:-webkit-box;
-webkit-line-clamp:1;
-webkit-box-orient:vertical;
overflow:hidden;
}
.border{
width:92%;

@ -29,7 +29,7 @@
</scroll-view>
</view>
<view class="text-xs items-center create" @click="sessionAddTalk">
<u-icon name="plus" class="mt-[15rpx]" size="40" />
<u-icon name="plus" class="mt-[20rpx]" size="40" />
<view class="create-tx">新建</view>
</view>
<!-- <u-button
@ -47,7 +47,7 @@ import { useAppStore } from '@/stores/app'
import { useSessionList } from './useSessionList'
import { useLockFn } from '@/hooks/useLockFn'
import SessionItem from './session-item.vue'
import { watch,defineExpose } from 'vue'
import { watch } from 'vue'
const props = defineProps({
modelValue: {
type: Boolean
@ -70,7 +70,8 @@ const {
sessionEdit,
sessionDelete,
sessionClear,
sessionActive
sessionActive,
getSessionLists
} = useSessionList()
const { lockFn: sessionAddLock, isLock } = useLockFn(async () => {
@ -83,7 +84,10 @@ const sessionAddTalk=()=>{
const sessionDetail=(val)=>{
emit('update:modelValue', val)
}
const showPopup=()=>emit('update:modelValue', true)
const showPopup=()=>{
getSessionLists()
emit('update:modelValue', true)
}
const appStore = useAppStore()
watch(
() => appStore.getChatConfig,
@ -109,7 +113,7 @@ defineExpose({
}
.create{
position: fixed;
bottom:30rpx;
bottom:50rpx;
right:20rpx;
width:130rpx;
height:130rpx;

@ -15,6 +15,7 @@
v-model="userInfo.avatar"
file-key="url"
:round="true"
@update="handlerUpdate"
@upload="uploadImg"
>
<template #footer>
@ -343,7 +344,7 @@
</template>
<script lang="ts" setup>
import { ref, shallowRef } from 'vue'
import { ref, shallowRef,watch } from 'vue'
import { onShow, onLoad } from '@dcloudio/uni-app'
import {
getUserInfo,
@ -413,6 +414,13 @@ const mobileCode = ref<string>('')
const codeTips = ref('')
const uCodeRef = shallowRef()
watch(()=> userInfo.value.avatar,(val,old)=>{
console.log(val,'=========头像',old)
},{deep: true})
const handlerUpdate=(val: string)=>{
console.log(val,'=========touxiang')
userInfo.value.avatar=val
}
//
const getUser = async (): Promise<void> => {
userInfo.value = await getUserInfo()

@ -57,7 +57,7 @@
/>
<div class="text-sm mt-[10px]">手机号登录</div>
</div>
<div
<!-- <div
class="flex flex-col items-center"
v-if="hasMailboxLogin && !isMailboxLogin"
@click="changeLoginWay(LoginWayEnum.MAILBOX)"
@ -67,7 +67,7 @@
:size="80"
/>
<div class="text-sm mt-[10px]">邮箱登录</div>
</div>
</div> -->
</div>
<!-- <agreement /> -->
</view>

Loading…
Cancel
Save