fix : 语音输出状态
This commit is contained in:
@@ -546,7 +546,6 @@ export function useRealtimeRecorderOnce() {
|
|||||||
|
|
||||||
// 发送到服务器进行识别
|
// 发送到服务器进行识别
|
||||||
await sendToASR(audioBlob);
|
await sendToASR(audioBlob);
|
||||||
isProcessing.value = false
|
|
||||||
} else {
|
} else {
|
||||||
throw new Error('录音数据为空或无效');
|
throw new Error('录音数据为空或无效');
|
||||||
}
|
}
|
||||||
@@ -604,6 +603,7 @@ export function useRealtimeRecorderOnce() {
|
|||||||
if (response.ok) {
|
if (response.ok) {
|
||||||
const result = await response.json();
|
const result = await response.json();
|
||||||
if(result.code == 200){
|
if(result.code == 200){
|
||||||
|
isProcessing.value = false
|
||||||
recognizedText.value = result.data || ''
|
recognizedText.value = result.data || ''
|
||||||
}else{
|
}else{
|
||||||
$api.msg(result.msg || '识别失败')
|
$api.msg(result.msg || '识别失败')
|
||||||
|
|||||||
Reference in New Issue
Block a user