|
|
@@ -42,7 +42,7 @@ const _sfc_main = {
|
|
|
// 其他属性保持不变...
|
|
|
questions: [],
|
|
|
// 添加新属性存储API返回的问题数据
|
|
|
- introVideoUrl: "http://121.36.251.245:9000/minlong/tenant_1/general_uploads/880a117c8fcc4196b0d8c0750608d373.mp4",
|
|
|
+ introVideoUrl: "https://data.qicai321.com/minlong/ee4d9cce-c3d5-4350-8c6e-684283827897.mp4",
|
|
|
// 保留介绍视频
|
|
|
isRecording: false,
|
|
|
recordingTimer: null,
|
|
|
@@ -137,8 +137,10 @@ const _sfc_main = {
|
|
|
// 录制进度百分比
|
|
|
progressColor: "#05dc8b",
|
|
|
// 进度条颜色
|
|
|
- progressBgColor: "rgba(0, 0, 0,0.3)"
|
|
|
+ progressBgColor: "rgba(0, 0, 0,0.3)",
|
|
|
// 进度条背景色
|
|
|
+ parentQuestion: ""
|
|
|
+ // 添加父问题存储
|
|
|
};
|
|
|
},
|
|
|
mounted() {
|
|
|
@@ -602,7 +604,6 @@ const _sfc_main = {
|
|
|
}
|
|
|
if (this.isFollowUpQuestion) {
|
|
|
console.log("追问问题视频播放完成");
|
|
|
- this.isFollowUpQuestion = false;
|
|
|
this.showStartRecordingButton = true;
|
|
|
this.startCountdown();
|
|
|
return;
|
|
|
@@ -613,6 +614,10 @@ const _sfc_main = {
|
|
|
} else {
|
|
|
this.showAnswerButton = true;
|
|
|
}
|
|
|
+ if (this.isFollowUpQuestion) {
|
|
|
+ this.isFollowUpQuestion = false;
|
|
|
+ this.currentFollowUpQuestion = null;
|
|
|
+ }
|
|
|
},
|
|
|
// 添加新方法:开始倒计时
|
|
|
startCountdown() {
|
|
|
@@ -2208,11 +2213,14 @@ const _sfc_main = {
|
|
|
this.proceedToNextQuestion();
|
|
|
}
|
|
|
},
|
|
|
- // 添加新方法:播放追问问题视频
|
|
|
+ // 修改播放追问问题视频的方法
|
|
|
playFollowUpQuestionVideo(followUpQuestion) {
|
|
|
console.log("播放追问问题视频:", followUpQuestion.digital_human_video_url);
|
|
|
+ this.parentQuestion = this.currentSubtitle;
|
|
|
this.videoUrl = followUpQuestion.digital_human_video_url;
|
|
|
this.videoPlaying = true;
|
|
|
+ this.isFollowUpQuestion = true;
|
|
|
+ this.currentFollowUpQuestion = followUpQuestion;
|
|
|
const followUpSubtitles = [{
|
|
|
startTime: 0,
|
|
|
endTime: 60,
|
|
|
@@ -2254,6 +2262,10 @@ const _sfc_main = {
|
|
|
// 修改进度百分比的计算方式
|
|
|
progressPercent() {
|
|
|
return Math.min(Math.round(this.recordingTimerCount / this.maxRecordingTime * 100), 100);
|
|
|
+ },
|
|
|
+ // 添加总题数计算属性
|
|
|
+ totalQuestions() {
|
|
|
+ return this.questions.length || 5;
|
|
|
}
|
|
|
}
|
|
|
};
|
|
|
@@ -2270,26 +2282,36 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
h: common_vendor.o((...args) => $options.handleAnswerButtonClick && $options.handleAnswerButtonClick(...args))
|
|
|
} : {}, {
|
|
|
i: $data.currentSubtitle
|
|
|
- }, $data.currentSubtitle ? {
|
|
|
- j: common_vendor.t($data.currentSubtitle)
|
|
|
+ }, $data.currentSubtitle ? common_vendor.e({
|
|
|
+ j: $data.currentVideoIndex > 0
|
|
|
+ }, $data.currentVideoIndex > 0 ? {
|
|
|
+ k: common_vendor.t($data.currentVideoIndex),
|
|
|
+ l: common_vendor.t($options.totalQuestions)
|
|
|
} : {}, {
|
|
|
- k: $data.useMiniProgramCameraComponent
|
|
|
+ m: !$data.isFollowUpQuestion
|
|
|
+ }, !$data.isFollowUpQuestion ? {
|
|
|
+ n: common_vendor.t($data.currentSubtitle)
|
|
|
+ } : {
|
|
|
+ o: common_vendor.t($data.parentQuestion),
|
|
|
+ p: common_vendor.t($data.currentSubtitle)
|
|
|
+ }) : {}, {
|
|
|
+ q: $data.useMiniProgramCameraComponent
|
|
|
}, $data.useMiniProgramCameraComponent ? {
|
|
|
- l: common_vendor.o((...args) => $options.handleCameraError && $options.handleCameraError(...args))
|
|
|
+ r: common_vendor.o((...args) => $options.handleCameraError && $options.handleCameraError(...args))
|
|
|
} : {}, {
|
|
|
- m: $data.loading
|
|
|
+ s: $data.loading
|
|
|
}, $data.loading ? {} : {}, {
|
|
|
- n: $data.showDebugInfo
|
|
|
+ t: $data.showDebugInfo
|
|
|
}, $data.showDebugInfo ? common_vendor.e({
|
|
|
- o: $data.assistantResponse
|
|
|
+ v: $data.assistantResponse
|
|
|
}, $data.assistantResponse ? {
|
|
|
- p: common_vendor.t($data.assistantResponse)
|
|
|
+ w: common_vendor.t($data.assistantResponse)
|
|
|
} : {}, {
|
|
|
- q: $data.audioTranscript
|
|
|
+ x: $data.audioTranscript
|
|
|
}, $data.audioTranscript ? {
|
|
|
- r: common_vendor.t($data.audioTranscript)
|
|
|
+ y: common_vendor.t($data.audioTranscript)
|
|
|
} : {}, {
|
|
|
- s: common_vendor.f($data.processedResponses, (item, index, i0) => {
|
|
|
+ z: common_vendor.f($data.processedResponses, (item, index, i0) => {
|
|
|
return common_vendor.e({
|
|
|
a: item.role
|
|
|
}, item.role ? {
|
|
|
@@ -2303,30 +2325,30 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
});
|
|
|
})
|
|
|
}) : {}, {
|
|
|
- t: $data.showStopRecordingButton
|
|
|
+ A: $data.showStopRecordingButton
|
|
|
}, $data.showStopRecordingButton ? {
|
|
|
- v: common_vendor.o((...args) => $options.stopRecordingAnswer && $options.stopRecordingAnswer(...args))
|
|
|
+ B: common_vendor.o((...args) => $options.stopRecordingAnswer && $options.stopRecordingAnswer(...args))
|
|
|
} : {}, {
|
|
|
- w: $data.isRecording
|
|
|
+ C: $data.isRecording
|
|
|
}, $data.isRecording ? {
|
|
|
- x: common_vendor.t($data.recordingTimeDisplay),
|
|
|
- y: `conic-gradient(${$data.progressColor} ${$options.progressPercent}%, ${$data.progressBgColor} 0%)`
|
|
|
+ D: common_vendor.t($data.recordingTimeDisplay),
|
|
|
+ E: `conic-gradient(${$data.progressColor} ${$options.progressPercent}%, ${$data.progressBgColor} 0%)`
|
|
|
} : {}, {
|
|
|
- z: $data.showStartRecordingButton
|
|
|
+ F: $data.showStartRecordingButton
|
|
|
}, $data.showStartRecordingButton ? {
|
|
|
- A: common_vendor.o((...args) => $options.handleStartRecordingClick && $options.handleStartRecordingClick(...args))
|
|
|
+ G: common_vendor.o((...args) => $options.handleStartRecordingClick && $options.handleStartRecordingClick(...args))
|
|
|
} : {}, {
|
|
|
- B: $data.showRetryButton
|
|
|
+ H: $data.showRetryButton
|
|
|
}, $data.showRetryButton ? {
|
|
|
- C: common_vendor.o((...args) => $options.retryVideoUpload && $options.retryVideoUpload(...args))
|
|
|
+ I: common_vendor.o((...args) => $options.retryVideoUpload && $options.retryVideoUpload(...args))
|
|
|
} : {}, {
|
|
|
- D: $data.showCountdown
|
|
|
+ J: $data.showCountdown
|
|
|
}, $data.showCountdown ? {
|
|
|
- E: common_vendor.t($data.countdownValue)
|
|
|
+ K: common_vendor.t($data.countdownValue)
|
|
|
} : {}, {
|
|
|
- F: $data.showRerecordButton
|
|
|
+ L: $data.showRerecordButton
|
|
|
}, $data.showRerecordButton ? {
|
|
|
- G: common_vendor.o((...args) => $options.handleRerecordButtonClick && $options.handleRerecordButtonClick(...args))
|
|
|
+ M: common_vendor.o((...args) => $options.handleRerecordButtonClick && $options.handleRerecordButtonClick(...args))
|
|
|
} : {});
|
|
|
}
|
|
|
const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-464e78c6"]]);
|