Bladeren bron

Merge branch 'beta'

lsc 1 jaar geleden
bovenliggende
commit
f0a2f14e56

+ 1 - 1
dist/index.html

@@ -32,7 +32,7 @@
       width: 100%;
       background: #e6eaf0;
       font-family: '黑体';
-    }</style><link href=./static/css/app.0a0872830bdb78633fc9399bf5cb7d9f.css rel=stylesheet></head><body><div id=app></div><script type=text/javascript src=./static/js/manifest.e9c12cd41f6178fd10e7.js></script><script type=text/javascript src=./static/js/vendor.48018345936b7569e64e.js></script><script type=text/javascript src=./static/js/app.8c502291ac32f0e343cf.js></script></body></html><script>function stopSafari() {
+    }</style><link href=./static/css/app.92fc15c5674f3229ff8e994cf5744006.css rel=stylesheet></head><body><div id=app></div><script type=text/javascript src=./static/js/manifest.571c38d63f24b1ae9e16.js></script><script type=text/javascript src=./static/js/vendor.8db9a3f753f5644e3c5e.js></script><script type=text/javascript src=./static/js/app.46667317cf727bb6b265.js></script></body></html><script>function stopSafari() {
     //阻止safari浏览器双击放大功能
     let lastTouchEnd = 0  //更新手指弹起的时间
     document.documentElement.addEventListener("touchstart", function (event) {

File diff suppressed because it is too large
+ 0 - 0
dist/static/css/app.92fc15c5674f3229ff8e994cf5744006.css


File diff suppressed because it is too large
+ 0 - 0
dist/static/css/app.92fc15c5674f3229ff8e994cf5744006.css.map


+ 0 - 0
dist/static/img/videoFile.2273786.svg → dist/static/img/videoFile.8b2406f.svg


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/0.35cc8a07bbd75bad52ac.js.map


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/0.7da288988865a9378b49.js


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/0.7da288988865a9378b49.js.map


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/app.46667317cf727bb6b265.js


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/app.46667317cf727bb6b265.js.map


+ 2 - 2
dist/static/js/manifest.e9c12cd41f6178fd10e7.js → dist/static/js/manifest.571c38d63f24b1ae9e16.js

@@ -1,2 +1,2 @@
-!function(e){var n=window.webpackJsonp;window.webpackJsonp=function(r,a,c){for(var i,u,f,s=0,l=[];s<r.length;s++)u=r[s],t[u]&&l.push(t[u][0]),t[u]=0;for(i in a)Object.prototype.hasOwnProperty.call(a,i)&&(e[i]=a[i]);for(n&&n(r,a,c);l.length;)l.shift()();if(c)for(s=0;s<c.length;s++)f=o(o.s=c[s]);return f};var r={},t={6:0};function o(n){if(r[n])return r[n].exports;var t=r[n]={i:n,l:!1,exports:{}};return e[n].call(t.exports,t,t.exports,o),t.l=!0,t.exports}o.e=function(e){var n=t[e];if(0===n)return new Promise(function(e){e()});if(n)return n[2];var r=new Promise(function(r,o){n=t[e]=[r,o]});n[2]=r;var a=document.getElementsByTagName("head")[0],c=document.createElement("script");c.type="text/javascript",c.charset="utf-8",c.async=!0,c.timeout=12e4,o.nc&&c.setAttribute("nonce",o.nc),c.src=o.p+"static/js/"+e+"."+{0:"35cc8a07bbd75bad52ac",1:"d8d4e9b1fe43bbb0a681",2:"94e1427bfc7ef0b4c685",3:"3a9f53a78da16650e6b8"}[e]+".js";var i=setTimeout(u,12e4);function u(){c.onerror=c.onload=null,clearTimeout(i);var n=t[e];0!==n&&(n&&n[1](new Error("Loading chunk "+e+" failed.")),t[e]=void 0)}return c.onerror=c.onload=u,a.appendChild(c),r},o.m=e,o.c=r,o.d=function(e,n,r){o.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:r})},o.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(n,"a",n),n},o.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},o.p="./",o.oe=function(e){throw console.error(e),e}}([]);
-//# sourceMappingURL=manifest.e9c12cd41f6178fd10e7.js.map
+!function(e){var n=window.webpackJsonp;window.webpackJsonp=function(r,a,c){for(var i,u,f,s=0,l=[];s<r.length;s++)u=r[s],t[u]&&l.push(t[u][0]),t[u]=0;for(i in a)Object.prototype.hasOwnProperty.call(a,i)&&(e[i]=a[i]);for(n&&n(r,a,c);l.length;)l.shift()();if(c)for(s=0;s<c.length;s++)f=o(o.s=c[s]);return f};var r={},t={6:0};function o(n){if(r[n])return r[n].exports;var t=r[n]={i:n,l:!1,exports:{}};return e[n].call(t.exports,t,t.exports,o),t.l=!0,t.exports}o.e=function(e){var n=t[e];if(0===n)return new Promise(function(e){e()});if(n)return n[2];var r=new Promise(function(r,o){n=t[e]=[r,o]});n[2]=r;var a=document.getElementsByTagName("head")[0],c=document.createElement("script");c.type="text/javascript",c.charset="utf-8",c.async=!0,c.timeout=12e4,o.nc&&c.setAttribute("nonce",o.nc),c.src=o.p+"static/js/"+e+"."+{0:"7da288988865a9378b49",1:"d8d4e9b1fe43bbb0a681",2:"94e1427bfc7ef0b4c685",3:"3a9f53a78da16650e6b8"}[e]+".js";var i=setTimeout(u,12e4);function u(){c.onerror=c.onload=null,clearTimeout(i);var n=t[e];0!==n&&(n&&n[1](new Error("Loading chunk "+e+" failed.")),t[e]=void 0)}return c.onerror=c.onload=u,a.appendChild(c),r},o.m=e,o.c=r,o.d=function(e,n,r){o.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:r})},o.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(n,"a",n),n},o.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},o.p="./",o.oe=function(e){throw console.error(e),e}}([]);
+//# sourceMappingURL=manifest.571c38d63f24b1ae9e16.js.map

File diff suppressed because it is too large
+ 0 - 0
dist/static/js/manifest.571c38d63f24b1ae9e16.js.map


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/vendor.8db9a3f753f5644e3c5e.js


File diff suppressed because it is too large
+ 0 - 0
dist/static/js/vendor.8db9a3f753f5644e3c5e.js.map


+ 42 - 22
src/components/pages/aiAddCourse/aiBoxRight.vue

@@ -226,7 +226,13 @@
         :disabled="isVoice"
         ref="textareaRef"
         v-model.trim="courseText"
-        :placeholder="isVoice ? isTalk?'':'点击按钮开始录音' : '在此输入您想了解的内容'"
+        :placeholder="
+          isVoice
+            ? isTalk
+              ? ''
+              : '点击按钮开始录音'
+            : '在此输入您想了解的内容'
+        "
       ></textarea>
 
       <span
@@ -341,7 +347,7 @@
         终止
       </div>
     </div>
-		<iframe
+    <iframe
       allow="camera *; microphone *;display-capture;midi;encrypted-media;"
       src="https://beta.cloud.cocorobo.cn/browser/public/index.html"
       ref="iiframe"
@@ -869,7 +875,11 @@ ATTENTION: Use '##' to SPLIT SECTIONS, not '#'.Output format carefully reference
           let history = [];
           if (this.continuous) {
             this.array.forEach((i, index) => {
-              if (i.content) history.push({ role: "user", content: index == this.array.length - 1 ? message : i.content  });
+              if (i.content)
+                history.push({
+                  role: "user",
+                  content: index == this.array.length - 1 ? message : i.content
+                });
               if (i.aiContent)
                 history.push({ role: "assistant", content: i.aiContent });
             });
@@ -1030,7 +1040,10 @@ ATTENTION: Use '##' to SPLIT SECTIONS, not '#'.Output format carefully reference
     async getUserName() {
       let params = { uid: this.userid };
       try {
-        let res = await this.ajax.get(this.$store.state.api + "getUser", params);
+        let res = await this.ajax.get(
+          this.$store.state.api + "getUser",
+          params
+        );
         this.username = res.data[0][0].name;
       } catch (err) {
         console.error(err);
@@ -1039,10 +1052,10 @@ ATTENTION: Use '##' to SPLIT SECTIONS, not '#'.Output format carefully reference
     //保存消息
     async insertChat(_uid) {
       let _data = this.array.find(i => i.uid == _uid);
-      this.saveUid = ''
-      this.faloading = false
-      if(!this.username){
-        await this.getUserName()
+      this.saveUid = "";
+      this.faloading = false;
+      if (!this.username) {
+        await this.getUserName();
       }
       if (!_data) return;
       let params = {
@@ -1355,7 +1368,7 @@ ATTENTION: Use '##' to SPLIT SECTIONS, not '#'.Output format carefully reference
       this.isVoice = flag;
     },
     startVoice() {
-			let iiframe = this.$refs["iiframe"];
+      let iiframe = this.$refs["iiframe"];
       iiframe.contentWindow.window.document.getElementById(
         "languageOptions"
       ).selectedIndex = 2; //普通话
@@ -1367,20 +1380,27 @@ ATTENTION: Use '##' to SPLIT SECTIONS, not '#'.Output format carefully reference
         if (_msg) this.courseText += _msg;
       };
     },
-		stopVoice(){
-			if (!this.isTalk) return this.$message.info("请先开始录音");
-      let iiframe = this.$refs["iiframe"];
-      iiframe.contentWindow.window.document
-        .getElementById("scenarioStopButton")
-        .click();
-      iiframe.contentWindow.onSessionStopped = (s, e) => {
+    stopVoice() {
+      try {
+        if (!this.isTalk) return this.$message.info("请先开始录音");
+        let iiframe = this.$refs["iiframe"];
+        iiframe.contentWindow.window.document
+          .getElementById("scenarioStopButton")
+          .click();
+        iiframe.contentWindow.onSessionStopped = (s, e) => {
+          this.isTalk = false;
+          if (this.courseText) {
+            this.addContent();
+          }
+        };
+      } catch (error) {
+        console.log(error);
         this.isTalk = false;
-				if(this.courseText){
-					this.addContent();
-				}
-        
-      };
-		}
+        if (this.courseText) {
+          this.addContent();
+        }
+      }
+    }
   },
   computed: {
     pan() {

+ 18 - 17
src/components/pages/aiAddCourse/jsmind2.vue

@@ -221,19 +221,19 @@ export default {
       }
       let _eJson = {}
       for(var i = 0;i<listName.length;i++){
-        let item = listName[i]
-        _eJson[item] = {
+        let listItem = listName[i]
+        _eJson[listItem] = {
           child: {}
         }
         for(var j = 0;j<elist.length;j++){
           let item2 = elist[j]
-          if(item2.target == item){
-            if(_eJson[item].child[item2.detail]){
-              if(_eJson[item].child[item2.detail].child.indexOf(item2.index) == -1){
-                _eJson[item].child[item2.detail].child.push(item2.index)
+          if(item2.target == listItem){
+            if(_eJson[listItem].child[item2.detail]){
+              if(_eJson[listItem].child[item2.detail].child.indexOf(item2.index) == -1){
+                _eJson[listItem].child[item2.detail].child.push(item2.index)
               }
             }else{
-              _eJson[item].child[item2.detail] = {
+              _eJson[listItem].child[item2.detail] = {
                 child: [item2.index]
               }
             }
@@ -257,19 +257,20 @@ export default {
             parentid: _JsonName[i],
             topic: _eJsonz[j],
           })
-          let _eJsonz2 = Object.keys(item2.child)
+          // let _eJsonz2 = Object.keys(item2.child)
           let _e4 = item2.child
-          for(var z = 0;z<_eJsonz2.length;z++){
+          // for(var z = 0;z<_eJsonz2.length;z++){
             // let item3 = _e4[_eJsonz2[z]]
-            for(var zz = 0;zz<_e4.length;zz++){
-              data.data.push({
-                id: `${_eJsonz[j]}-${_eJsonz2[z]}-${zz}`,
-                parentid: _eJsonz[j],
-                topic: `工具${_e4[zz] + 1}`,
-              })
-            }
-
+          for(var zz = 0;zz<_e4.length;zz++){
+            data.data.push({
+              // id: `${_eJsonz[j]}-${_eJsonz2[z]}-${zz}`,
+              id: `${_eJsonz[j]}-${zz}`,
+              parentid: _eJsonz[j],
+              topic: `工具${_e4[zz] + 1}`,
+            })
           }
+
+          // }
           }
         }
       }

+ 18 - 11
src/components/pages/test/check/aiBoxRight.vue

@@ -1302,18 +1302,25 @@ export default {
       };
     },
 		stopVoice(){
-			if (!this.isTalk) return this.$message.info("请先开始录音");
-      let iiframe = this.$refs["iiframe"];
-      iiframe.contentWindow.window.document
-        .getElementById("scenarioStopButton")
-        .click();
-      iiframe.contentWindow.onSessionStopped = (s, e) => {
+			try {
+        if (!this.isTalk) return this.$message.info("请先开始录音");
+        let iiframe = this.$refs["iiframe"];
+        iiframe.contentWindow.window.document
+          .getElementById("scenarioStopButton")
+          .click();
+        iiframe.contentWindow.onSessionStopped = (s, e) => {
+          this.isTalk = false;
+          if (this.courseText) {
+            this.addContent();
+          }
+        };
+      } catch (error) {
+        console.log(error);
         this.isTalk = false;
-				if(this.courseText){
-					this.addContent();
-				}
-        
-      };
+        if (this.courseText) {
+          this.addContent();
+        }
+      }
 		}
   },
   computed: {

Some files were not shown because too many files changed in this diff