Jelajahi Sumber

安装 eep-ui 包

dsy 5 hari lalu
induk
melakukan
741d483619

+ 13 - 4
package-lock.json

@@ -11,9 +11,10 @@
         "@tinymce/tinymce-vue": "^3.2.8",
         "awe-dnd": "^0.3.4",
         "axios": "^1.6.8",
-        "book-ui": "file:../book-ui-0.3.110.tgz",
+        "book-ui": "file:../GCLS-Book-UI/book-ui-0.4.31.tgz",
         "core-js": "^3.36.1",
         "dayjs": "^1.11.10",
+        "eep-ui": "file:../eep_page/packages/eep-ui-0.0.10.tgz",
         "element-ui": "^2.15.14",
         "jquery": "^3.7.1",
         "js-base64": "^3.7.7",
@@ -6085,9 +6086,9 @@
       }
     },
     "node_modules/book-ui": {
-      "version": "0.3.109",
-      "resolved": "file:../book-ui-0.3.110.tgz",
-      "integrity": "sha512-aTzxsg+SkzM6VRJ0OgX5A64Ij/fBvy7pZeduJ0RtsdmnipWYWF+qbQ1jVpZKuRndxzPUV96sOgKiEclR6O64UQ==",
+      "version": "0.4.31",
+      "resolved": "file:../GCLS-Book-UI/book-ui-0.4.31.tgz",
+      "integrity": "sha512-iKckZvYpBtHoEtOuAD3oUSuz09PBibUCjRoUXTdSOtflzGN4GMKFsHVoTlLS65IgJIk/vkXlL12sy+Ko3MutAQ==",
       "dependencies": {
         "awe-dnd": "^0.3.4",
         "axios": "^0.21.1",
@@ -8641,6 +8642,14 @@
       "integrity": "sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==",
       "dev": true
     },
+    "node_modules/eep-ui": {
+      "version": "0.0.9",
+      "resolved": "file:../eep_page/packages/eep-ui-0.0.10.tgz",
+      "integrity": "sha512-KvGm26AtDmVaa0XNgz02ItzkT2B47q/ALxjT4JsO7H8lJFMGs/fKVAsajhdtYv+F8WPMThAxvKHLD21OLjMjug==",
+      "peerDependencies": {
+        "vue": "^2.6.14"
+      }
+    },
     "node_modules/electron-to-chromium": {
       "version": "1.4.710",
       "resolved": "https://registry.npmmirror.com/electron-to-chromium/-/electron-to-chromium-1.4.710.tgz",

+ 2 - 1
package.json

@@ -16,9 +16,10 @@
     "@tinymce/tinymce-vue": "^3.2.8",
     "awe-dnd": "^0.3.4",
     "axios": "^1.6.8",
-    "book-ui": "file:../book-ui-0.3.130.tgz",
+    "book-ui": "file:../GCLS-Book-UI/book-ui-0.4.31.tgz",
     "core-js": "^3.36.1",
     "dayjs": "^1.11.10",
+    "eep-ui": "file:../GCLS-Book-UI/eep-ui-0.0.9.tgz",
     "element-ui": "^2.15.14",
     "jquery": "^3.7.1",
     "js-base64": "^3.7.7",

+ 16 - 0
src/components/course/CompletionView.vue

@@ -72,6 +72,16 @@
         :book-answer-content="bookAnswerContent"
       />
     </template>
+    <template v-if="category == 'EEP'">
+      <BookEep
+        v-if="content.content && curCoursewareId"
+        :id="curCoursewareId"
+        :content="content.content"
+        :content-group-row-list="content.content_group_row_list"
+        :component-list="content.component_list"
+        :book-background="content.background"
+      ></BookEep>
+    </template>
 
     <div slot="footer"></div>
   </el-dialog>
@@ -166,6 +176,12 @@ export default {
               this.context = JSON.parse(content);
               return;
             }
+
+            if (category === 'EEP') {
+              this.dialogWidth = '1250px';
+              this.content = JSON.parse(content);
+              return;
+            }
           }
         );
       });

+ 16 - 0
src/components/course/FinishCourseware.vue

@@ -67,6 +67,16 @@
         @finishTaskMaterial="finishMyTaskMaterial_Student"
       />
     </template>
+    <template v-if="category == 'EEP'">
+      <BookEep
+        v-if="content.content && coursewareId"
+        :id="coursewareId"
+        :content="content.content"
+        :content-group-row-list="content.content_group_row_list"
+        :component-list="content.component_list"
+        :book-background="content.background"
+      ></BookEep>
+    </template>
 
     <div v-if="category !== 'NPC' && category !== 'NNPE' && category !== 'RLC' && category !== 'NEW'" slot="footer">
       <el-button type="primary" @click="finishTaskMaterial">
@@ -156,6 +166,12 @@ export default {
             this.context = JSON.parse(content);
             return;
           }
+
+          if (category === 'EEP') {
+            this.dialogWidth = '1250px';
+            this.content = JSON.parse(content);
+            return;
+          }
         }
       );
     }

+ 5 - 1
src/components/course/courseware.js

@@ -2,7 +2,7 @@ import { ref, unref } from 'vue';
 import { GetCoursewareContent_View } from '@/api/course';
 import { Message } from 'element-ui';
 
-const categoryList = ['OC', 'AILP', 'NPC', 'NNPE', 'RLC', 'NEW'];
+const categoryList = ['OC', 'AILP', 'NPC', 'NNPE', 'RLC', 'NEW', 'EEP']; // 课件类型列表
 
 /**
  * 显示课件
@@ -51,6 +51,10 @@ export function useShowCourseware(courseId, groupId = '[]', previewType = 'previ
           context.value = JSON.parse(content);
           return;
         }
+        if (category.value === categoryList[6]) {
+          context.value = JSON.parse(content);
+          return;
+        }
       }
     );
   }

+ 16 - 0
src/components/live/CurMaterial.vue

@@ -97,6 +97,17 @@
           @finishTaskMaterial="saveNPCAnswer"
         />
       </template>
+
+      <template v-if="category == 'EEP'">
+        <BookEep
+          v-if="content.content && material_id"
+          :id="material_id"
+          :content="content.content"
+          :content-group-row-list="content.content_group_row_list"
+          :component-list="content.component_list"
+          :book-background="content.background"
+        ></BookEep>
+      </template>
     </template>
 
     <template v-else>
@@ -315,6 +326,11 @@ export default {
             this.context = JSON.parse(content);
             return;
           }
+
+          if (category === 'EEP') {
+            this.content = JSON.parse(content);
+            return;
+          }
         })
         .then(() => {
           if (this.isFinished && !this.isCurMaterial) {

+ 15 - 0
src/components/preview/PreviewCourse.vue

@@ -47,6 +47,16 @@
       <template v-if="category === 'NEW'">
         <BookNew v-if="context" ref="book" :context="context" :current-tree-i-d="fileId" :is-show-save="false" />
       </template>
+      <template v-if="category == 'EEP'">
+        <BookEep
+          v-if="content.content && fileId"
+          :id="fileId"
+          :content="content.content"
+          :content-group-row-list="content.content_group_row_list"
+          :component-list="content.component_list"
+          :book-background="content.background"
+        ></BookEep>
+      </template>
     </template>
 
     <template v-else-if="fileType === 'file'">
@@ -167,6 +177,11 @@ function getCoursewareContent_View() {
         context.value = JSON.parse(content);
         return;
       }
+
+      if (category.value === 'EEP') {
+        context.value = JSON.parse(content);
+        return;
+      }
     }
   );
 }

+ 10 - 0
src/components/select/SelectCourse.vue

@@ -68,6 +68,16 @@
         <template v-if="category === 'NEW'">
           <BookNew v-if="context" ref="book" :context="context" :current-tree-i-d="courseID" :is-show-save="false" />
         </template>
+        <template v-if="category == 'EEP'">
+          <BookEep
+            v-if="content.content && courseID"
+            :id="courseID"
+            :content="content.content"
+            :content-group-row-list="content.content_group_row_list"
+            :component-list="content.component_list"
+            :book-background="content.background"
+          ></BookEep>
+        </template>
       </div>
     </div>
 

+ 4 - 0
src/main.js

@@ -31,10 +31,14 @@ import '@/permission'; // 权限控制
 
 import '@/components/globalComponents';
 
+import EepUi from 'eep-ui';
+import 'eep-ui/style.css';
+
 Vue.use(ElementUI);
 Vue.use(BookUI);
 Vue.use(VideoPlayer);
 Vue.use(VueDND);
+Vue.use(EepUi);
 
 Vue.config.productionTip = false;
 

+ 15 - 0
src/views/live/teacher/CompleteList.vue

@@ -107,6 +107,16 @@
             :book-answer-content="bookAnswerContent"
           />
         </template>
+        <template v-if="category == 'EEP'">
+          <BookEep
+            v-if="content.content && material_id"
+            :id="material_id"
+            :content="content.content"
+            :content-group-row-list="content.content_group_row_list"
+            :component-list="content.component_list"
+            :book-background="content.background"
+          ></BookEep>
+        </template>
       </template>
       <template v-else>
         <div v-loading="file_loading">
@@ -305,6 +315,11 @@ export default {
             this.context = JSON.parse(content);
             return;
           }
+          if (category === 'EEP') {
+            this.dialogWidth = '1250';
+            this.context = JSON.parse(content);
+            return;
+          }
         }
       );
     },

+ 16 - 0
src/views/new_live/teacher/components/CompleteList.vue

@@ -107,6 +107,16 @@
             :book-answer-content="bookAnswerContent"
           />
         </template>
+        <template v-if="category == 'EEP'">
+          <BookEep
+            v-if="content.content && material_id"
+            :id="material_id"
+            :content="content.content"
+            :content-group-row-list="content.content_group_row_list"
+            :component-list="content.component_list"
+            :book-background="content.background"
+          ></BookEep>
+        </template>
       </template>
       <template v-else>
         <div v-loading="file_loading">
@@ -305,6 +315,12 @@ export default {
             this.context = JSON.parse(content);
             return;
           }
+
+          if (category === 'EEP') {
+            this.dialogWidth = '1250';
+            this.context = JSON.parse(content);
+            return;
+          }
         }
       );
     },

+ 10 - 0
src/views/new_task_view/components/common/CoursewareView.vue

@@ -63,6 +63,16 @@
         @finishTaskMaterial="saveNPCAnswer"
       />
     </template>
+    <template v-if="category == 'EEP'">
+      <BookEep
+        v-if="content.content && coursewareData.courseware_id"
+        :id="coursewareData.courseware_id"
+        :content="content.content"
+        :content-group-row-list="content.content_group_row_list"
+        :component-list="content.component_list"
+        :book-background="content.background"
+      ></BookEep>
+    </template>
   </div>
 </template>
 

+ 15 - 0
src/views/task_details/ShowCourseware.vue

@@ -55,6 +55,16 @@
           :is-show-save="false"
         />
       </template>
+      <template v-if="category == 'EEP'">
+        <BookEep
+          v-if="content.content && coursewareId"
+          :id="coursewareId"
+          :content="content.content"
+          :content-group-row-list="content.content_group_row_list"
+          :component-list="content.component_list"
+          :book-background="content.background"
+        ></BookEep>
+      </template>
     </div>
   </div>
 </template>
@@ -110,6 +120,11 @@ export default {
           this.context = JSON.parse(content);
           return;
         }
+
+        if (category === 'EEP') {
+          this.context = JSON.parse(content);
+          return;
+        }
       }
     );
   },

+ 10 - 0
src/views/teacher/create_course/step_three/components/preview/task_preview/components/CoursewareView.vue

@@ -54,6 +54,16 @@
           :is-show-save="false"
         />
       </template>
+      <template v-if="category == 'EEP'">
+        <BookEep
+          v-if="content.content && coursewareId"
+          :id="coursewareId"
+          :content="content.content"
+          :content-group-row-list="content.content_group_row_list"
+          :component-list="content.component_list"
+          :book-background="content.background"
+        ></BookEep>
+      </template>
     </template>
   </div>
 </template>