natasha 2 лет назад
Родитель
Сommit
b1e34dfc69

+ 24 - 16
src/components/Header.vue

@@ -174,10 +174,16 @@ export default {
       visible: false,
       visibleOption: false,
       corpus: {
-        difficlty: localStorage.getItem('seekPageData')?JSON.parse(localStorage.getItem('seekPageData')).difficlty:null,
-        scope: localStorage.getItem('seekPageData')?JSON.parse(localStorage.getItem('seekPageData')).scope:null,
-        sentenceStart: localStorage.getItem('seekPageData')?JSON.parse(localStorage.getItem('seekPageData')).sentenceStart:null,
-        sentenceEnd: localStorage.getItem('seekPageData')?JSON.parse(localStorage.getItem('seekPageData')).sentenceEnd:null,
+        difficlty: localStorage.getItem('seekPageData')
+          ? JSON.parse(localStorage.getItem('seekPageData')).difficlty
+          : null,
+        scope: localStorage.getItem('seekPageData') ? JSON.parse(localStorage.getItem('seekPageData')).scope : null,
+        sentenceStart: localStorage.getItem('seekPageData')
+          ? JSON.parse(localStorage.getItem('seekPageData')).sentenceStart
+          : null,
+        sentenceEnd: localStorage.getItem('seekPageData')
+          ? JSON.parse(localStorage.getItem('seekPageData')).sentenceEnd
+          : null,
       },
       activeIndex: '2', // 主导航索引
       LoginNavIndex: 0, // 下拉框导航索引
@@ -308,12 +314,14 @@ export default {
         this.$message.warning('请输入要搜索的内容');
         return;
       }
-      this.$router.replace({
-        path: '/corpus/Result',
-        query: {
-          keyword: this.keyword,
-        },
-      }).catch(err => err);
+      this.$router
+        .replace({
+          path: '/corpus/Result',
+          query: {
+            keyword: this.keyword,
+          },
+        })
+        .catch((err) => err);
       this.$emit('changehzdata');
     },
     // 前往个人中心
@@ -421,12 +429,12 @@ export default {
         });
     },
     // 存储句长信息
-    sureCorpus(){
-      this.visibleOption = false
-      this.visible = false
-      localStorage.setItem('seekPageData',JSON.stringify(this.corpus))
-      if(this.seekOptions) this.seekresult()
-    }
+    sureCorpus() {
+      this.visibleOption = false;
+      this.visible = false;
+      localStorage.setItem('seekPageData', JSON.stringify(this.corpus));
+      if (this.seekOptions) this.seekresult();
+    },
   },
 };
 </script>

+ 2 - 2
src/permission.js

@@ -19,11 +19,11 @@ router.beforeEach(async (to, from, next) => {
   NProgress.done()
   const hasToken = getToken()
 
-  if (hasToken) {
+  if (hasToken || to.path === '/Integration/TextAnalyser') {
     //=======重点部分以下=======
 
     let config = getConfig();
-    if (config) {
+    if (config || to.path === '/Integration/TextAnalyser') {
       if (to.path === '/login') {
         // if is logged in, redirect to the home page
         next({ path: '/EnterSys' })

+ 7 - 0
src/router/index.js

@@ -76,6 +76,13 @@ const routes = [{
             import ('../views/teacher-dev/TextAnalysis.vue'),
     },
     {
+        path: '/Integration/TextAnalyser',
+        name: 'IntegrationTextAnalysis',
+        meta: { title: '', keepAlive: false },
+        component: () =>
+            import ('../views/teacher-dev/TextAnalysis.vue'),
+    },
+    {
         path: '/teacherdevEntering',
         name: 'teacherdevEntering',
         meta: { title: '', keepAlive: false },

+ 128 - 129
src/views/Textanalysis/WordTable.vue

@@ -43,14 +43,16 @@
             collapse-tags
             style="width: 180px; margin-right: 24px"
             placeholder="请选择"
-            @change="page1getdata">
-            <el-checkbox class="checkAllCheckbox" :indeterminate="isIndeterminate" v-model="checkAll" @change="handleCheckAllChange">全部</el-checkbox>
-            <el-option
-                v-for="item in levelList"
-                :key="item.value"
-                :label="item.label"
-                :value="item.value">
-            </el-option>
+            @change="page1getdata"
+          >
+            <el-checkbox
+              class="checkAllCheckbox"
+              :indeterminate="isIndeterminate"
+              v-model="checkAll"
+              @change="handleCheckAllChange"
+              >全部</el-checkbox
+            >
+            <el-option v-for="item in levelList" :key="item.value" :label="item.label" :value="item.value"> </el-option>
           </el-select>
           <div class="seek">
             <img src="../../assets/teacherdev/search-icon.png" alt="" />
@@ -112,7 +114,7 @@
                   fontWeight: '400',
                   fontSize: '18px',
                   color: item.level_id && levelMap[item.level_id] ? levelMap[item.level_id].color : '',
-                  cursor: typeIndex !== 0 ?'pointer' : ''
+                  cursor: typeIndex !== 0 ? 'pointer' : '',
                 }"
                 @click="backHighlight(item, levelMap[item.level_id].color, 'all', index, typeIndex)"
                 >{{ item.word }}</span
@@ -158,10 +160,8 @@
                   :style="{
                     marginRight: '10px',
                     cursor: 'pointer',
-                    borderColor:
-                      items.levelId && levelMap[items.levelId] ? levelMap[items.levelId].color + '16' : '',
-                    background:
-                      items.levelId && levelMap[items.levelId] ? levelMap[items.levelId].color + '50' : '',
+                    borderColor: items.levelId && levelMap[items.levelId] ? levelMap[items.levelId].color + '16' : '',
+                    background: items.levelId && levelMap[items.levelId] ? levelMap[items.levelId].color + '50' : '',
                   }"
                   @click="backHighlight(items, levelMap[items.levelId].color, 'one', index)"
                 >
@@ -431,7 +431,7 @@ export default {
       routerData: null,
       alldata: null,
       id: '',
-      allLevels: []
+      allLevels: [],
     };
   },
   // 生命周期 - 创建完成(可以访问当前this实例)
@@ -439,15 +439,15 @@ export default {
     this.routerData = JSON.parse(JSON.stringify(this.$route.query));
 
     this.partition_key = Number(this.$route.query.partition_key);
-    this.id = this.routerData.id
-    this.getLevelList()
+    this.id = this.routerData.id;
+    this.getLevelList();
     this.getlist();
   },
   methods: {
     // 下载
     download() {
       let data = JSON.parse(JSON.stringify(this.alldata));
-      data.forEach((item,index) => {
+      data.forEach((item, index) => {
         item.text_ratio += '%';
         let str = '';
         // 处理备注
@@ -457,7 +457,7 @@ export default {
           str += `${node.innerText} ${items.levelName} ${items.freq}      `;
         });
         item.remarksTxt = str;
-        item.number = index+1
+        item.number = index + 1;
       });
       let tHeader = [];
       let filterVal = [];
@@ -484,8 +484,8 @@ export default {
     },
     // 返回并高亮对应数据
     backHighlight(item, color, type, index, typeIndex) {
-      if(typeIndex===0){
-        return
+      if (typeIndex === 0) {
+        return;
       }
       let data = JSON.parse(JSON.stringify(this.routerData));
       let arr = [];
@@ -500,7 +500,7 @@ export default {
       } else if (this.typeIndex === 0) {
         arr.push(item.word);
       } else {
-        let matchStr = item.word.replace(/<span style='color:red;'>/g, "").replace(/<\/span>/g, "");
+        let matchStr = item.word.replace(/<span style='color:red;'>/g, '').replace(/<\/span>/g, '');
         arr.push(matchStr);
       }
       data.remarks = JSON.stringify(arr);
@@ -521,59 +521,58 @@ export default {
       this.getlist();
     },
     // 获取等级列表
-    getLevelList(){
-        this.allLevels = []
-        // this.levelList = [{
-        //     value: '',
-        //     id: '',
-        //     name: '全部',
-        //     label: '全部'
-        // }]
-        this.levelList = []
-        publicMethods('/TeachingServer/TextAnalyser/GetLevelList',{})
-        .then((res) => {
-          if(res.status===1){
-            res.level_list.forEach(item=>{
-                item.value = item.id
-                item.label = item.name
-                this.allLevels.push(item.id)
-            })
-            this.levelList = this.levelList.concat(res.level_list)
-          }
-        })
+    getLevelList() {
+      this.allLevels = [];
+      // this.levelList = [{
+      //     value: '',
+      //     id: '',
+      //     name: '全部',
+      //     label: '全部'
+      // }]
+      this.levelList = [];
+      publicMethods('/TeachingServer/TextAnalyser/GetLevelList', {}).then((res) => {
+        if (res.status === 1) {
+          res.level_list.forEach((item) => {
+            item.value = item.id;
+            item.label = item.name;
+            this.allLevels.push(item.id);
+          });
+          this.levelList = this.levelList.concat(res.level_list);
+        }
+      });
     },
     getlist() {
       this.loading = true;
-      let order_column_list = []
-      if(this.sortType===1){
-        order_column_list = [this.sortField + ':desc']
-      }else if(this.sortType===0){
+      let order_column_list = [];
+      if (this.sortType === 1) {
+        order_column_list = [this.sortField + ':desc'];
+      } else if (this.sortType === 0) {
         // 升序不传值
-        order_column_list = [this.sortField]
+        order_column_list = [this.sortField];
       }
       let data = {
-          cur_page: this.page,
-          page_capacity: this.pageSize,
-          type: this.typeIndex,
-          word: this.keyword,
-          order_column_list: order_column_list,
-          level_id_list: this.level ,
-          analyse_record_id: this.id
-      }
-      publicMethods('/TeachingServer/TextAnalyser/PageQueryWordList',data)
-    //   postapi({
-    //     url: '/GCLSTCServer/tools/TS/glossary/list',
-    //     data: {
-    //       pageIndex: this.page,
-    //       pageSize: this.pageSize,
-    //       partitionKey: this.partition_key,
-    //       searchType: this.typeIndex,
-    //       word: this.keyword,
-    //       sortField: this.sortField,
-    //       sortType: this.sortType,
-    //       levels: this.level ? this.level[1] : null,
-    //     },
-    //   })
+        cur_page: this.page,
+        page_capacity: this.pageSize,
+        type: this.typeIndex,
+        word: this.keyword,
+        order_column_list: order_column_list,
+        level_id_list: this.level,
+        analyse_record_id: this.id,
+      };
+      publicMethods('/TeachingServer/TextAnalyser/PageQueryWordList', data)
+        //   postapi({
+        //     url: '/GCLSTCServer/tools/TS/glossary/list',
+        //     data: {
+        //       pageIndex: this.page,
+        //       pageSize: this.pageSize,
+        //       partitionKey: this.partition_key,
+        //       searchType: this.typeIndex,
+        //       word: this.keyword,
+        //       sortField: this.sortField,
+        //       sortType: this.sortType,
+        //       levels: this.level ? this.level[1] : null,
+        //     },
+        //   })
         .then((res) => {
           let num = this.page * this.pageSize - this.pageSize + 1;
           res.word_list.forEach((item) => {
@@ -587,40 +586,40 @@ export default {
         .catch(() => {
           this.loading = false;
         });
-    publicMethods('/TeachingServer/TextAnalyser/PageQueryWordList',{
+      publicMethods('/TeachingServer/TextAnalyser/PageQueryWordList', {
         cur_page: 1,
         page_capacity: 9999,
         type: this.typeIndex,
         word: this.keyword,
         order_column_list: order_column_list,
-        level_id_list: this.level ,
-        analyse_record_id: this.id
-    })
-    //   postapi({
-    //     url: '/GCLSTCServer/tools/TS/glossary/list',
-    //     data: {
-    //       pageIndex: 1,
-    //       pageSize: 9999,
-    //       partitionKey: this.partition_key,
-    //       searchType: this.typeIndex,
-    //       word: this.keyword,
-    //       sortField: this.sortField,
-    //       sortType: this.sortType,
-    //       levels: this.level ? this.level[1] : null,
-    //     },
-    //   })
-    .then((res) => {
-        let num = 0;
-        res.word_list.forEach((item) => {
-          item.remarks = JSON.parse(item.remarks);
-          item.number = num;
-          num += 1;
+        level_id_list: this.level,
+        analyse_record_id: this.id,
+      })
+        //   postapi({
+        //     url: '/GCLSTCServer/tools/TS/glossary/list',
+        //     data: {
+        //       pageIndex: 1,
+        //       pageSize: 9999,
+        //       partitionKey: this.partition_key,
+        //       searchType: this.typeIndex,
+        //       word: this.keyword,
+        //       sortField: this.sortField,
+        //       sortType: this.sortType,
+        //       levels: this.level ? this.level[1] : null,
+        //     },
+        //   })
+        .then((res) => {
+          let num = 0;
+          res.word_list.forEach((item) => {
+            item.remarks = JSON.parse(item.remarks);
+            item.number = num;
+            num += 1;
+          });
+          this.alldata = res.word_list;
         });
-        this.alldata = res.word_list;
-      });
     },
     page1getdata(value) {
-      if(value){
+      if (value) {
         let checkedCount = value.length;
         this.checkAll = checkedCount === this.levelList.length;
         this.isIndeterminate = checkedCount > 0 && checkedCount < this.levelList.length;
@@ -674,8 +673,8 @@ export default {
       this.page1getdata();
     },
     handleCheckAllChange(val) {
-        this.level = val ? this.allLevels : [];
-        this.isIndeterminate = false;
+      this.level = val ? this.allLevels : [];
+      this.isIndeterminate = false;
     },
   },
 };
@@ -693,25 +692,25 @@ export default {
   .main {
     width: 1200px;
     margin: 23px auto;
-    .go-back{
-        border-radius: 4px;
-        border: 1px solid #D9D9D9;
-        background: #FFF;
-        box-shadow: 0px 2px 0px 0px rgba(0, 0, 0, 0.02);
-        display: flex;
-        width: 60px;
-        color: #333;
-        font-size: 14px;
-        font-weight: 400;
-        line-height: 22px;
-        padding: 9px 8px;
-        align-items: center;
-        cursor: pointer;
-        margin-bottom: 16px;
-        .el-icon-arrow-left{
-            font-size: 16px;
-            margin-right: 8px;
-        }
+    .go-back {
+      border-radius: 4px;
+      border: 1px solid #d9d9d9;
+      background: #fff;
+      box-shadow: 0px 2px 0px 0px rgba(0, 0, 0, 0.02);
+      display: flex;
+      width: 60px;
+      color: #333;
+      font-size: 14px;
+      font-weight: 400;
+      line-height: 22px;
+      padding: 9px 8px;
+      align-items: center;
+      cursor: pointer;
+      margin-bottom: 16px;
+      .el-icon-arrow-left {
+        font-size: 16px;
+        margin-right: 8px;
+      }
     }
     .top {
       display: flex;
@@ -999,19 +998,19 @@ export default {
     border-radius: 2px;
   }
 }
-.checkAllCheckbox{
-    width: 100%;
-    padding: 0 20px;  
-    height: 34px;
-    line-height: 34px;
-    &:hover{
-        background-color: #F5F7FA;
-    }
-    .el-checkbox__input{
-        display: none;
-    }
-    .el-checkbox__label{
-        padding: 0;
-    }
+.checkAllCheckbox {
+  width: 100%;
+  padding: 0 20px;
+  height: 34px;
+  line-height: 34px;
+  &:hover {
+    background-color: #f5f7fa;
+  }
+  .el-checkbox__input {
+    display: none;
+  }
+  .el-checkbox__label {
+    padding: 0;
+  }
 }
 </style>

+ 311 - 239
src/views/corpus/Result.vue

@@ -10,20 +10,22 @@
     <div class="main">
       <div class="hanzi_list">
         <el-select
-            class="selectBook"
-            v-model="level"
-            multiple
-            collapse-tags
-            placeholder="请选择"
-            @change="page1getdata">
-            <el-checkbox class="checkAllCheckbox" :indeterminate="isIndeterminate" v-model="checkAll" @change="handleCheckAllChange">全部</el-checkbox>
-            <el-option
-                v-for="item in levelList"
-                :key="item.value"
-                :label="item.label"
-                :value="item.value">
-            </el-option>
-          </el-select>
+          class="selectBook"
+          v-model="level"
+          multiple
+          collapse-tags
+          placeholder="请选择"
+          @change="page1getdata"
+        >
+          <el-checkbox
+            class="checkAllCheckbox"
+            :indeterminate="isIndeterminate"
+            v-model="checkAll"
+            @change="handleCheckAllChange"
+            >全部</el-checkbox
+          >
+          <el-option v-for="item in levelList" :key="item.value" :label="item.label" :value="item.value"> </el-option>
+        </el-select>
         <div class="top_jf">
           <div class="j_f">
             <div :class="[JFIndex == 0 ? 'sele' : '']" @click="jfEvent(0)">简</div>
@@ -33,7 +35,7 @@
         <div
           class="list_one_box"
           :style="{
-            overflowY: unfold ? 'scroll' : 'hidden'
+            overflowY: unfold ? 'scroll' : 'hidden',
           }"
           v-if="ShowHzData"
         >
@@ -47,7 +49,7 @@
               :isHighlight="false"
               :judgeAnswer="2"
             />
-            <div class="Highlight" v-if="item.hzDetail.hz_json&&item.hzDetail.hz_json.medians">
+            <div class="Highlight" v-if="item.hzDetail.hz_json && item.hzDetail.hz_json.medians">
               <div class="play_audio">
                 <!-- <img src="../../assets/teacherdev/speaker-one.png" alt="" /> -->
                 <span>{{ item.pinyin }}</span>
@@ -70,7 +72,7 @@
             </div>
           </div>
         </div>
-        <div class="shouqi" v-if="hzData&&hzData.length > 2">
+        <div class="shouqi" v-if="hzData && hzData.length > 2">
           <span @click="updownHz">
             <template v-if="unfold">
               <img src="../../assets/teacherdev/up.png" alt="" />
@@ -149,10 +151,18 @@
           <div class="main">
             <div class="list">
               <template v-if="patternIndex == 0">
-                <div class="lang_sort" :class="[sortType==='length'?'active':'']" @click="sortEvent('length')">
+                <div class="lang_sort" :class="[sortType === 'length' ? 'active' : '']" @click="sortEvent('length')">
                   按长度
-                  <img v-if="sort == 'down'&&sortType==='length'" src="../../assets/teacherdev/ylk-sort-up.png" alt="" />
-                  <img v-else-if="sort == 'up'&&sortType==='length'" src="../../assets/teacherdev/ylk-sort-down.png" alt="" />
+                  <img
+                    v-if="sort == 'down' && sortType === 'length'"
+                    src="../../assets/teacherdev/ylk-sort-up.png"
+                    alt=""
+                  />
+                  <img
+                    v-else-if="sort == 'up' && sortType === 'length'"
+                    src="../../assets/teacherdev/ylk-sort-down.png"
+                    alt=""
+                  />
                   <img v-else src="../../assets/teacherdev/ylk-sort-no.png" alt="" />
                 </div>
                 <div v-for="(item, i) in ShowList" :key="i + 'sentence'" class="one">
@@ -166,26 +176,26 @@
                      -->
                     <!-- <img src="../../assets/teacherdev/speaker-one.png" alt="" /> -->
                     <div class="words">
-                        <template v-if="item.sentence_fc_list_style&&item.sentence_fc_list_style.length>1">
-                            <span
-                                :style="{
-                                fontSize: conSize + 'px',
-                                padding: fenciShow?'0 2px':''
-                                }"
-                                v-for="(items,indexs) in item.sentence_fc_list_style"
-                                :key="indexs"
-                                v-html="items"
-                            ></span>
-                        </template>
-                        <template v-else>
-                            <span
-                                :style="{
-                                    fontSize: conSize + 'px',
-                                    padding: fenciShow?'0 2px':''
-                                }"
-                                v-html="item.res"
-                            ></span>
-                        </template>
+                      <template v-if="item.sentence_fc_list_style && item.sentence_fc_list_style.length > 1">
+                        <span
+                          :style="{
+                            fontSize: conSize + 'px',
+                            padding: fenciShow ? '0 2px' : '',
+                          }"
+                          v-for="(items, indexs) in item.sentence_fc_list_style"
+                          :key="indexs"
+                          v-html="items"
+                        ></span>
+                      </template>
+                      <template v-else>
+                        <span
+                          :style="{
+                            fontSize: conSize + 'px',
+                            padding: fenciShow ? '0 2px' : '',
+                          }"
+                          v-html="item.res"
+                        ></span>
+                      </template>
                       <template v-if="shiyiShow && item.word_definition_list.length > 0">
                         <span class="shiyi">
@@ -205,19 +215,43 @@
                 </div>
               </template>
               <template v-else>
-                <div style="display:flex">
-                    <div class="lang_sort" :class="[sortType==='zflength'?'active':'']" @click="sortEvent('zflength')">
+                <div style="display: flex">
+                  <div
+                    class="lang_sort"
+                    :class="[sortType === 'zflength' ? 'active' : '']"
+                    @click="sortEvent('zflength')"
+                  >
                     按字符
-                    <img v-if="sort == 'down'&&sortType==='zflength'" src="../../assets/teacherdev/ylk-sort-up.png" alt="" />
-                    <img v-else-if="sort == 'up'&&sortType==='zflength'" src="../../assets/teacherdev/ylk-sort-down.png" alt="" />
+                    <img
+                      v-if="sort == 'down' && sortType === 'zflength'"
+                      src="../../assets/teacherdev/ylk-sort-up.png"
+                      alt=""
+                    />
+                    <img
+                      v-else-if="sort == 'up' && sortType === 'zflength'"
+                      src="../../assets/teacherdev/ylk-sort-down.png"
+                      alt=""
+                    />
                     <img v-else src="../../assets/teacherdev/ylk-sort-no.png" alt="" />
-                    </div>
-                    <div class="lang_sort" :class="[sortType==='pclength'?'active':'']" @click="sortEvent('pclength')">
+                  </div>
+                  <div
+                    class="lang_sort"
+                    :class="[sortType === 'pclength' ? 'active' : '']"
+                    @click="sortEvent('pclength')"
+                  >
                     按频次
-                    <img v-if="sort == 'down'&&sortType==='pclength'" src="../../assets/teacherdev/ylk-sort-up.png" alt="" />
-                    <img v-else-if="sort == 'up'&&sortType==='pclength'" src="../../assets/teacherdev/ylk-sort-down.png" alt="" />
+                    <img
+                      v-if="sort == 'down' && sortType === 'pclength'"
+                      src="../../assets/teacherdev/ylk-sort-up.png"
+                      alt=""
+                    />
+                    <img
+                      v-else-if="sort == 'up' && sortType === 'pclength'"
+                      src="../../assets/teacherdev/ylk-sort-down.png"
+                      alt=""
+                    />
                     <img v-else src="../../assets/teacherdev/ylk-sort-no.png" alt="" />
-                    </div>
+                  </div>
                 </div>
                 <div v-for="(item, index) in ShowList" :key="'kwic' + index" class="kwic_one">
                   <div class="number">{{ item.number }}</div>
@@ -232,39 +266,51 @@
                   <div
                     class="word"
                     :style="{
-                      fontSize: conSize + 'px'
+                      fontSize: conSize + 'px',
                     }"
                   >
                     <div v-for="(txt, indexs) in item.resArr" :key="indexs">
-                      <div :style="{'padding':fenciShow?'0 2px':'','display':'inline-block'}" v-for="(txts, indext) in txt" :key="indext">
+                      <div
+                        :style="{ padding: fenciShow ? '0 2px' : '', display: 'inline-block' }"
+                        v-for="(txts, indext) in txt"
+                        :key="indext"
+                      >
                         <!-- <span v-html="txts"></span> -->
-                        <template v-if="sortType==='pclength'&&(KWIC_sortIndex === 0 || KWIC_sortIndex === 2)">
-                            <template v-if="indexs===0&&KWIC_sortIndex === 0">
-                                <el-tooltip effect="dark" placement="bottom" style="display:inline">
-                                    <div slot="content">
-                                        {{item.adjoin_fc_frequency_list_left&&item.adjoin_fc_frequency_list_left[indext]?item.adjoin_fc_frequency_list_left[indext]:1}}
-                                    </div>
-                                    <div class="">
-                                        <span v-html="txts"></span>
-                                    </div>
-                                </el-tooltip>
-                            </template>
-                            <template v-else-if="indexs===2&&KWIC_sortIndex === 2">
-                                <el-tooltip effect="dark" placement="bottom" style="display:inline">
-                                    <div slot="content">
-                                        {{item.adjoin_fc_frequency_list_right&&item.adjoin_fc_frequency_list_right[indext]?item.adjoin_fc_frequency_list_right[indext]:1}}
-                                    </div>
-                                    <div class="">
-                                        <span v-html="txts"></span>
-                                    </div>
-                                </el-tooltip>
-                            </template>
-                            <template v-else>
+                        <template v-if="sortType === 'pclength' && (KWIC_sortIndex === 0 || KWIC_sortIndex === 2)">
+                          <template v-if="indexs === 0 && KWIC_sortIndex === 0">
+                            <el-tooltip effect="dark" placement="bottom" style="display: inline">
+                              <div slot="content">
+                                {{
+                                  item.adjoin_fc_frequency_list_left && item.adjoin_fc_frequency_list_left[indext]
+                                    ? item.adjoin_fc_frequency_list_left[indext]
+                                    : 1
+                                }}
+                              </div>
+                              <div class="">
                                 <span v-html="txts"></span>
-                            </template>
+                              </div>
+                            </el-tooltip>
+                          </template>
+                          <template v-else-if="indexs === 2 && KWIC_sortIndex === 2">
+                            <el-tooltip effect="dark" placement="bottom" style="display: inline">
+                              <div slot="content">
+                                {{
+                                  item.adjoin_fc_frequency_list_right && item.adjoin_fc_frequency_list_right[indext]
+                                    ? item.adjoin_fc_frequency_list_right[indext]
+                                    : 1
+                                }}
+                              </div>
+                              <div class="">
+                                <span v-html="txts"></span>
+                              </div>
+                            </el-tooltip>
+                          </template>
+                          <template v-else>
+                            <span v-html="txts"></span>
+                          </template>
                         </template>
                         <template v-else>
-                            <span v-html="txts"></span>
+                          <span v-html="txts"></span>
                         </template>
                       </div>
                     </div>
@@ -273,14 +319,19 @@
               </template>
             </div>
             <div class="page">
-              <span class="text"> 共 {{ selectCurrent?selectCurrent:CurrentList.length }} 条 {{patternIndex === 0 && selectLaiyuanBookIdList.length===0?' 命中 '+scoreAHitNumber+' 次':''}} </span>
+              <span class="text">
+                共 {{ selectCurrent ? selectCurrent : CurrentList.length }} 条
+                {{
+                  patternIndex === 0 && selectLaiyuanBookIdList.length === 0 ? ' 命中 ' + scoreAHitNumber + ' 次' : ''
+                }}
+              </span>
               <el-pagination
                 background
                 @current-change="handleCurrentChange"
                 :current-page.sync="page"
                 :page-size="pageSize"
                 layout="prev, pager, next"
-                :total="selectCurrent?selectCurrent:CurrentList.length"
+                :total="selectCurrent ? selectCurrent : CurrentList.length"
                 :pager-count="5"
               >
               </el-pagination>
@@ -290,7 +341,13 @@
         <div class="right">
           <div class="top">
             <div>
-              <div v-if="allList.stat_list_word_definition&&allList.stat_list_word_definition.length>0" :class="[rightTopIndex == 0 ? 'sele' : '']" @click="cutsyly(0)">释义</div>
+              <div
+                v-if="allList.stat_list_word_definition && allList.stat_list_word_definition.length > 0"
+                :class="[rightTopIndex == 0 ? 'sele' : '']"
+                @click="cutsyly(0)"
+              >
+                释义
+              </div>
               <div :class="[rightTopIndex == 1 ? 'sele' : '']" @click="cutsyly(1)">来源</div>
             </div>
           </div>
@@ -302,7 +359,7 @@
               class="one"
               :style="{
                 borderBottom: i == rightList.length - 1 ? 'none' : '1px solid #eeeeee',
-                backgroundColor: selectLaiyuanBookIdList.indexOf(item.book_id)>-1?'#F2F3F5':''
+                backgroundColor: selectLaiyuanBookIdList.indexOf(item.book_id) > -1 ? '#F2F3F5' : '',
               }"
               @mouseover="gaolangbzt(i, 'shanxing_main')"
               @mouseout="closegaolangbzt(i, 'shanxing_main')"
@@ -356,7 +413,7 @@ export default {
   components: {
     Header,
     Strockplayredline,
-    StrockplayredlineCorpus
+    StrockplayredlineCorpus,
   },
   props: {},
   data() {
@@ -394,7 +451,7 @@ export default {
       allLevels: [],
       levelList: [],
       selectLaiyuanBookIdList: [], // 选中右侧来源书籍列表id
-      selectCurrent: 0
+      selectCurrent: 0,
     };
   },
   //计算属性 类似于data概念
@@ -411,13 +468,13 @@ export default {
     KWICsortEvent(index, type) {
       if (this.KWIC_sortIndex == index) return;
       this.KWIC_sortIndex = index;
-    //   this.CurrentList = this.allList[type];
-    //   this.padingEvetn();
+      //   this.CurrentList = this.allList[type];
+      //   this.padingEvetn();
       this.getdata();
     },
     // 排序
     sortEvent(type) {
-      this.sortType = type
+      this.sortType = type;
       if (this.sort == 'up' || !this.sort) {
         this.sort = 'down';
       } else {
@@ -461,13 +518,13 @@ export default {
         return;
       }
       this.patternIndex = index;
-      this.getdata()
-    //   if (this.patternIndex == 0) {
-    //     this.CurrentList = JSON.parse(JSON.stringify(this.allList.sentence_list));
-    //   } else {
-    //     this.CurrentList = JSON.parse(JSON.stringify(this.allList.sentence_list_sort_left));
-    //   }
-    //   this.padingEvetn();
+      this.getdata();
+      //   if (this.patternIndex == 0) {
+      //     this.CurrentList = JSON.parse(JSON.stringify(this.allList.sentence_list));
+      //   } else {
+      //     this.CurrentList = JSON.parse(JSON.stringify(this.allList.sentence_list_sort_left));
+      //   }
+      //   this.padingEvetn();
       this.page = 1;
     },
     // 切换释义来源
@@ -481,15 +538,15 @@ export default {
       } else {
         this.rightList = this.allList.stat_list_sentence_source_book;
       }
-    //   if (this.rightList.length > 0) {
-        this.inityuan();
-    //   }
+      //   if (this.rightList.length > 0) {
+      this.inityuan();
+      //   }
     },
     updownHz(flag) {
-      if(flag===true){
-        this.unfold = false
+      if (flag === true) {
+        this.unfold = false;
         this.ShowHzData.splice(2);
-      }else{
+      } else {
         this.unfold = !this.unfold;
         if (this.unfold) {
           this.ShowHzData = JSON.parse(JSON.stringify(this.hzData));
@@ -505,7 +562,7 @@ export default {
         this.gethzJSON();
       } else {
         //繁体
-        this.hzData.forEach(item => {
+        this.hzData.forEach((item) => {
           let a = converter(item.con);
           item.fanti = a;
         });
@@ -519,18 +576,18 @@ export default {
       let MethodName = 'hz_resource_manager-GetHZStrokesContent';
       this.hzData.forEach((item, i) => {
         let data = {
-          hz: this.JFIndex == 0 ? item.con : item.fanti
+          hz: this.JFIndex == 0 ? item.con : item.fanti,
         };
         item.hzDetail = {
-          hz_json: null
+          hz_json: null,
         };
         this.$forceUpdate();
         getLogin(MethodName, data)
-          .then(res => {
+          .then((res) => {
             this.$set(item.hzDetail, 'hz_json', res);
             this.$forceUpdate();
             this.ShowHzData = JSON.parse(JSON.stringify(this.hzData));
-            this.updownHz(true)
+            this.updownHz(true);
             if (i == this.hzData.length - 1) {
               this.loading = false;
             }
@@ -549,7 +606,7 @@ export default {
       var option;
       this.allNumber = 0;
       let newdata = JSON.parse(JSON.stringify(this.rightList));
-      newdata.forEach(item => {
+      newdata.forEach((item) => {
         this.allNumber += item.count;
         let percent = item.percent;
         item.value = item.count;
@@ -565,7 +622,7 @@ export default {
             name: 'Access From',
             type: 'pie',
             // radius: ["50%", "50%"],
-            data: newdata.length>0?newdata:[],
+            data: newdata.length > 0 ? newdata : [],
             itemStyle: {
               //   borderColor: "#fff",
               //   borderWidth: 2,
@@ -575,35 +632,37 @@ export default {
               itemStyle: {
                 shadowBlur: 10,
                 shadowOffsetX: 0,
-                shadowColor: 'rgba(0, 0, 0, 0.5)'
-              }
-            }
-          }
+                shadowColor: 'rgba(0, 0, 0, 0.5)',
+              },
+            },
+          },
         ],
         xAxis: {
           show: false, //不显示坐标轴线、坐标轴刻度线和坐标轴上的文字
           axisTick: {
-            show: false //不显示坐标轴刻度线
+            show: false, //不显示坐标轴刻度线
           },
           axisLine: {
-            show: false //不显示坐标轴线
+            show: false, //不显示坐标轴线
           },
           axisLabel: {
-            show: false //不显示坐标轴上的文字
-          }
-        }
+            show: false, //不显示坐标轴上的文字
+          },
+        },
       };
       option && myChart.setOption(option);
-      if(this.rightTopIndex === 1){
-        let number = 0
-        let _this = this
-        myChart.on('click', function(param) { //添加点击事件
+      if (this.rightTopIndex === 1) {
+        let number = 0;
+        let _this = this;
+        myChart.on('click', function (param) {
+          //添加点击事件
           myChart.dispatchAction({ type: 'highlight', dataIndex: param.dataIndex }); //激活点击区域高亮
-          if (param.dataIndex !== number) { // 当鼠标点击的时候 消除上一个扇区的高亮
-              myChart.dispatchAction({ type: 'downplay', dataIndex: number });
+          if (param.dataIndex !== number) {
+            // 当鼠标点击的时候 消除上一个扇区的高亮
+            myChart.dispatchAction({ type: 'downplay', dataIndex: number });
           }
-          number = param.dataIndex //接住当前扇区的dataIndex
-          _this.handleBookLiju(param.data.book_id)
+          number = param.dataIndex; //接住当前扇区的dataIndex
+          _this.handleBookLiju(param.data.book_id);
         });
       }
     },
@@ -613,7 +672,7 @@ export default {
       compareChart.dispatchAction({
         type: 'highlight',
         seriesIndex: 0,
-        dataIndex: index
+        dataIndex: index,
       });
     },
     // 鼠标移出
@@ -622,16 +681,16 @@ export default {
       compareChart.dispatchAction({
         type: 'downplay',
         seriesIndex: 0,
-        dataIndex: index
+        dataIndex: index,
       });
     },
     // 计算选中教材例句
-    handleBookLiju(id){
-      if(!id) return false
-      if(this.selectLaiyuanBookIdList.indexOf(id)>-1){
-        this.selectLaiyuanBookIdList.splice(this.selectLaiyuanBookIdList.indexOf(id),1)
-      }else{
-        this.selectLaiyuanBookIdList.push(id)
+    handleBookLiju(id) {
+      if (!id) return false;
+      if (this.selectLaiyuanBookIdList.indexOf(id) > -1) {
+        this.selectLaiyuanBookIdList.splice(this.selectLaiyuanBookIdList.indexOf(id), 1);
+      } else {
+        this.selectLaiyuanBookIdList.push(id);
       }
       this.padingEvetn();
       this.page = 1;
@@ -640,7 +699,7 @@ export default {
       this.hzData = [];
       this.jfEvent(0);
       let arr = this.$route.query.keyword.trim().split('');
-      arr.forEach(item => {
+      arr.forEach((item) => {
         if (!/^[\u4e00-\u9fa5]/.test(item)) {
           return;
         }
@@ -649,8 +708,8 @@ export default {
           con: item,
           pinyin: result,
           hzDetail: {
-            hz_json: null
-          }
+            hz_json: null,
+          },
         };
         this.hzData.push(obj);
         this.ShowHzData = JSON.parse(JSON.stringify(this.hzData));
@@ -663,7 +722,7 @@ export default {
       this.fenciShow = true;
       this.sizeIndex = 1;
       this.sort = '';
-      this.sortType = ''
+      this.sortType = '';
       this.KWIC_sortIndex = 0;
       this.cutSize(1);
       this.getdata();
@@ -671,7 +730,7 @@ export default {
     },
     getdata(flag) {
       this.loading = true;
-      this.scoreAHitNumber = 0
+      this.scoreAHitNumber = 0;
       let Mname = 'book-courseware_manager-GetCoursewareWordExampleSentenceList_Sort';
       let data = {
         // courseware_id: "003-20211012-17-BDUZ1JVCAN",
@@ -683,55 +742,61 @@ export default {
         is_contain_word_variants: false, // 是否包含单词变体例句
         is_contain_stat_data: true, //是否包统计数据
         is_filter_repetitive_sentence: 'true', // 过滤重复例句
-        sort_mode: this.sort ? (this.sort == 'down' ? 'DESCENT' : 'ASCENT') : 'NO',// 排序模式 NO 【不排序】,ASCENT【顺序】,DESCENT【倒序】
-        compare_mode: this.patternIndex === 0 ? 'LENGTH' : 'KWIC',// 排序比较模式,LENGTH【例句长度】,KWIC【KWIC 模式】
-        kwic_arrange_type: this.KWIC_sortIndex === 0 ? 'LEFT' : this.KWIC_sortIndex === 1 ? 'MID' : 'RIGHT',// KWIC 排列类型, LEFT【左】,MID【中】,RIGHT【右】
-        kwic_compare_by: this.sortType==='pclength'?1:0,// KWIC 排序比较依据,0【字符】,1【相邻的搭配词出现的次数】
+        sort_mode: this.sort ? (this.sort == 'down' ? 'DESCENT' : 'ASCENT') : 'NO', // 排序模式 NO 【不排序】,ASCENT【顺序】,DESCENT【倒序】
+        compare_mode: this.patternIndex === 0 ? 'LENGTH' : 'KWIC', // 排序比较模式,LENGTH【例句长度】,KWIC【KWIC 模式】
+        kwic_arrange_type: this.KWIC_sortIndex === 0 ? 'LEFT' : this.KWIC_sortIndex === 1 ? 'MID' : 'RIGHT', // KWIC 排列类型, LEFT【左】,MID【中】,RIGHT【右】
+        kwic_compare_by: this.sortType === 'pclength' ? 1 : 0, // KWIC 排序比较依据,0【字符】,1【相邻的搭配词出现的次数】
         book_publish_status: -1, // 教材发布状态 -1【全部】, 0【下架】1【上架】
-        book_id_list: this.level,  // 指定教材查询,空表示在检索范围内检索所有教材。
-        sentence_fc_length_min: localStorage.getItem('seekPageData')&&JSON.parse(localStorage.getItem('seekPageData')).sentenceStart?Number(JSON.parse(localStorage.getItem('seekPageData')).sentenceStart):-1, // 例句分词长度范围(最小值),-1 表示不检测最小值
-        sentence_fc_length_max: localStorage.getItem('seekPageData')&&JSON.parse(localStorage.getItem('seekPageData')).sentenceEnd?Number(JSON.parse(localStorage.getItem('seekPageData')).sentenceEnd):-1, // 例句分词长度范围(最大值),-1 表示不检测最大值
+        book_id_list: this.level, // 指定教材查询,空表示在检索范围内检索所有教材。
+        sentence_fc_length_min:
+          localStorage.getItem('seekPageData') && JSON.parse(localStorage.getItem('seekPageData')).sentenceStart
+            ? Number(JSON.parse(localStorage.getItem('seekPageData')).sentenceStart)
+            : -1, // 例句分词长度范围(最小值),-1 表示不检测最小值
+        sentence_fc_length_max:
+          localStorage.getItem('seekPageData') && JSON.parse(localStorage.getItem('seekPageData')).sentenceEnd
+            ? Number(JSON.parse(localStorage.getItem('seekPageData')).sentenceEnd)
+            : -1, // 例句分词长度范围(最大值),-1 表示不检测最大值
       };
       BookgetContent(Mname, data)
-        .then(res => {
+        .then((res) => {
           this.allList = {
             sentence_list: [],
             sentence_list_sort_left: [],
             sentence_list_sort_mid: [],
             sentence_list_sort_right: [],
             stat_list_sentence_source_book: res.stat_list_sentence_source_book,
-            stat_list_word_definition: res.stat_list_word_definition
+            stat_list_word_definition: res.stat_list_word_definition,
           };
 
           if (res.sentence_list.length > 0) {
-            res.stat_list_word_definition.forEach(item => {
+            res.stat_list_word_definition.forEach((item) => {
               item.book_name_s = item.definition;
-              item.book_name = JSON.parse(JSON.stringify(item.definition)).replace(/<i>/g, "").replace(/<\/i>/g, "");
+              item.book_name = JSON.parse(JSON.stringify(item.definition)).replace(/<i>/g, '').replace(/<\/i>/g, '');
             });
-            res.stat_list_sentence_source_book.forEach(item => {
+            res.stat_list_sentence_source_book.forEach((item) => {
               item.book_name_s = item.book_name;
             });
             // 清理脏数据
             this.removeRubbishData(res);
-            if(res.stat_list_word_definition.length===0){
-                this.rightTopIndex = 1
+            if (res.stat_list_word_definition.length === 0) {
+              this.rightTopIndex = 1;
             }
-            if(this.rightTopIndex === 0){
-                this.rightList = res.stat_list_word_definition;
-            }else{
-                this.rightList = res.stat_list_sentence_source_book;
+            if (this.rightTopIndex === 0) {
+              this.rightList = res.stat_list_word_definition;
+            } else {
+              this.rightList = res.stat_list_sentence_source_book;
             }
             this.getrightListdata();
-            if(this.patternIndex === 0){
-                this.allList.sentence_list = this.handleExample(res.sentence_list);
-            }else{
-                if(this.KWIC_sortIndex === 0){
-                    this.allList.sentence_list_sort_left = this.handleExample(res.sentence_list, 'left');
-                }else if(this.KWIC_sortIndex === 1){
-                    this.allList.sentence_list_sort_mid = this.handleExample(res.sentence_list, 'mid');
-                }else{
-                    this.allList.sentence_list_sort_right = this.handleExample(res.sentence_list, 'right');
-                }
+            if (this.patternIndex === 0) {
+              this.allList.sentence_list = this.handleExample(res.sentence_list);
+            } else {
+              if (this.KWIC_sortIndex === 0) {
+                this.allList.sentence_list_sort_left = this.handleExample(res.sentence_list, 'left');
+              } else if (this.KWIC_sortIndex === 1) {
+                this.allList.sentence_list_sort_mid = this.handleExample(res.sentence_list, 'mid');
+              } else {
+                this.allList.sentence_list_sort_right = this.handleExample(res.sentence_list, 'right');
+              }
             }
             this.CurrentList = JSON.parse(JSON.stringify(res.sentence_list));
             this.padingEvetn();
@@ -746,15 +811,15 @@ export default {
           } else {
             this.loading = false;
           }
-          if(res.word_pinyin_list){
-            res.word_pinyin_list.forEach((itemP,indexP)=>{
-              if(this.hzData[indexP]){
-                this.hzData[indexP].pinyin = itemP
+          if (res.word_pinyin_list) {
+            res.word_pinyin_list.forEach((itemP, indexP) => {
+              if (this.hzData[indexP]) {
+                this.hzData[indexP].pinyin = itemP;
               }
-            })
+            });
           }
         })
-        .catch(err => {
+        .catch((err) => {
           this.loading = false;
         });
     },
@@ -773,7 +838,10 @@ export default {
             });
             let data = this.changefiveword(arr, item.sentence_fc_list_word_index, type);
             item.resArr = data;
-            item.adjoin_fc_frequency_list_left = item.adjoin_fc_frequency_list.splice(0,item.sentence_fc_list_word_index)
+            item.adjoin_fc_frequency_list_left = item.adjoin_fc_frequency_list.splice(
+              0,
+              item.sentence_fc_list_word_index,
+            );
           } else if (type == 'right') {
             let sentence = JSON.parse(JSON.stringify(item.sentence));
             let arr = JSON.parse(JSON.stringify(item.sentence_fc_list));
@@ -784,7 +852,9 @@ export default {
             });
             let data = this.changefiveword(arr, item.sentence_fc_list_word_index, type);
             item.resArr = data;
-            item.adjoin_fc_frequency_list_right = item.adjoin_fc_frequency_list.splice(item.sentence_fc_list_word_index+1)
+            item.adjoin_fc_frequency_list_right = item.adjoin_fc_frequency_list.splice(
+              item.sentence_fc_list_word_index + 1,
+            );
           } else if (type == 'mid') {
             let sentence = JSON.parse(JSON.stringify(item.sentence));
             let arr = JSON.parse(JSON.stringify(item.sentence_fc_list));
@@ -797,7 +867,7 @@ export default {
             item.resArr = data;
           } else {
             this.scoreAHitNumber += item.position_list.length;
-            let sentence_fc_list_style = []
+            let sentence_fc_list_style = [];
             let newsentence = JSON.parse(JSON.stringify(item.sentence));
             let res = '';
             for (let i = 0; i < item.position_list.length; i++) {
@@ -824,14 +894,14 @@ export default {
               res += part1 + '<span style="color:#DE4444;">' + part2 + '</span>' + part3;
             }
             item.res = res;
-            item.sentence_fc_list.forEach((items,indexs)=>{
-                if(item.sentence_fc_list_word_index_list.indexOf(indexs)>-1){
-                    sentence_fc_list_style.push('<span style="color:#DE4444;">' + items + '</span>')
-                }else{
-                    sentence_fc_list_style.push(items)
-                }
-            })
-            item.sentence_fc_list_style = sentence_fc_list_style
+            item.sentence_fc_list.forEach((items, indexs) => {
+              if (item.sentence_fc_list_word_index_list.indexOf(indexs) > -1) {
+                sentence_fc_list_style.push('<span style="color:#DE4444;">' + items + '</span>');
+              } else {
+                sentence_fc_list_style.push(items);
+              }
+            });
+            item.sentence_fc_list_style = sentence_fc_list_style;
           }
           return item;
         });
@@ -886,65 +956,67 @@ export default {
     // 处理分页
     padingEvetn() {
       let arr = JSON.parse(JSON.stringify(this.CurrentList));
-      let arrs = []
-      if(this.selectLaiyuanBookIdList.length===0){
-        arrs = arr
-      }else{
-        arr.forEach(item=>{
-          let path = item.source_courseware_id_path.split('/')
-          if(path.length>0&&this.selectLaiyuanBookIdList.indexOf(path[0])>-1){
-            arrs.push(item)
+      let arrs = [];
+      if (this.selectLaiyuanBookIdList.length === 0) {
+        arrs = arr;
+      } else {
+        arr.forEach((item) => {
+          let path = item.source_courseware_id_path.split('/');
+          if (path.length > 0 && this.selectLaiyuanBookIdList.indexOf(path[0]) > -1) {
+            arrs.push(item);
           }
-        })
+        });
       }
-      this.selectCurrent = arrs.length
+      this.selectCurrent = arrs.length;
       let newarr = arrs.splice((this.page - 1) * this.pageSize, this.pageSize);
       this.ShowList = JSON.parse(JSON.stringify(newarr));
     },
     // 删除脏数据
     removeRubbishData(data) {
-      if(data.sentence_list.length>0){
+      if (data.sentence_list.length > 0) {
         for (let i = data.sentence_list.length; i--; ) {
-            if (data.sentence_list[i].sentence_fc_list.length <= 1||data.sentence_list[i].sentence_fc_list_word_index===-1) {
-                data.sentence_list.splice(i, 1);
-            }
+          if (
+            data.sentence_list[i].sentence_fc_list.length <= 1 ||
+            data.sentence_list[i].sentence_fc_list_word_index === -1
+          ) {
+            data.sentence_list.splice(i, 1);
+          }
         }
       }
     },
     page1getdata(value) {
-      if(value){
+      if (value) {
         let checkedCount = value.length;
         this.checkAll = checkedCount === this.levelList.length;
         this.isIndeterminate = checkedCount > 0 && checkedCount < this.levelList.length;
       }
     },
     handleCheckAllChange(val) {
-        this.level = val ? this.allLevels : [];
-        this.isIndeterminate = false;
+      this.level = val ? this.allLevels : [];
+      this.isIndeterminate = false;
     },
     // 获取上架教材列表
-    getLevelList(){
-        this.allLevels = []
-        this.levelList = []
-        BookgetContent('book-book_manager-GetBookList',{
-          publish_status: 1
-        })
-        .then((res) => {
-          this.loading = false
-          if(res.status===1){
-            res.book_list.forEach(item=>{
-                item.value = item.id
-                item.label = item.name
-                this.allLevels.push(item.id)
-            })
-            this.levelList = this.levelList.concat(res.book_list)
-          }
-        })
+    getLevelList() {
+      this.allLevels = [];
+      this.levelList = [];
+      BookgetContent('book-book_manager-GetBookList', {
+        publish_status: 1,
+      }).then((res) => {
+        this.loading = false;
+        if (res.status === 1) {
+          res.book_list.forEach((item) => {
+            item.value = item.id;
+            item.label = item.name;
+            this.allLevels.push(item.id);
+          });
+          this.levelList = this.levelList.concat(res.book_list);
+        }
+      });
     },
   },
   //生命周期 - 创建完成(可以访问当前this实例)
   created() {
-    this.getLevelList()
+    this.getLevelList();
   },
   //生命周期 - 挂载完成(可以访问DOM元素)
   mounted() {
@@ -963,7 +1035,7 @@ export default {
   //生命周期-销毁完成
   destoryed() {},
   //如果页面有keep-alive缓存功能,这个函数会触发
-  activated() {}
+  activated() {},
 };
 </script>
 <style lang="scss" scoped>
@@ -987,12 +1059,12 @@ export default {
     background: #fff;
     border-radius: 8px;
 
-    .selectBook{
+    .selectBook {
       position: absolute;
       right: 13px;
       top: 40px;
-      width: 180px; 
-      .el-select__tags{
+      width: 180px;
+      .el-select__tags {
         max-width: 135px;
       }
     }
@@ -1264,7 +1336,7 @@ export default {
         // height: 95%;
         .list {
           margin-top: 16px;
-          
+
           .lang_sort {
             display: flex;
             align-items: center;
@@ -1273,18 +1345,18 @@ export default {
             cursor: pointer;
             margin: 0 0 16px 16px;
             border-radius: 20px;
-            border: 1px solid #E5E6EB;
+            border: 1px solid #e5e6eb;
             padding: 4px 12px;
             font-size: 14px;
-            &.active{
-                border-color: #4992FF;
-                background: #4992FF;
-                color: #fff;
+            &.active {
+              border-color: #4992ff;
+              background: #4992ff;
+              color: #fff;
             }
             img {
-                width: 16px;
-                height: 16px;
-                margin-left: 2px;
+              width: 16px;
+              height: 16px;
+              margin-left: 2px;
             }
           }
           .one {
@@ -1293,7 +1365,7 @@ export default {
 
             .top {
               display: flex;
-            //   align-items: center;
+              //   align-items: center;
 
               // flex-flow: wrap;
               width: 100%;
@@ -1508,7 +1580,7 @@ export default {
           display: flex;
           align-items: center;
           justify-content: center;
-        //   width: 84px;
+          //   width: 84px;
           padding: 0 2px;
           height: 28px;
           margin-left: 16px;
@@ -1610,23 +1682,23 @@ export default {
 .el-loading-mask {
   z-index: 200000 !important;
 }
-.checkAllCheckbox{
+.checkAllCheckbox {
   width: 100%;
-  padding: 0 20px;  
+  padding: 0 20px;
   height: 34px;
   line-height: 34px;
-  &:hover{
-      background-color: #F5F7FA;
+  &:hover {
+    background-color: #f5f7fa;
   }
-  .el-checkbox__input{
-      display: none;
+  .el-checkbox__input {
+    display: none;
   }
-  .el-checkbox__label{
-      padding: 0;
+  .el-checkbox__label {
+    padding: 0;
   }
 }
-.selectBook{ 
-  .el-tag{
+.selectBook {
+  .el-tag {
     max-width: 90px;
   }
 }

+ 7 - 7
src/views/corpus/seekPage.vue

@@ -16,10 +16,10 @@
 <script>
 //这里可以导入其它文件(比如:组件,工具js,第三方插件js,json文件,图片文件等等)
 //例如:import 《组件名称》from ‘《组件路径》';
-import Header from "@/components/Header";
+import Header from '@/components/Header';
 
 export default {
-  name: "corpus_seekpage",
+  name: 'corpus_seekpage',
   //import引入的组件需要注入到对象中才能使用
   components: {
     Header,
@@ -40,7 +40,7 @@ export default {
     downSeek(e) {
       if (e.keyCode == 13) {
         if (!this.keyword) {
-          this.$message.warning("请输入要搜索的内容");
+          this.$message.warning('请输入要搜索的内容');
           return;
         }
         this.seekEvent();
@@ -48,11 +48,11 @@ export default {
     },
     seekEvent() {
       if (!this.keyword) {
-        this.$message.warning("请输入要搜索的内容");
+        this.$message.warning('请输入要搜索的内容');
         return;
       }
       this.$router.push({
-        path: "/corpus/Result",
+        path: '/corpus/Result',
         query: {
           keyword: this.keyword,
         },
@@ -61,7 +61,7 @@ export default {
   },
   //生命周期 - 创建完成(可以访问当前this实例)
   created() {
-    localStorage.removeItem('seekPageData')
+    localStorage.removeItem('seekPageData');
   },
   //生命周期 - 挂载完成(可以访问DOM元素)
   mounted() {},
@@ -143,4 +143,4 @@ export default {
     opacity: 0.65;
   }
 }
-</style>
+</style>

+ 45 - 15
src/views/teacher-dev/TextAnalysis.vue

@@ -1,10 +1,16 @@
 <template>
   <div v-loading="loading" class="TextAnalysis">
-    <HeaderPage />
-    <div class="main">
+    <HeaderPage v-if="!AccessToken" />
+    <div class="main" v-if="showPage">
       <div class="title">文本分析</div>
       <div class="input_main">
-        <el-input v-model="txt" type="textarea" placeholder="请输入文本" :autosize="{ minRows: 9 }" :maxlength="maxWordCount" />
+        <el-input
+          v-model="txt"
+          type="textarea"
+          placeholder="请输入文本"
+          :autosize="{ minRows: 9 }"
+          :maxlength="maxWordCount"
+        />
         <div class="text_btn">
           <span class="left">{{ txt.length }}/{{ maxWordCount }}</span>
           <div class="operation">
@@ -29,9 +35,13 @@
         <div class="title">
           <span style="margin-right: 16px">文本列表:</span>
         </div>
-        <div class="list" v-loading="recordLoading">
-          <div v-for="(item, i) in data.record_list" :key="`${i}one`" :style="{backgroundColor:item.analysis_status === 0 ? '#FAF6EB' : ''}">
-            <div class="number">{{ i + 1 }}</div>
+        <div v-loading="recordLoading" class="list">
+          <div
+            v-for="(item, i) in data.record_list"
+            :key="`${i}one`"
+            :style="{ backgroundColor: item.analysis_status === 0 ? '#FAF6EB' : '' }"
+          >
+            <div class="number">{{ pageSize * (data.cur_page - 1) + i + 1 }}</div>
             <div class="txt" @click="handleJump(item)">
               {{ item.first_sentence }}
             </div>
@@ -51,7 +61,7 @@
         </div>
         <el-pagination
           :current-page.sync="data.cur_page"
-          :page-size="20"
+          :page-size="pageSize"
           layout="total, prev, pager, next, jumper"
           :total="data.total_count"
           @current-change="handleCurrentChange"
@@ -69,8 +79,9 @@ import {
   analyse,
   reparse,
   DeleteTextAnalyseRecord,
+  getStaticContent,
 } from '@/api/api';
-import { getToken } from '@/utils/auth';
+import { getToken, setToken } from '@/utils/auth';
 
 import HeaderPage from '@/components/Header';
 
@@ -95,18 +106,34 @@ export default {
         3: '解析失败',
       },
       recordLoading: false,
+      AccessToken: this.$route.query.AccessToken,
+      AppID: this.$route.query.AppID,
+      UserID: this.$route.query.UserID,
+      showPage: false,
     };
   },
   computed: {
     url() {
-      let userInfo = JSON.parse(getToken());
+      let userInfo = getToken() ? JSON.parse(getToken()) : null;
       if (!userInfo) return `${process.env.VUE_APP_BASE_API}/GCLSFileServer/WebFileUpload`;
       return `${process.env.VUE_APP_BASE_API}/GCLSFileServer/WebFileUpload?AccessToken=${userInfo.access_token}&SecurityLevel=Mid"`;
     },
   },
-  created() {
+  async created() {
+    const _this = this;
+    if (this.AccessToken) {
+      const Mname = 'login_control-ParseAccessToken';
+      await getStaticContent(Mname, {
+        access_token: _this.AccessToken,
+      }).then((res) => {
+        res.access_token = _this.AccessToken;
+        setToken(res);
+        this.showPage = true;
+      });
+    }
     let data = getToken();
     this.token = JSON.parse(data);
+    this.showPage = true;
     this.pageQueryMyTextAnalyseRecordList();
   },
   // 方法集合
@@ -177,7 +204,7 @@ export default {
             // word_difficulty: item.word_difficulty,
             // vocabulary_difficulty: item.vocabulary_difficulty,
             type: '文本分析',
-            id: item.id
+            id: item.id,
           },
         }).href,
         '_blank',
@@ -194,8 +221,7 @@ export default {
           this.pageQueryMyTextAnalyseRecordList();
           this.$message.success('删除成功');
         })
-        .finally(() => {
-        });
+        .finally(() => {});
     },
     /**
      * 重新解析
@@ -227,7 +253,7 @@ export default {
         text: this.txt,
       })
         .then(({ record }) => {
-        //   this.txt = '';
+          //   this.txt = '';
           this.jumpResult(record);
           this.pageQueryMyTextAnalyseRecordList(true);
         })
@@ -252,7 +278,11 @@ export default {
      */
     pageQueryMyTextAnalyseRecordList(bol) {
       this.recordLoading = true;
-      PageQueryMyTextAnalyseRecordList({ page_capacity: this.pageSize, cur_page: this.data?.cur_page ?? 1 })
+      PageQueryMyTextAnalyseRecordList({
+        page_capacity: this.pageSize,
+        cur_page: this.data?.cur_page ?? 1,
+        app_user_id: this.UserID ? this.UserID : '',
+      })
         .then((data) => {
           this.data = data;
           if (bol) {

+ 123 - 200
src/views/wordcard/cread.vue

@@ -4,20 +4,14 @@
     <div class="main" v-if="!isPreview">
       <div class="from">
         <div class="type">
-          <div :class="[typeIndex == 0 ? 'sele' : '']" @click="cutType(0)">
-            字模式
-          </div>
-          <div :class="[typeIndex == 1 ? 'sele' : '']" @click="cutType(1)">
-            词模式
-          </div>
+          <div :class="[typeIndex == 0 ? 'sele' : '']" @click="cutType(0)">字模式</div>
+          <div :class="[typeIndex == 1 ? 'sele' : '']" @click="cutType(1)">词模式</div>
         </div>
         <div class="from_main">
           <div class="left">
             <el-input
               type="textarea"
-              :placeholder="
-                typeIndex == 0 ? '请输入' : '每行输入一个句子/词汇'
-              "
+              :placeholder="typeIndex == 0 ? '请输入' : '每行输入一个句子/词汇'"
               v-model="from.content"
               maxlength="100"
               show-word-limit
@@ -36,11 +30,7 @@
                 <el-radio :label="2">空格</el-radio>
               </el-radio-group>
               <span class="title">文字大小</span>
-              <el-select
-                v-model="from.fontSize"
-                placeholder=""
-                style="width: 60px"
-              >
+              <el-select v-model="from.fontSize" placeholder="" style="width: 60px">
                 <el-option label="大" value="big"> </el-option>
                 <el-option label="中" value="center"> </el-option>
                 <el-option label="小" value="little"> </el-option>
@@ -48,10 +38,7 @@
             </div>
             <div class="dv">
               <span class="title">边框颜色</span>
-              <el-color-picker
-                v-model="from.borderColor"
-                style="margin-right: 16px"
-              ></el-color-picker>
+              <el-color-picker v-model="from.borderColor" style="margin-right: 16px"></el-color-picker>
               <span class="title">文字颜色</span>
               <el-color-picker v-model="from.fontColor"></el-color-picker>
             </div>
@@ -65,12 +52,7 @@
               >
               </el-switch>
               <template v-if="typeIndex == 0">
-                <el-switch
-                  active-color="#424242"
-                  v-model="from.StorkesUnfold"
-                  active-text="笔顺展开"
-                >
-                </el-switch>
+                <el-switch active-color="#424242" v-model="from.StorkesUnfold" active-text="笔顺展开"> </el-switch>
               </template>
             </div>
             <div class="title" style="margin-top: 24px">书写配置:</div>
@@ -83,9 +65,7 @@
                   onkeyup="value=value.replace(/^0+(\d)|[^\d]+/g,'')"
                   class="numbre-input"
                 ></el-input>
-                <span style="margin-left: 8px">{{
-                  typeIndex == 0 ? "行" : "句"
-                }}</span>
+                <span style="margin-left: 8px">{{ typeIndex == 0 ? '行' : '句' }}</span>
               </div>
               <div style="margin-right: 16px">
                 <span class="title">描红</span>
@@ -95,9 +75,7 @@
                   class="numbre-input"
                   onkeyup="value=value.replace(/^0+(\d)|[^\d]+/g,'')"
                 ></el-input>
-                <span style="margin-left: 8px">{{
-                  typeIndex == 0 ? "格" : "句"
-                }}</span>
+                <span style="margin-left: 8px">{{ typeIndex == 0 ? '格' : '句' }}</span>
               </div>
               <div>
                 <span class="title">文末空行</span>
@@ -112,33 +90,23 @@
             </div>
             <div class="dv">
               <span class="title">描红底色</span>
-              <el-color-picker
-                v-model="from.miaoRedBgcolor"
-                style="margin-right: 16px"
-              ></el-color-picker>
+              <el-color-picker v-model="from.miaoRedBgcolor" style="margin-right: 16px"></el-color-picker>
               <span class="title">书写颜色</span>
               <el-color-picker v-model="from.writeColor"></el-color-picker>
             </div>
           </div>
         </div>
       </div>
-      <div class="operation" v-if="isCread && writeTableData && writeTableData.result && writeTableData.result.length>0">
-        <div @click="saveEvent">
-          <img src="../../assets/teacherdev/word-save.png" alt="" /> 保存
-        </div>
-        <div @click="previewEvent">
-          <img src="../../assets/teacherdev/word-eyes.png" alt="" /> 预览
-        </div>
-        <div @click="download2('pdfDom')">
-          <img src="../../assets/teacherdev/word-download.png" alt="" /> 打印
-        </div>
+      <div
+        class="operation"
+        v-if="isCread && writeTableData && writeTableData.result && writeTableData.result.length > 0"
+      >
+        <div @click="saveEvent"><img src="../../assets/teacherdev/word-save.png" alt="" /> 保存</div>
+        <div @click="previewEvent"><img src="../../assets/teacherdev/word-eyes.png" alt="" /> 预览</div>
+        <div @click="download2('pdfDom')"><img src="../../assets/teacherdev/word-download.png" alt="" /> 打印</div>
       </div>
       <div class="word_main" v-if="writeTableData && writeTableData.result">
-        <div
-          class="word_main_table"
-          v-for="(itemT, indexT) in writeTableData.result"
-          :key="indexT"
-        >
+        <div class="word_main_table" v-for="(itemT, indexT) in writeTableData.result" :key="indexT">
           <writeTable
             :type="typeIndex"
             :dataConfig="writeTableData"
@@ -150,12 +118,7 @@
       </div>
     </div>
     <div class="preview_dv" v-if="isPreview">
-      <img
-        class="close"
-        src="../../assets/teacherdev/creadCad-close.png"
-        alt=""
-        @click="closepreviewEvent"
-      />
+      <img class="close" src="../../assets/teacherdev/creadCad-close.png" alt="" @click="closepreviewEvent" />
       <div class="preview_main">
         <img
           class="left"
@@ -174,21 +137,10 @@
             />
           </div>
         </div>
-        <img
-          class="right"
-          src="../../assets/teacherdev/creadCad-right.png"
-          alt=""
-          @click="changepreviewIndex('add')"
-        />
+        <img class="right" src="../../assets/teacherdev/creadCad-right.png" alt="" @click="changepreviewIndex('add')" />
       </div>
     </div>
-    <el-dialog
-      title="保存为"
-      :visible.sync="saveShow"
-      width="30%"
-      :before-close="handleClose"
-      :modal="false"
-    >
+    <el-dialog title="保存为" :visible.sync="saveShow" width="30%" :before-close="handleClose" :modal="false">
       <el-input placeholder="请输入" v-model="saveName"> </el-input>
       <span slot="footer" class="dialog-footer">
         <el-button @click="handleClose">取 消</el-button>
@@ -201,15 +153,15 @@
 <script>
 //这里可以导入其它文件(比如:组件,工具js,第三方插件js,json文件,图片文件等等)
 //例如:import 《组件名称》from ‘《组件路径》';
-import Header from "@/components/Header";
-import { getLogin, LearnWebSI } from "@/api/api";
-import writeTable from "./writeTable.vue";
-import html2canvas from "html2canvas";
-import { jsPDF } from "jspdf";
-import canvg from "canvg";
+import Header from '@/components/Header';
+import { getLogin, LearnWebSI } from '@/api/api';
+import writeTable from './writeTable.vue';
+import html2canvas from 'html2canvas';
+import { jsPDF } from 'jspdf';
+import canvg from 'canvg';
 
-import FileSaver from "file-saver";
-import htmlDocx from "html-docx-js/dist/html-docx";
+import FileSaver from 'file-saver';
+import htmlDocx from 'html-docx-js/dist/html-docx';
 export default {
   //import引入的组件需要注入到对象中才能使用
   components: {
@@ -220,28 +172,28 @@ export default {
   data() {
     //这里存放数据
     return {
-      saveName: "",
+      saveName: '',
       typeIndex: 0,
       from: {
-        content: "",
+        content: '',
         BoxbgType: 0,
-        fontSize: "center",
+        fontSize: 'center',
         playStorkes: true,
         StorkesUnfold: true,
-        writeBoxNumber: "0", //书写行
-        miaoRedBoxNumber: "0", //描红格
-        lastNullrow: "0", //文本末空行数
-        miaoRedBgcolor: "#E1E1E1", //描红底色
-        writeColor: "#000000", //书写颜色
-        borderColor: "#D65353", //边框颜色
-        fontColor: "#000000", //文字颜色
+        writeBoxNumber: '0', //书写行
+        miaoRedBoxNumber: '0', //描红格
+        lastNullrow: '0', //文本末空行数
+        miaoRedBgcolor: '#E1E1E1', //描红底色
+        writeColor: '#000000', //书写颜色
+        borderColor: '#D65353', //边框颜色
+        fontColor: '#000000', //文字颜色
       },
       loading: false,
       writeTableData: null,
       isCread: false,
       isPreview: false,
       previewIndex: 0,
-      htmlTitle: "1",
+      htmlTitle: '1',
       saveShow: false,
       writetableShow: true,
       hzDetailList: null,
@@ -263,17 +215,17 @@ export default {
     save() {
       this.loading = this.$loading({
         lock: true,
-        text: "Loading",
-        spinner: "el-icon-loading",
-        background: "rgba(0, 0, 0, 0.7)",
+        text: 'Loading',
+        spinner: 'el-icon-loading',
+        background: 'rgba(0, 0, 0, 0.7)',
       });
       if (this.$route.query.id) {
         // 编辑
-        let Mname = "tr_tool-wsc_manager-UpdateMyWordSentenceCard";
+        let Mname = 'tr_tool-wsc_manager-UpdateMyWordSentenceCard';
         LearnWebSI(Mname, {
           id: this.$route.query.id,
           name: this.saveName,
-          type: this.typeIndex == 0 ? "WORD" : "SENTENCE",
+          type: this.typeIndex == 0 ? 'WORD' : 'SENTENCE',
           text: this.from.content,
           content: JSON.stringify(this.writeTableData),
         })
@@ -281,7 +233,7 @@ export default {
             this.loading.close();
             this.loading = false;
             this.saveShow = false;
-            this.$message.success("保存成功");
+            this.$message.success('保存成功');
           })
           .catch((res) => {
             this.loading.close();
@@ -289,16 +241,16 @@ export default {
           });
       } else {
         // 新建
-        let Mname = "tr_tool-wsc_manager-CreateMyWordSentenceCard";
+        let Mname = 'tr_tool-wsc_manager-CreateMyWordSentenceCard';
         LearnWebSI(Mname, {
           name: this.saveName,
-          type: this.typeIndex == 0 ? "WORD" : "SENTENCE",
+          type: this.typeIndex == 0 ? 'WORD' : 'SENTENCE',
           text: this.from.content,
           content: JSON.stringify(this.writeTableData),
         })
           .then((res) => {
             this.$router.replace({
-              path: "/wordcard/cread",
+              path: '/wordcard/cread',
               query: {
                 id: res.id,
               },
@@ -306,7 +258,7 @@ export default {
             this.loading.close();
             this.loading = false;
             this.saveShow = false;
-            this.$message.success("保存成功");
+            this.$message.success('保存成功');
           })
           .catch((res) => {
             this.loading.close();
@@ -319,7 +271,7 @@ export default {
       content = content ? content : null;
       // 条件判断是否打印
       if (!content) {
-        alert("打印失败,请重新操作");
+        alert('打印失败,请重新操作');
         return false;
       }
       // 开始打印
@@ -329,12 +281,12 @@ export default {
       //以下是对svg的处理
       var nodesToRecover = [];
       var nodesToRemove = [];
-      var svgElem = $("#pdfDom").find("svg-icon"); //divReport为需要截取成图片的dom的id
+      var svgElem = $('#pdfDom').find('svg-icon'); //divReport为需要截取成图片的dom的id
       console.log(svgElem);
       svgElem.each(function (index, node) {
         var parentNode = node.parentNode;
         var svg = node.outerHTML.trim();
-        var canvas2 = document.createElement("canvas");
+        var canvas2 = document.createElement('canvas');
         canvg(canvas2, svg);
         if (node.style.position) {
           canvas2.style.position += node.style.position;
@@ -352,10 +304,10 @@ export default {
         });
         parentNode.appendChild(canvas2);
       });
-      var canvas = document.createElement("canvas");
+      var canvas = document.createElement('canvas');
       canvas.width = contentWidth;
       canvas.height = contentHeight;
-      var context = canvas.getContext("2d");
+      var context = canvas.getContext('2d');
       html2canvas(content, {
         allowTaint: true,
         scale: 2, // 提升画面质量,但是会增加文件大小
@@ -367,14 +319,14 @@ export default {
         var position = 0;
         var imgWidth = 595.28;
         var imgHeight = (595.28 / pdfWidth) * pdfHeight;
-        var pageData = canvas.toDataURL("img/jpeg", 1.0);
-        var pdf = new jsPDF("", "pt", "a4");
+        var pageData = canvas.toDataURL('img/jpeg', 1.0);
+        var pdf = new jsPDF('', 'pt', 'a4');
         // 判断打印dom高度是否需要分页,如果需要进行分页处理
         if (leftHeight < pageHeight) {
-          pdf.addImage(pageData, "JPEG", 0, 0, imgWidth, imgHeight);
+          pdf.addImage(pageData, 'JPEG', 0, 0, imgWidth, imgHeight);
         } else {
           while (leftHeight > 0) {
-            pdf.addImage(pageData, "JPEG", 0, position, imgWidth, imgHeight);
+            pdf.addImage(pageData, 'JPEG', 0, position, imgWidth, imgHeight);
             leftHeight -= pageHeight;
             position -= 841.89;
             if (leftHeight > 0) {
@@ -382,15 +334,15 @@ export default {
             }
           }
         }
-        pdf.save("案例.pdf");
+        pdf.save('案例.pdf');
       });
     },
     download2() {
       this.$nextTick(() => {
         if (this.writeTableData) {
           let str = JSON.stringify(this.writeTableData);
-          localStorage.setItem("writeTableData", str);
-          this.$router.replace("/wordcard/print");
+          localStorage.setItem('writeTableData', str);
+          this.$router.replace('/wordcard/print');
         }
       });
 
@@ -410,15 +362,15 @@ export default {
       // return false;
     },
     changepreviewIndex(type) {
-      if (type == "add") {
+      if (type == 'add') {
         if (this.previewIndex == this.writeTableData.result.length - 1) {
-          this.$message.warning("当前已经是最后一页");
+          this.$message.warning('当前已经是最后一页');
           return;
         }
         this.previewIndex++;
       } else {
         if (this.previewIndex == 0) {
-          this.$message.warning("当前已经是第一页");
+          this.$message.warning('当前已经是第一页');
           return;
         }
         this.previewIndex--;
@@ -456,58 +408,48 @@ export default {
         miaoRedBoxNumber: this.from.miaoRedBoxNumber,
         lastNullrow: this.from.lastNullrow,
       };
-      if (this.from.fontSize == "big") {
-        data.width = "62px";
-        data.fontSize = "48px";
+      if (this.from.fontSize == 'big') {
+        data.width = '62px';
+        data.fontSize = '48px';
         data.rowNumber = 8;
         data.pageNumber = 9;
-        data.marginBottom = "15px";
-        data.playWidth = "11px";
-      } else if (this.from.fontSize == "center") {
-        data.width = "49px";
-        data.fontSize = "38px";
+        data.marginBottom = '15px';
+        data.playWidth = '11px';
+      } else if (this.from.fontSize == 'center') {
+        data.width = '49px';
+        data.fontSize = '38px';
         data.rowNumber = 10;
         data.pageNumber = 12;
-        data.marginBottom = "8px";
-        data.playWidth = "9px";
+        data.marginBottom = '8px';
+        data.playWidth = '9px';
       } else {
-        data.width = "41px";
-        data.fontSize = "31px";
+        data.width = '41px';
+        data.fontSize = '31px';
         data.rowNumber = 12;
         data.pageNumber = 14;
-        data.marginBottom = "7px";
-        data.playWidth = "8px";
+        data.marginBottom = '7px';
+        data.playWidth = '8px';
       }
-      if (this.from.content == "") {
-        this.$message.warning("请先输入内容");
+      if (this.from.content == '') {
+        this.$message.warning('请先输入内容');
         return;
       }
-      if (
-        !(
-          this.from.writeBoxNumber ||
-          this.from.miaoRedBoxNumber ||
-          this.from.lastNullrow
-        )
-      ) {
-        this.$message.warning("请先输入配置内容");
+      if (!(this.from.writeBoxNumber || this.from.miaoRedBoxNumber || this.from.lastNullrow)) {
+        this.$message.warning('请先输入配置内容');
         return;
       }
-      if (
-        Number(this.from.writeBoxNumber) < Number(this.from.miaoRedBoxNumber) &&
-        this.typeIndex == 1
-      ) {
-        this.$message.warning("书写格数不能小于描红数");
+      if (Number(this.from.writeBoxNumber) < Number(this.from.miaoRedBoxNumber) && this.typeIndex == 1) {
+        this.$message.warning('书写格数不能小于描红数');
         return;
       } else if (
-        Number(this.from.writeBoxNumber) <
-          Math.ceil(this.from.miaoRedBoxNumber / data.rowNumber) &&
+        Number(this.from.writeBoxNumber) < Math.ceil(this.from.miaoRedBoxNumber / data.rowNumber) &&
         this.typeIndex == 0
       ) {
-        this.$message.warning("书写格数不能小于描红所用行数");
+        this.$message.warning('书写格数不能小于描红所用行数');
         return;
       }
       let option = [];
-      let contentArr = this.from.content.split("\n");
+      let contentArr = this.from.content.split('\n');
       for (let i = 0; i < contentArr.length; i++) {
         if (data.typeIndex == 0) {
           if (contentArr[i].length == 1) {
@@ -528,7 +470,7 @@ export default {
             }
           }
         } else {
-          let contentItem = "";
+          let contentItem = '';
           for (let s = 0; s < contentArr[i].length; s++) {
             if (/^[\u4e00-\u9fa5]/.test(contentArr[i][s])) {
               contentItem += contentArr[i][s];
@@ -537,7 +479,7 @@ export default {
           if (contentItem) option.push(contentItem);
         }
       }
-      let hz_str = "";
+      let hz_str = '';
       if (data.typeIndex == 0) {
         option.forEach((item) => {
           hz_str += item.con;
@@ -551,7 +493,7 @@ export default {
     //得到多个汉字笔画内容
     getMultHZStrokesContent(hz_str, oldData) {
       this.loading = true;
-      let MethodName = "hz_resource_manager-GetMultHZStrokesContent";
+      let MethodName = 'hz_resource_manager-GetMultHZStrokesContent';
       let data = {
         hz_str: hz_str,
       };
@@ -559,7 +501,7 @@ export default {
         .then((res) => {
           this.loading = false;
           for (let key in res) {
-            if (key != "status" && key != ",") {
+            if (key != 'status' && key != ',') {
               res[key] = JSON.parse(res[key]);
             }
           }
@@ -574,7 +516,7 @@ export default {
     handleEvent(hzDetailList, oldData) {
       this.writeTableData = null;
       let data = JSON.parse(JSON.stringify(oldData));
-      let contentArr = this.from.content.split("\n");
+      let contentArr = this.from.content.split('\n');
       for (let i = 0; i < contentArr.length; i++) {
         if (data.typeIndex == 0) {
           if (contentArr[i].length == 1) {
@@ -595,7 +537,7 @@ export default {
             }
           }
         } else {
-          let contentItem = "";
+          let contentItem = '';
           for (let s = 0; s < contentArr[i].length; s++) {
             if (/^[\u4e00-\u9fa5]/.test(contentArr[i][s])) {
               contentItem += contentArr[i][s];
@@ -611,7 +553,7 @@ export default {
             hz_json: null,
           };
           let res = JSON.parse(JSON.stringify(hzDetailList[item.con]));
-          this.$set(data.option[i].hzDetail, "hz_json", res);
+          this.$set(data.option[i].hzDetail, 'hz_json', res);
         });
         if (data.StorkesUnfold) {
           let allArr = [];
@@ -624,11 +566,7 @@ export default {
               con: item.con,
               hzDetail: JSON.parse(JSON.stringify(item.hzDetail.hz_json)),
             });
-            if (
-              item.hzDetail &&
-              item.hzDetail.hz_json &&
-              item.hzDetail.hz_json.medians
-            ) {
+            if (item.hzDetail && item.hzDetail.hz_json && item.hzDetail.hz_json.medians) {
               hzLength += item.hzDetail.hz_json.medians.length;
               item.hzDetail.hz_json.medians.forEach((items, indexs) => {
                 arr.push({
@@ -669,8 +607,7 @@ export default {
                 // 描红格
                 if (i == 0 && data.miaoRedBoxNumber) {
                   let m =
-                    Math.ceil(data.miaoRedBoxNumber / data.rowNumber) >
-                    data.writeBoxNumber
+                    Math.ceil(data.miaoRedBoxNumber / data.rowNumber) > data.writeBoxNumber
                       ? data.writeBoxNumber
                       : Math.ceil(data.miaoRedBoxNumber / data.rowNumber);
                   for (let j = 0; j < m; j++) {
@@ -764,20 +701,13 @@ export default {
                 // 描红格
                 if (i == 0 && data.miaoRedBoxNumber) {
                   let m =
-                    Math.ceil(
-                      (data.miaoRedBoxNumber - areadyMiao) / data.rowNumber
-                    ) > data.writeBoxNumber
+                    Math.ceil((data.miaoRedBoxNumber - areadyMiao) / data.rowNumber) > data.writeBoxNumber
                       ? data.writeBoxNumber
-                      : Math.ceil(
-                          (data.miaoRedBoxNumber - areadyMiao) / data.rowNumber
-                        );
+                      : Math.ceil((data.miaoRedBoxNumber - areadyMiao) / data.rowNumber);
                   for (let j = 0; j < m; j++) {
                     let miaoArr = [];
                     for (let l = 0; l < data.rowNumber; l++) {
-                      if (
-                        j * data.rowNumber + l <
-                        data.miaoRedBoxNumber - areadyMiao
-                      ) {
+                      if (j * data.rowNumber + l < data.miaoRedBoxNumber - areadyMiao) {
                         miaoArr[l] = {
                           con: item.con,
                           miaoRed: true,
@@ -863,11 +793,7 @@ export default {
           }
           // 书写内容
           if (data.writeBoxNumber > 0) {
-            for (
-              let w = 0;
-              w < Number(sentence) * Number(data.writeBoxNumber);
-              w++
-            ) {
+            for (let w = 0; w < Number(sentence) * Number(data.writeBoxNumber); w++) {
               let sentenceItemWrite = [];
               for (let j = 0; j < data.rowNumber; j++) {
                 sentenceItemWrite.push({});
@@ -875,10 +801,7 @@ export default {
               sentenceArr.push(JSON.parse(JSON.stringify(sentenceItemWrite)));
             }
           }
-          sentenceArr = sentenceArr.slice(
-            0,
-            Number(sentence) * Number(data.writeBoxNumber)
-          );
+          sentenceArr = sentenceArr.slice(0, Number(sentence) * Number(data.writeBoxNumber));
           sentenceArr.forEach((itemS, indexS) => {
             allArr.push(JSON.parse(JSON.stringify(itemS)));
           });
@@ -903,7 +826,7 @@ export default {
                 itemss.hzDetail = {
                   hz_json: null,
                 };
-                this.$set(data.result[index][indexs][indexss], "hzDetail", res);
+                this.$set(data.result[index][indexs][indexss], 'hzDetail', res);
               }
             });
           });
@@ -928,7 +851,7 @@ export default {
     // 字句详情
     getdetai() {
       this.loading = true;
-      let Mname = "tr_tool-wsc_manager-GetWordSentenceCard";
+      let Mname = 'tr_tool-wsc_manager-GetWordSentenceCard';
       LearnWebSI(Mname, {
         id: this.$route.query.id,
       })
@@ -939,20 +862,20 @@ export default {
           // 初始化 from 表单
           for (let key in this.from) {
             if (this.writeTableData[key]) {
-              if (key == "fontSize") {
-                if (this.writeTableData[key] == "48px") {
-                  this.from[key] = "big";
-                } else if (this.writeTableData[key] == "38px") {
-                  this.from[key] = "center";
+              if (key == 'fontSize') {
+                if (this.writeTableData[key] == '48px') {
+                  this.from[key] = 'big';
+                } else if (this.writeTableData[key] == '38px') {
+                  this.from[key] = 'center';
                 } else {
-                  this.from[key] = "little";
+                  this.from[key] = 'little';
                 }
               } else {
                 this.from[key] = this.writeTableData[key];
               }
             }
           }
-          if (res.type == "WORD") {
+          if (res.type == 'WORD') {
             this.typeIndex = 0;
           } else {
             this.typeIndex = 1;
@@ -983,29 +906,29 @@ export default {
   destoryed() {},
   //如果页面有keep-alive缓存功能,这个函数会触发
   activated() {
-    if (this.$route.query.cachesType == "pop") {
-      this.saveName = "";
+    if (this.$route.query.cachesType == 'pop') {
+      this.saveName = '';
       this.typeIndex = 0;
       this.from = {
-        content: "",
+        content: '',
         BoxbgType: 0,
-        fontSize: "center",
+        fontSize: 'center',
         playStorkes: true,
         StorkesUnfold: true,
-        writeBoxNumber: "0", //书写行
-        miaoRedBoxNumber: "0", //描红格
-        lastNullrow: "0", //文本末空行数
-        miaoRedBgcolor: "#E1E1E1", //描红底色
-        writeColor: "#000000", //书写颜色
-        borderColor: "#D65353", //边框颜色
-        fontColor: "#000000", //文字颜色
+        writeBoxNumber: '0', //书写行
+        miaoRedBoxNumber: '0', //描红格
+        lastNullrow: '0', //文本末空行数
+        miaoRedBgcolor: '#E1E1E1', //描红底色
+        writeColor: '#000000', //书写颜色
+        borderColor: '#D65353', //边框颜色
+        fontColor: '#000000', //文字颜色
       };
       this.loading = false;
       this.writeTableData = null;
       this.isCread = false;
       this.isPreview = false;
       this.previewIndex = 0;
-      this.htmlTitle = "1";
+      this.htmlTitle = '1';
       this.saveShow = false;
       this.writetableShow = true;
       if (this.$route.query.id) {
@@ -1263,4 +1186,4 @@ export default {
     }
   }
 }
-</style>
+</style>