guanchunjie 3 years ago
parent
commit
87757575fe
4 changed files with 30 additions and 2 deletions
  1. 1 1
      package.json
  2. 14 0
      src/views/bookView.vue
  3. 14 0
      src/views/courseView.vue
  4. 1 1
      vue.config.js

+ 1 - 1
package.json

@@ -18,7 +18,7 @@
     "@ztree/ztree_v3": "^3.5.46",
     "awe-dnd": "^0.3.4",
     "axios": "0.18.1",
-    "book-ui": "file:../GCLS-Book-question-ui/book-ui-0.1.6.tgz",
+    "book-ui": "file:../GCLS-Book-question-ui/book-ui-0.1.8.tgz",
     "cnchar": "^3.0.1",
     "cnchar-all": "^3.0.1",
     "cnchar-order": "^3.0.1",

+ 14 - 0
src/views/bookView.vue

@@ -66,6 +66,18 @@
             :isShowTitle="true"
           />
         </template>
+        <template v-if="category == 'NNPE'">
+          <Booknnpe
+            v-if="chapterId && context"
+            ref="previewAnswer"
+            :context="context"
+            :currentTreeID="chapterId"
+            :FatherTreeData="FatherTreeData"
+            :change-id="changeId"
+            :themeColor="themeColor"
+            :isShowTitle="true"
+          />
+        </template>
       </div>
       <a
         v-if="chapterId && treeFlag"
@@ -180,6 +192,8 @@ export default {
             };
           } else if (this.category == "NPC") {
             _this.context = JSON.parse(res.content);
+          } else if (this.category == "NNPE") {
+            _this.context = JSON.parse(res.content);
           }
         } else {
           const _this = this;

+ 14 - 0
src/views/courseView.vue

@@ -54,6 +54,18 @@
             :isShowTitle="true"
           />
         </template>
+        <template v-if="category == 'NNPE'">
+          <Booknnpe
+            v-if="chapterId && context"
+            ref="previewAnswer"
+            :context="context"
+            :currentTreeID="chapterId"
+            :FatherTreeData="FatherTreeData"
+            :change-id="changeId"
+            :themeColor="themeColor"
+            :isShowTitle="true"
+          />
+        </template>
       </div>
     </div>
     <!-- <Preview :context="context" :queIndex="queIndex" /> -->
@@ -144,6 +156,8 @@ export default {
             };
           } else if (this.category == "NPC") {
             _this.context = JSON.parse(res.content);
+          } else if (this.category == "NNPE") {
+            _this.context = JSON.parse(res.content);
           }
         } else {
           const _this = this;

+ 1 - 1
vue.config.js

@@ -42,7 +42,7 @@ module.exports = {
       // change xxx-api/login => mock/login
       // detail: https://cli.vuejs.org/config/#devserver-proxy
       [process.env.VUE_APP_BASE_API]: {
-        target: `http://gcls.helxsoft.cn/`,
+        target: `http://gcls.utschool.cn/`,
         changeOrigin: true,
         pathRewrite: {
           ['^' + process.env.VUE_APP_BASE_API]: ''