Ver Fonte

预览宽度改为 1000px

dusenyao há 1 ano atrás
pai
commit
61237fc4a6

+ 2 - 1
src/styles/variables.scss

@@ -18,7 +18,8 @@ $error-color: #f2555a;
 $right-color: #30a47d;
 $right-bc-color: #e8f7f2;
 $label-color: #076aff;
-$setting-active-color: #4176FF;
+$setting-active-color: #4176ff;
 
 // px
 $header-h: 64px;
+$courseware-width: 1000px;

+ 5 - 1
src/views/book/chapter.vue

@@ -171,7 +171,11 @@ export default {
       this.visibleStatus = false;
     },
     addCoursewareToBook() {
-      AddCoursewareToBook({ book_id: this.book_id, chapter_id: this.curChapterId, name: '教材内容' }).then(() => {
+      AddCoursewareToBook({
+        book_id: this.book_id,
+        chapter_id: this.curChapterId,
+        name: `教材内容${this.coursewareDataList.length + 1}`,
+      }).then(() => {
         this.getCoursewareList_Chapter(this.curChapterId);
         this.$message.success('添加成功');
       });

+ 2 - 1
src/views/book/components/catalogueTree.vue

@@ -2,7 +2,8 @@
   <div class="node-wrapper">
     <div v-for="node in nodes" :key="node.id" :class="['node', { active: getCurChapterId() === node.id }]">
       <div
-        :class="['node-name', { content: node.is_leaf_chapter === 'true' }]"
+        :class="['node-name', 'nowrap-ellipsis', { content: node.is_leaf_chapter === 'true' }]"
+        :title="node.name"
         @click="handleSelectNode(node.is_leaf_chapter, node.id)"
       >
         <span>{{ node.name }}</span>

+ 1 - 1
src/views/book/courseware/create/components/CreateCanvas.vue

@@ -845,7 +845,7 @@ export default {
   display: flex;
   flex-direction: column;
   row-gap: 6px;
-  width: 1100px;
+  width: $courseware-width;
   min-height: calc(100% - 56px);
   padding: 24px;
   margin: 0 auto;

+ 1 - 1
src/views/book/courseware/preview/CoursewarePreview.vue

@@ -188,7 +188,7 @@ export default {
   display: flex;
   flex-direction: column;
   row-gap: 6px;
-  width: 1100px;
+  width: $courseware-width;
   min-height: 500px;
   padding: 24px;
   background-color: #fff;

+ 2 - 26
src/views/book/courseware/preview/index.vue

@@ -15,7 +15,7 @@
             <SvgIcon icon-class="menu-2" size="24" />
             <template v-for="(item, m) in menuList">
               <span :key="m">{{ item }}</span>
-              <span v-if="index < menuList.length - 1" :key="`separator-${m}`" class="separator">/</span>
+              <span v-if="m < menuList.length - 1" :key="`separator-${m}`" class="separator">/</span>
             </template>
           </span>
           <CoursewarePreview :data="data" />
@@ -306,7 +306,7 @@ export default {
     }
 
     .content {
-      width: 1106px;
+      width: calc($courseware-width + 6px);
       margin: 24px auto 0;
       background-color: #fff;
       border: 3px solid #f44444;
@@ -325,30 +325,6 @@ export default {
         border-top-left-radius: 12px;
         border-bottom-right-radius: 16px;
       }
-
-      .courserware {
-        display: flex;
-        flex-direction: column;
-        row-gap: 6px;
-        width: 100%;
-        min-height: 500px;
-        padding: 24px;
-        background-color: #fff;
-        background-repeat: no-repeat;
-        border-bottom-right-radius: 12px;
-        border-bottom-left-radius: 12px;
-
-        .row {
-          display: grid;
-          gap: 16px;
-
-          .col {
-            display: grid;
-            gap: 16px;
-            overflow: auto;
-          }
-        }
-      }
     }
   }
 }

+ 2 - 0
src/views/home/index.vue

@@ -134,9 +134,11 @@ export default {
     },
     changePage(number) {
       this.cur_page = number;
+      this.pageQueryBookList();
     },
     changePageSize(size) {
       this.page_capacity = size;
+      this.pageQueryBookList();
     },
     // 分页查询教材列表
     pageQueryBookList() {