|
|
@@ -3,7 +3,8 @@
|
|
|
<div class="qaa_title">{{ work.answerQ }}</div>
|
|
|
<div class="qaa_img" v-if="work.imageList && work.imageList.length > 0">
|
|
|
<div v-for="(item, index) in work.imageList" :key="index">
|
|
|
- <el-image style="width: auto; height: 100%;cursor: pointer;max-height: 300px;" :src="item.url" alt="" :preview-src-list="[item.url]" fit="cover" />
|
|
|
+ <el-image style="width: auto; height: 100%;cursor: pointer;max-height: 300px;" :src="item.url" alt=""
|
|
|
+ :preview-src-list="[item.url]" fit="cover" />
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="qaa_type">{{ lang.ssQAQuestion }}</div>
|
|
|
@@ -164,8 +165,8 @@ export default {
|
|
|
console.log(privText)
|
|
|
};
|
|
|
|
|
|
- iframe.contentWindow.sessionStarted = (s,e)=>{
|
|
|
- console.log("sessionStarted", s,e)
|
|
|
+ iframe.contentWindow.sessionStarted = (s, e) => {
|
|
|
+ console.log("sessionStarted", s, e)
|
|
|
this.recordObj.status = "1"
|
|
|
this.recordObj.startTime = new Date().getTime();
|
|
|
}
|
|
|
@@ -173,7 +174,7 @@ export default {
|
|
|
iframe.contentWindow.ConversationTranscriber();
|
|
|
|
|
|
this.recordObj.status = "1"
|
|
|
- this.recordObj.startTime = new Date().getTime();
|
|
|
+ this.recordObj.startTime = new Date().getTime();
|
|
|
|
|
|
|
|
|
};
|
|
|
@@ -230,23 +231,31 @@ export default {
|
|
|
}
|
|
|
console.log("测试测试222")
|
|
|
// 有权限再判断状态
|
|
|
- if (this.recordObj.status == '1' && !this.recordObj.loading) {
|
|
|
- console.log("测试测3333")
|
|
|
- this.recordObj.loading = true;
|
|
|
- iframe.contentWindow.window.document
|
|
|
- .getElementById("scenarioStopButton")
|
|
|
- .click();
|
|
|
- iframe.contentWindow.onSessionStopped = (s, e) => {
|
|
|
- this.recordObj.status = "0"
|
|
|
+ try {
|
|
|
+ if (this.recordObj.status == '1' && !this.recordObj.loading) {
|
|
|
+ console.log("测试测3333")
|
|
|
+ this.recordObj.loading = true;
|
|
|
+ iframe.contentWindow.window.document
|
|
|
+ .getElementById("scenarioStopButton")
|
|
|
+ .click();
|
|
|
+ iframe.contentWindow.onSessionStopped = (s, e) => {
|
|
|
+ try {
|
|
|
+ this.recordObj.status = "0"
|
|
|
+ this.recordObj.loading = false;
|
|
|
+ this.$message.success(this.lang.ssStoppedRec)
|
|
|
+ iframe.contentWindow.onSessionStopped = null;
|
|
|
+ this._cleanupTranscriber(iframe);
|
|
|
+ } catch (error) {
|
|
|
+ alert(JSON.stringify(error))
|
|
|
+ }
|
|
|
+ };
|
|
|
+ } else {
|
|
|
+ this.recordObj.status = "0";
|
|
|
this.recordObj.loading = false;
|
|
|
- this.$message.success(this.lang.ssStoppedRec)
|
|
|
- iframe.contentWindow.onSessionStopped = null;
|
|
|
this._cleanupTranscriber(iframe);
|
|
|
- };
|
|
|
- } else {
|
|
|
- this.recordObj.status = "0";
|
|
|
- this.recordObj.loading = false;
|
|
|
- this._cleanupTranscriber(iframe);
|
|
|
+ }
|
|
|
+ } catch (error) {
|
|
|
+ alert(JSON.stringify(error))
|
|
|
}
|
|
|
}).catch((e) => {
|
|
|
alert(JSON.stringify(e))
|