Browse Source

情绪大模型喇叭颜色校正;

dev
宋杰 2 days ago
parent
commit
5cb72d6775
  1. 21
      src/views/AiEmotion.vue

21
src/views/AiEmotion.vue

@ -1664,6 +1664,13 @@ const playNextAudio = () => {
emotionAudioStore.nowSound = null;
isCallingPlayNext = false;
//
const currentStock = emotionStore.activeStock;
if (currentStock) {
console.log('所有音频播放完成,重置当前股票音频状态:', currentStock.stockInfo?.name);
setStockAudioState(currentStock, { isPlaying: false, isPaused: false });
}
//
if (
audioInfo.onComplete &&
@ -1681,6 +1688,13 @@ const playNextAudio = () => {
emotionAudioStore.playbackPosition = 0;
isAudioPlaying.value = false;
isPlayingQueueAudio.value = false;
//
const currentStock = emotionStore.activeStock;
if (currentStock) {
console.log('音频被停止,重置当前股票音频状态:', currentStock.stockInfo?.name);
setStockAudioState(currentStock, { isPlaying: false, isPaused: false });
}
},
onerror: (error) => {
console.error(`${audioInfo.name}音频播放失败:`, error);
@ -1844,6 +1858,13 @@ function playAudioQueue(
}
} else {
console.log(`总共找到 ${audioQueue.value.length} 个音频,准备播放`);
//
const currentStock = emotionStore.activeStock;
if (currentStock) {
console.log('设置当前股票音频状态为播放中:', currentStock.stockInfo?.name);
setStockAudioState(currentStock, { isPlaying: true, isPaused: false });
}
}
} catch (error) {
console.error("处理音频播放失败:", error);

Loading…
Cancel
Save