电话咨询

This commit is contained in:
duoaohui
2026-06-08 14:24:17 +08:00
parent 3c305257f7
commit 15b7cd61cd
2 changed files with 6 additions and 11 deletions

View File

@@ -640,17 +640,7 @@ const scheduleEndedRedirect = () => {
}
const goToConsultDetail = () => {
// 结束页按钮必须强制重试,不能走 notifyMiniProgramCallEndedOnce()。
// 前面自动跳转可能已经把 miniProgramEndNotified / miniProgramRedirected 置为 true
// 但实际 wx.miniProgram 导航可能静默失败,导致用户点「查看咨询详情」也被 once guard 拦掉。
miniProgramEndNotified = false
miniProgramRedirected = false
console.log('[CloudLawVideoCall] 查看咨询详情 CLICK force redirect', {
callId: callId.value,
consultId: consultId.value,
returnUrl: buildMiniProgramReturnUrl()
})
notifyCloudLawEnd().finally(() => notifyMiniProgramCallEnded())
notifyCloudLawEnd().finally(() => notifyMiniProgramCallEndedOnce())
}
const pollCommandsOnce = async () => {

View File

@@ -137,6 +137,11 @@ export function notifyNativeMiniProgramHangup() {
return false
}
try {
const mp = window.wx && window.wx.miniProgram
if (!mp) {
console.warn('[cloudLawVoiceCall] bridge skip: window.wx.miniProgram 不存在jweixin 未加载/不在小程序 web-view 内)')
return false
}
const href = String(window.location.href || '')
if (href.includes(`${CLOUD_LAW_HANGUP_QUERY}=1`)) {
console.log('[cloudLawVoiceCall] bridge: URL 已含 cloudLawHangup=1跳过重复重载')