From 6e27f421d2b2c26ef9ae8ea67cc6de09f7b5cfa1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E8=88=AA?= Date: Fri, 19 Dec 2025 16:46:25 +0800 Subject: [PATCH] =?UTF-8?q?JLBA202505130001=5F=E5=85=B3=E4=BA=8E=E5=90=89?= =?UTF-8?q?=E6=9E=97=E9=93=B6=E8=A1=8C=E6=96=B0=E5=BB=BAAI=E6=99=BA?= =?UTF-8?q?=E8=83=BD=E5=9F=B9=E8=AE=AD=E7=B3=BB=E7=BB=9F=E7=9A=84=E9=9C=80?= =?UTF-8?q?=E6=B1=82=5Ffix:=20bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/sparring/components/talk-microphone.vue | 11 ++++++----- src/pages/sparring/talk.vue | 12 ++++++++++-- 2 files changed, 16 insertions(+), 7 deletions(-) diff --git a/src/pages/sparring/components/talk-microphone.vue b/src/pages/sparring/components/talk-microphone.vue index ab861c1c..bfd5d29b 100644 --- a/src/pages/sparring/components/talk-microphone.vue +++ b/src/pages/sparring/components/talk-microphone.vue @@ -25,6 +25,7 @@ stop() { this.status = 'stop'; this.options = null; + }, frameRecorded({ isLastFrame, frameBuffer }) { // console.log('1111',typeof this.onFrameRecorded); @@ -54,11 +55,11 @@ return bytes; }, toShowToast() { - uni.showToast({ - title: '发生错误,请检查是否有麦克风权限', - icon: 'none' - }); - this.stop(); + // uni.showToast({ + // title: '发生错误,请检查是否有麦克风权限11', + // icon: 'none' + // }); + this.$emit('noPermission') }, recordedChunks(base64) { this.$emit('onStop', base64); diff --git a/src/pages/sparring/talk.vue b/src/pages/sparring/talk.vue index e4c28d63..e4c4d236 100644 --- a/src/pages/sparring/talk.vue +++ b/src/pages/sparring/talk.vue @@ -20,7 +20,7 @@ - + @@ -137,7 +137,15 @@ const onCurrentDecibels = (res) => { console.log('当前分贝', res); }; - + + // 麦克风录音结束 + const microphoneNoPermission= () =>{ + common.show('', '该功能需要授予麦克风权限', false).then((res) => { + if (res) { + destroy(); // 走关闭销毁流程 + } + }); + } // 定时器实例 let timer = null;