2025-09-29

聊天记录上拉获取记录
This commit is contained in:
2025-10-09 15:13:48 +08:00
parent 22c4b5d4d5
commit 039111ed27
14 changed files with 445 additions and 122 deletions

View File

@@ -164,6 +164,7 @@
</view>
</u-modal>
<u-toast ref="pdMsgRef" />
</view>
</template>
@@ -173,6 +174,8 @@
import { programAPI } from '../../api/program';
import { onLoad } from '@dcloudio/uni-app'
import { groupAPI } from '../../api/group';
const pdMsgRef = ref()
const userId = ref()
const programId = ref()
@@ -229,11 +232,17 @@
} else {
// 开启群组聊天
groupAPI.add({ programId: programId.value, userId: userId.value }).then(res => {
console.log(res);
if(res.code==200){
// 创建成功,进入聊天
uni.redirectTo({
url: '/pages/message/chat?groupId=' + res.data.groupId
})
}else{
pdMsgRef.value.show({
title: res.msg,
type: 'error'
})
}
})
}