|
@@ -103,6 +103,11 @@ export default {
|
|
|
this.aiText = "";
|
|
|
this.userText = "";
|
|
|
this.stopRecord();
|
|
|
+ if(this.curRequestController){
|
|
|
+ this.curRequestController.abort();
|
|
|
+ console.log("请求已终止");
|
|
|
+ this.curRequestController = null;
|
|
|
+ }
|
|
|
},
|
|
|
stopOne(){
|
|
|
if(this.source){
|
|
@@ -111,12 +116,18 @@ export default {
|
|
|
}
|
|
|
if (this.talkLoading) {
|
|
|
this.stopTalk();
|
|
|
+ }
|
|
|
+ if(this.curRequestController){
|
|
|
+ this.curRequestController.abort();
|
|
|
+ console.log("请求已终止");
|
|
|
+ this.curRequestController = null;
|
|
|
}
|
|
|
this.showIndex = 0;
|
|
|
this.showTextIndex = 0;
|
|
|
this.aiText = "您好,我是小可,有什么可以帮助您的?";
|
|
|
this.aiStatus = 0;
|
|
|
this.chatLoading = false;
|
|
|
+
|
|
|
},
|
|
|
recordStart(_text) {
|
|
|
var OpenCC = require("opencc-js");
|