temp jitsi
This commit is contained in:
@@ -532,10 +532,43 @@ function handleWorkcaseAction() {
|
||||
}
|
||||
|
||||
// 发起会议
|
||||
function startMeeting() {
|
||||
uni.navigateTo({
|
||||
url: `/pages/meeting/Meeting/Meeting?roomId=${roomId.value}&workcaseId=${workcaseId.value}`
|
||||
})
|
||||
async function startMeeting() {
|
||||
try {
|
||||
uni.showLoading({ title: '创建会议中...' })
|
||||
|
||||
// 调用后端API创建会议
|
||||
const res = await workcaseChatAPI.createVideoMeeting({
|
||||
roomId: roomId.value,
|
||||
workcaseId: workcaseId.value,
|
||||
meetingName: `工单 ${workcaseId.value || roomId.value} 技术支持`,
|
||||
maxParticipants: 10
|
||||
})
|
||||
|
||||
uni.hideLoading()
|
||||
|
||||
if (res.success && res.data) {
|
||||
const meetingUrl = res.data.iframeUrl
|
||||
const meetingId = res.data.meetingId
|
||||
|
||||
// 小程序/App使用webview打开会议
|
||||
uni.navigateTo({
|
||||
url: `/pages/meeting/MeetingView/MeetingView?meetingUrl=${encodeURIComponent(meetingUrl)}&meetingId=${meetingId}`,
|
||||
success: () => {
|
||||
console.log('[chatRoom] 跳转会议页面成功')
|
||||
},
|
||||
fail: (err) => {
|
||||
console.error('[chatRoom] 跳转会议页面失败:', err)
|
||||
uni.showToast({ title: '打开会议失败', icon: 'none' })
|
||||
}
|
||||
})
|
||||
} else {
|
||||
uni.showToast({ title: res.message || '创建会议失败', icon: 'none' })
|
||||
}
|
||||
} catch (e) {
|
||||
uni.hideLoading()
|
||||
console.error('[chatRoom] 创建会议失败:', e)
|
||||
uni.showToast({ title: '创建会议失败', icon: 'none' })
|
||||
}
|
||||
}
|
||||
|
||||
// 返回上一页
|
||||
|
||||
Reference in New Issue
Block a user