m修复talk页奇怪的bug

This commit is contained in:
田岩
2025-12-12 21:29:33 +08:00
parent 6cb40e0242
commit 5774ea2514
+5 -11
View File
@@ -69,13 +69,13 @@
const isVideoStyle = computed(() => dataInfo.traInterTyp === '03'); const isVideoStyle = computed(() => dataInfo.traInterTyp === '03');
const dataInfo = reactive({ const dataInfo = reactive({
isPreview: '', // 是否是预览
traId: '', traId: '',
chaId: '', chaId: '',
traType: '', traType: '',
traInterTyp: '', traInterTyp: '',
execId: '', execId: '',
sceneDesc: '', sceneDesc: '',
preview: false, // 是否是预览
traInterTypDesc: '', // 类型的文字提示,例如 语音通话 traInterTypDesc: '', // 类型的文字提示,例如 语音通话
ossAddr: '', //用户头像 ossAddr: '', //用户头像
chaName: '' //用户名称 chaName: '' //用户名称
@@ -118,7 +118,8 @@
dataInfo.execId + dataInfo.execId +
'&type=' + '&type=' +
dataInfo.traType + dataInfo.traType +
'&isPreview=' + dataInfo.isPreview '&isPreview=' +
(dataInfo.preview ? '1' : '')
); );
} else { } else {
common.navigateBack() common.navigateBack()
@@ -245,8 +246,7 @@
// 只有app才能打开摄像头 // 只有app才能打开摄像头
isVideo.value = dataInfo.traInterTyp === '03'; isVideo.value = dataInfo.traInterTyp === '03';
//#endif //#endif
console.log('isVideo.value', isVideo.value); dataInfo.preview = e.isPreview === '1'; // 是否是预览
dataInfo.isPreview = e.isPreview ?? '0'; // 是否是预览
const pageData = common.getPageCache('tipMsgsceneDesc'); const pageData = common.getPageCache('tipMsgsceneDesc');
dataInfo.ossAddr = pageData.ossAddr; dataInfo.ossAddr = pageData.ossAddr;
dataInfo.chaName = pageData.chaName; dataInfo.chaName = pageData.chaName;
@@ -254,13 +254,7 @@
}); });
onMounted(() => { onMounted(() => {
initConnection({ initConnection({
authParams: { authParams: Object.assign({}, dataInfo),
'traType': dataInfo.traType,
'traInterTyp': dataInfo.traInterTyp,
'traId': dataInfo.traId,
'chaId': dataInfo.chaId,
'preview': true
},
onStartRecord: onStartRecord, onStartRecord: onStartRecord,
playPcmCallback: (res) => talkSpeakerRef.value.playPCM(res), playPcmCallback: (res) => talkSpeakerRef.value.playPCM(res),
setPlayNumber: (id) => talkSpeakerRef.value.setPlayNumber(id), setPlayNumber: (id) => talkSpeakerRef.value.setPlayNumber(id),