Result.vue 53 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705
  1. <template>
  2. <div class="result" v-loading="loading">
  3. <Header
  4. :projectShow="true"
  5. :seekShow="true"
  6. :seekOption="false"
  7. :seekOptions="true"
  8. @changehzdata="getdata(true)"
  9. />
  10. <div class="main">
  11. <div class="hanzi_list">
  12. <el-select
  13. class="selectBook"
  14. v-model="level"
  15. multiple
  16. collapse-tags
  17. placeholder="请选择"
  18. @change="page1getdata"
  19. >
  20. <el-checkbox
  21. class="checkAllCheckbox"
  22. :indeterminate="isIndeterminate"
  23. v-model="checkAll"
  24. @change="handleCheckAllChange"
  25. >全部</el-checkbox
  26. >
  27. <el-option v-for="item in levelList" :key="item.value" :label="item.label" :value="item.value"> </el-option>
  28. </el-select>
  29. <div class="top_jf">
  30. <div class="j_f">
  31. <div :class="[JFIndex == 0 ? 'sele' : '']" @click="jfEvent(0)">简</div>
  32. <div :class="[JFIndex == 1 ? 'sele' : '']" @click="jfEvent(1)">繁</div>
  33. </div>
  34. </div>
  35. <div
  36. class="list_one_box"
  37. :style="{
  38. overflowY: unfold ? 'scroll' : 'hidden',
  39. }"
  40. v-if="ShowHzData"
  41. >
  42. <div class="list_one" v-for="(item, index) in ShowHzData" :key="'index' + index">
  43. <Strockplayredline
  44. v-if="item.hzDetail.hz_json"
  45. :Book_text="JFIndex == 0 ? item.con : item.fanti"
  46. :playStorkes="true"
  47. :curItem="item.hzDetail"
  48. :targetDiv="'bwcHanziIntp' + index + item.con"
  49. :isHighlight="false"
  50. :judgeAnswer="2"
  51. />
  52. <div class="Highlight" v-if="item.hzDetail.hz_json && item.hzDetail.hz_json.medians">
  53. <div class="play_audio">
  54. <!-- <img src="../../assets/teacherdev/speaker-one.png" alt="" /> -->
  55. <span>{{ item.pinyin }}</span>
  56. </div>
  57. <div v-for="(items, indexs) in item.hzDetail.hz_json.medians.length" :key="'row' + indexs" class="row">
  58. <StrockplayredlineCorpus
  59. :Book_text="JFIndex == 0 ? item.con : item.fanti"
  60. :playStorkes="false"
  61. :curItem="item.hzDetail"
  62. :targetDiv="'bwcHanziIntp_height' + index + item.con + indexs"
  63. :targetDivGray="'bwcHanziIntp_height_Grey' + index + item.con + indexs"
  64. :isHighlight="true"
  65. :judgeAnswer="indexs + 1"
  66. :BoxbgType="0"
  67. strokeColorgray="#ccc"
  68. strokeColor="#000000"
  69. />
  70. <div class="number">{{ indexs + 1 }}</div>
  71. </div>
  72. </div>
  73. </div>
  74. </div>
  75. <div class="shouqi" v-if="hzData && hzData.length > 2">
  76. <span @click="updownHz">
  77. <template v-if="unfold">
  78. <img src="../../assets/teacherdev/up.png" alt="" />
  79. 收起
  80. </template>
  81. <template v-else>
  82. <img src="../../assets/teacherdev/down.png" alt="" />
  83. 展开
  84. </template>
  85. </span>
  86. </div>
  87. </div>
  88. <div class="txt_imgtable">
  89. <div class="left">
  90. <div class="top">
  91. <div>
  92. <div class="pattern">
  93. <div :class="[patternIndex == 0 ? 'sele' : '']" @click="cutPattern(0)">引语模式</div>
  94. <div :class="[patternIndex == 1 ? 'sele' : '']" @click="cutPattern(1)">KWIC模式</div>
  95. </div>
  96. <template v-if="patternIndex == 1">
  97. <div class="KWIC_sort">
  98. <span
  99. :class="['sort', KWIC_sortIndex == 0 ? 'sele' : '']"
  100. @click="KWICsortEvent(0, 'sentence_list_sort_left')"
  101. >
  102. <img src="../../assets/teacherdev/analys-right.png" alt="" />
  103. </span>
  104. <span
  105. :class="['sort', KWIC_sortIndex == 1 ? 'sele' : '']"
  106. @click="KWICsortEvent(1, 'sentence_list_sort_mid')"
  107. >
  108. <img src="../../assets/teacherdev/analys-center.png" alt="" />
  109. </span>
  110. <span
  111. :class="['sort', KWIC_sortIndex == 2 ? 'sele' : '']"
  112. @click="KWICsortEvent(2, 'sentence_list_sort_right')"
  113. >
  114. <img src="../../assets/teacherdev/analys-left.png" alt="" />
  115. </span>
  116. </div>
  117. </template>
  118. <!-- <template v-if="patternIndex == 0">
  119. <div class="lang_sort" @click="sortEvent">
  120. 长度
  121. <img v-if="sort == 'down'" src="../../assets/teacherdev/ylk-sort-down.png" alt="" />
  122. <img v-else-if="sort == 'up'" src="../../assets/teacherdev/ylk-sort-up.png" alt="" />
  123. <img v-else src="../../assets/teacherdev/ylk-sort-no.png" alt="" />
  124. </div>
  125. </template> -->
  126. <div class="refresh" @click="handleRefresh">
  127. <img src="../../assets/teacherdev/refresh.png" alt="" />
  128. </div>
  129. <template v-if="patternIndex == 0">
  130. <!-- <el-switch
  131. v-model="pinyinShow"
  132. active-text="拼音"
  133. active-color="#424242"
  134. style="margin-left: 24px"
  135. >
  136. </el-switch> -->
  137. <el-switch v-model="shiyiShow" active-text="释义" active-color="#424242" style="margin-left: 20px">
  138. </el-switch>
  139. </template>
  140. <el-switch v-model="fenciShow" active-text="分词" active-color="#424242" style="margin-left: 8px">
  141. </el-switch>
  142. </div>
  143. <div class="size">
  144. <span :class="[sizeIndex == 0 ? 'sele' : '']" @click="cutSize(0)">大</span>
  145. <span :class="[sizeIndex == 1 ? 'sele' : '']" @click="cutSize(1)">中</span>
  146. <span :class="[sizeIndex == 2 ? 'sele' : '']" @click="cutSize(2)">小</span>
  147. </div>
  148. </div>
  149. <div class="main">
  150. <div class="list">
  151. <template v-if="patternIndex == 0">
  152. <div class="lang_sort" :class="[sortType === 'length' ? 'active' : '']" @click="sortEvent('length')">
  153. 按长度
  154. <img
  155. v-if="sort == 'down' && sortType === 'length'"
  156. src="../../assets/teacherdev/ylk-sort-up.png"
  157. alt=""
  158. />
  159. <img
  160. v-else-if="sort == 'up' && sortType === 'length'"
  161. src="../../assets/teacherdev/ylk-sort-down.png"
  162. alt=""
  163. />
  164. <img v-else src="../../assets/teacherdev/ylk-sort-no.png" alt="" />
  165. </div>
  166. <div v-for="(item, i) in ShowList" :key="i + 'sentence'" class="one">
  167. <div class="top">
  168. <!--
  169. :class="['number-' + sizeIndex + '-' + pinyinShow]"
  170. -->
  171. <div class="number">{{ item.number }}.</div>
  172. <!--
  173. :class="['speaker-' + sizeIndex + '-' + pinyinShow]"
  174. -->
  175. <!-- <img src="../../assets/teacherdev/speaker-one.png" alt="" /> -->
  176. <div class="words">
  177. <template v-if="item.sentence_fc_list_style && item.sentence_fc_list_style.length > 1">
  178. <span
  179. :style="{
  180. fontSize: conSize + 'px',
  181. padding: fenciShow ? '0 2px' : '',
  182. }"
  183. v-for="(items, indexs) in item.sentence_fc_list_style"
  184. :key="indexs"
  185. v-html="items"
  186. ></span>
  187. </template>
  188. <template v-else>
  189. <span
  190. :style="{
  191. fontSize: conSize + 'px',
  192. padding: fenciShow ? '0 2px' : '',
  193. }"
  194. v-html="item.res"
  195. ></span>
  196. </template>
  197. <template v-if="shiyiShow && item.word_definition_list.length > 0">
  198. <span class="shiyi">
  199. <span v-for="(items, indexs) in item.word_definition_list" :key="indexs" v-html="items">
  200. </span>
  201. </span>
  202. </template>
  203. </div>
  204. <!--
  205. :class="['shiyi-' + sizeIndex]"
  206. -->
  207. </div>
  208. <div class="bottom">
  209. {{ item.source_courseware_name_path }}
  210. </div>
  211. </div>
  212. </template>
  213. <template v-else>
  214. <div style="display: flex">
  215. <div
  216. class="lang_sort"
  217. :class="[sortType === 'zflength' ? 'active' : '']"
  218. @click="sortEvent('zflength')"
  219. >
  220. 按字符
  221. <img
  222. v-if="sort == 'down' && sortType === 'zflength'"
  223. src="../../assets/teacherdev/ylk-sort-up.png"
  224. alt=""
  225. />
  226. <img
  227. v-else-if="sort == 'up' && sortType === 'zflength'"
  228. src="../../assets/teacherdev/ylk-sort-down.png"
  229. alt=""
  230. />
  231. <img v-else src="../../assets/teacherdev/ylk-sort-no.png" alt="" />
  232. </div>
  233. <div
  234. class="lang_sort"
  235. :class="[sortType === 'pclength' ? 'active' : '']"
  236. @click="sortEvent('pclength')"
  237. >
  238. 按频次
  239. <img
  240. v-if="sort == 'down' && sortType === 'pclength'"
  241. src="../../assets/teacherdev/ylk-sort-up.png"
  242. alt=""
  243. />
  244. <img
  245. v-else-if="sort == 'up' && sortType === 'pclength'"
  246. src="../../assets/teacherdev/ylk-sort-down.png"
  247. alt=""
  248. />
  249. <img v-else src="../../assets/teacherdev/ylk-sort-no.png" alt="" />
  250. </div>
  251. </div>
  252. <div v-for="(item, index) in ShowList" :key="'kwic' + index" class="kwic_one">
  253. <div class="number">{{ item.number }}</div>
  254. <el-tooltip effect="dark" placement="bottom">
  255. <div slot="content">
  256. {{ item.source_courseware_name_path }}
  257. </div>
  258. <div class="laiyuan">
  259. {{ item.source_courseware_name_path }}
  260. </div>
  261. </el-tooltip>
  262. <div
  263. class="word"
  264. :style="{
  265. fontSize: conSize + 'px',
  266. }"
  267. >
  268. <div v-for="(txt, indexs) in item.resArr" :key="indexs">
  269. <div
  270. :style="{ padding: fenciShow ? '0 2px' : '', display: 'inline-block' }"
  271. v-for="(txts, indext) in txt"
  272. :key="indext"
  273. >
  274. <!-- <span v-html="txts"></span> -->
  275. <template v-if="sortType === 'pclength' && (KWIC_sortIndex === 0 || KWIC_sortIndex === 2)">
  276. <template v-if="indexs === 0 && KWIC_sortIndex === 0">
  277. <el-tooltip effect="dark" placement="bottom" style="display: inline">
  278. <div slot="content">
  279. {{
  280. item.adjoin_fc_frequency_list_left && item.adjoin_fc_frequency_list_left[indext]
  281. ? item.adjoin_fc_frequency_list_left[indext]
  282. : 1
  283. }}
  284. </div>
  285. <div class="">
  286. <span v-html="txts"></span>
  287. </div>
  288. </el-tooltip>
  289. </template>
  290. <template v-else-if="indexs === 2 && KWIC_sortIndex === 2">
  291. <el-tooltip effect="dark" placement="bottom" style="display: inline">
  292. <div slot="content">
  293. {{
  294. item.adjoin_fc_frequency_list_right && item.adjoin_fc_frequency_list_right[indext]
  295. ? item.adjoin_fc_frequency_list_right[indext]
  296. : 1
  297. }}
  298. </div>
  299. <div class="">
  300. <span v-html="txts"></span>
  301. </div>
  302. </el-tooltip>
  303. </template>
  304. <template v-else>
  305. <span v-html="txts"></span>
  306. </template>
  307. </template>
  308. <template v-else>
  309. <span v-html="txts"></span>
  310. </template>
  311. </div>
  312. </div>
  313. </div>
  314. </div>
  315. </template>
  316. </div>
  317. <div class="page">
  318. <span class="text">
  319. 共 {{ selectCurrent ? selectCurrent : CurrentList.length }} 条
  320. {{
  321. patternIndex === 0 && selectLaiyuanBookIdList.length === 0 ? ' 命中 ' + scoreAHitNumber + ' 次' : ''
  322. }}
  323. </span>
  324. <el-pagination
  325. background
  326. @current-change="handleCurrentChange"
  327. :current-page.sync="page"
  328. :page-size="pageSize"
  329. layout="prev, pager, next"
  330. :total="selectCurrent ? selectCurrent : CurrentList.length"
  331. :pager-count="5"
  332. >
  333. </el-pagination>
  334. </div>
  335. </div>
  336. </div>
  337. <div class="right">
  338. <div class="top">
  339. <div>
  340. <div
  341. v-if="allList.stat_list_word_definition && allList.stat_list_word_definition.length > 0"
  342. :class="[rightTopIndex == 0 ? 'sele' : '']"
  343. @click="cutsyly(0)"
  344. >
  345. 释义
  346. </div>
  347. <div :class="[rightTopIndex == 1 ? 'sele' : '']" @click="cutsyly(1)">来源</div>
  348. </div>
  349. </div>
  350. <div id="shanxing_main" style="height: 398px"></div>
  351. <div class="list" v-if="rightList.length > 0">
  352. <div
  353. v-for="(item, i) in rightList"
  354. :key="i + 'right'"
  355. class="one"
  356. :style="{
  357. borderBottom: i == rightList.length - 1 ? 'none' : '1px solid #eeeeee',
  358. backgroundColor: selectLaiyuanBookIdList.indexOf(item.book_id) > -1 ? '#F2F3F5' : '',
  359. }"
  360. @mouseover="gaolangbzt(i, 'shanxing_main')"
  361. @mouseout="closegaolangbzt(i, 'shanxing_main')"
  362. @click="handleBookLiju(item.book_id)"
  363. >
  364. <div style="width: 60%">
  365. <span></span>
  366. <span v-html="item.book_name_s"></span>
  367. </div>
  368. <div style="width: 10%">
  369. <span>{{ item.count }}</span>
  370. </div>
  371. <div style="width: 30%">
  372. <span>{{ item.percent }}%</span>
  373. </div>
  374. </div>
  375. <div class="one all">
  376. <div style="width: 60%">
  377. <span></span>
  378. <span>合计</span>
  379. </div>
  380. <div style="width: 10%">
  381. <span>{{ allNumber }}</span>
  382. </div>
  383. <div style="width: 30%">
  384. <span>100%</span>
  385. </div>
  386. </div>
  387. </div>
  388. </div>
  389. </div>
  390. </div>
  391. </div>
  392. </template>
  393. <script>
  394. //这里可以导入其它文件(比如:组件,工具js,第三方插件js,json文件,图片文件等等)
  395. //例如:import 《组件名称》from ‘《组件路径》';
  396. import Header from '@/components/Header';
  397. import { getLogin, BookgetContent } from '@/api/api';
  398. import Strockplayredline from '@/components/corpus/Strockplayredline';
  399. import StrockplayredlineCorpus from '@/components/corpus/StrockplayredlineCorpus';
  400. import '@/utils/pinyin_dict_withtone';
  401. import '@/utils/pinyinUtil';
  402. const OpenCC = require('opencc-js');
  403. const converter = OpenCC.Converter({ from: 'cn', to: 'tw' });
  404. import * as echarts from 'echarts';
  405. export default {
  406. //import引入的组件需要注入到对象中才能使用
  407. components: {
  408. Header,
  409. Strockplayredline,
  410. StrockplayredlineCorpus,
  411. },
  412. props: {},
  413. data() {
  414. //这里存放数据
  415. return {
  416. page: 1,
  417. pageSize: 30,
  418. shiyiShow: true,
  419. fenciShow: false,
  420. pinyinShow: true,
  421. JFIndex: 0,
  422. hzData: [],
  423. ShowHzData: [],
  424. loading: true,
  425. lang: null,
  426. unfold: true,
  427. patternIndex: 0,
  428. rightTopIndex: 0,
  429. sizeIndex: 1,
  430. sort: '',
  431. sortType: '',
  432. rightList: [],
  433. KWIC_sortIndex: 0,
  434. allNumber: 0,
  435. conSize: 20,
  436. pinyinSize: 12,
  437. allList: [],
  438. CurrentList: [],
  439. ShowList: [],
  440. chsFhList: [',', '。', '”', ':', '》', '《', '?', '!', ';'],
  441. scoreAHitNumber: 0,
  442. level: [],
  443. checkAll: false,
  444. isIndeterminate: true,
  445. allLevels: [],
  446. levelList: [],
  447. selectLaiyuanBookIdList: [], // 选中右侧来源书籍列表id
  448. selectCurrent: 0,
  449. };
  450. },
  451. //计算属性 类似于data概念
  452. computed: {},
  453. //监控data中数据变化
  454. watch: {},
  455. //方法集合
  456. methods: {
  457. handleCurrentChange(val) {
  458. this.page = val;
  459. this.padingEvetn();
  460. },
  461. // KWIC排序
  462. KWICsortEvent(index, type) {
  463. if (this.KWIC_sortIndex == index) return;
  464. this.KWIC_sortIndex = index;
  465. // this.CurrentList = this.allList[type];
  466. // this.padingEvetn();
  467. this.getdata();
  468. },
  469. // 排序
  470. sortEvent(type) {
  471. this.sortType = type;
  472. if (this.sort == 'up' || !this.sort) {
  473. this.sort = 'down';
  474. } else {
  475. this.sort = 'up';
  476. }
  477. this.getdata();
  478. this.page = 1;
  479. },
  480. // 修改大小
  481. cutSize(index) {
  482. this.sizeIndex = index;
  483. if (index == 0) {
  484. //大
  485. if (this.patternIndex == 0) {
  486. this.conSize = 24;
  487. this.pinyinSize = 12;
  488. } else {
  489. this.conSize = 20;
  490. }
  491. } else if (index == 1) {
  492. //中
  493. if (this.patternIndex == 0) {
  494. this.conSize = 20;
  495. this.pinyinSize = 12;
  496. } else {
  497. this.conSize = 17;
  498. }
  499. } else {
  500. //小
  501. if (this.patternIndex == 0) {
  502. this.conSize = 16;
  503. this.pinyinSize = 10;
  504. } else {
  505. this.conSize = 15;
  506. }
  507. }
  508. },
  509. // 切换模式
  510. cutPattern(index) {
  511. if (this.patternIndex == index) {
  512. return;
  513. }
  514. this.patternIndex = index;
  515. this.getdata();
  516. // if (this.patternIndex == 0) {
  517. // this.CurrentList = JSON.parse(JSON.stringify(this.allList.sentence_list));
  518. // } else {
  519. // this.CurrentList = JSON.parse(JSON.stringify(this.allList.sentence_list_sort_left));
  520. // }
  521. // this.padingEvetn();
  522. this.page = 1;
  523. },
  524. // 切换释义来源
  525. cutsyly(index) {
  526. if (this.rightTopIndex == index) {
  527. return;
  528. }
  529. this.rightTopIndex = index;
  530. if (this.rightTopIndex == 0) {
  531. this.rightList = this.allList.stat_list_word_definition;
  532. } else {
  533. this.rightList = this.allList.stat_list_sentence_source_book;
  534. }
  535. // if (this.rightList.length > 0) {
  536. this.inityuan();
  537. // }
  538. },
  539. updownHz(flag) {
  540. if (flag === true) {
  541. this.unfold = false;
  542. this.ShowHzData.splice(2);
  543. } else {
  544. this.unfold = !this.unfold;
  545. if (this.unfold) {
  546. this.ShowHzData = JSON.parse(JSON.stringify(this.hzData));
  547. } else {
  548. this.ShowHzData.splice(2);
  549. }
  550. }
  551. },
  552. jfEvent(index) {
  553. this.JFIndex = index;
  554. if (index == 0) {
  555. //简体
  556. this.gethzJSON();
  557. } else {
  558. //繁体
  559. this.hzData.forEach((item) => {
  560. let a = converter(item.con);
  561. item.fanti = a;
  562. });
  563. this.gethzJSON();
  564. }
  565. },
  566. // 获取汉字josn
  567. gethzJSON() {
  568. this.ShowHzData = null;
  569. this.loading = true;
  570. let MethodName = 'hz_resource_manager-GetHZStrokesContent';
  571. this.hzData.forEach((item, i) => {
  572. let data = {
  573. hz: this.JFIndex == 0 ? item.con : item.fanti,
  574. };
  575. item.hzDetail = {
  576. hz_json: null,
  577. };
  578. this.$forceUpdate();
  579. getLogin(MethodName, data)
  580. .then((res) => {
  581. this.$set(item.hzDetail, 'hz_json', res);
  582. this.$forceUpdate();
  583. this.ShowHzData = JSON.parse(JSON.stringify(this.hzData));
  584. this.updownHz(true);
  585. if (i == this.hzData.length - 1) {
  586. this.loading = false;
  587. }
  588. })
  589. .catch(() => {
  590. this.loading = false;
  591. });
  592. });
  593. },
  594. getrightListdata() {
  595. this.inityuan();
  596. },
  597. inityuan() {
  598. var chartDom = document.getElementById('shanxing_main');
  599. var myChart = echarts.init(chartDom);
  600. var option;
  601. this.allNumber = 0;
  602. let newdata = JSON.parse(JSON.stringify(this.rightList));
  603. newdata.forEach((item) => {
  604. this.allNumber += item.count;
  605. let percent = item.percent;
  606. item.value = item.count;
  607. if (percent % 1 == 0) {
  608. item.name = item.book_name + ' ' + percent + '%';
  609. } else {
  610. item.name = item.book_name + ' ' + percent.toFixed(2) + '%';
  611. }
  612. });
  613. option = {
  614. series: [
  615. {
  616. name: 'Access From',
  617. type: 'pie',
  618. // radius: ["50%", "50%"],
  619. data: newdata.length > 0 ? newdata : [],
  620. itemStyle: {
  621. // borderColor: "#fff",
  622. // borderWidth: 2,
  623. },
  624. top: 50,
  625. emphasis: {
  626. itemStyle: {
  627. shadowBlur: 10,
  628. shadowOffsetX: 0,
  629. shadowColor: 'rgba(0, 0, 0, 0.5)',
  630. },
  631. },
  632. },
  633. ],
  634. xAxis: {
  635. show: false, //不显示坐标轴线、坐标轴刻度线和坐标轴上的文字
  636. axisTick: {
  637. show: false, //不显示坐标轴刻度线
  638. },
  639. axisLine: {
  640. show: false, //不显示坐标轴线
  641. },
  642. axisLabel: {
  643. show: false, //不显示坐标轴上的文字
  644. },
  645. },
  646. };
  647. option && myChart.setOption(option);
  648. if (this.rightTopIndex === 1) {
  649. let number = 0;
  650. let _this = this;
  651. myChart.on('click', function (param) {
  652. //添加点击事件
  653. myChart.dispatchAction({ type: 'highlight', dataIndex: param.dataIndex }); //激活点击区域高亮
  654. if (param.dataIndex !== number) {
  655. // 当鼠标点击的时候 消除上一个扇区的高亮
  656. myChart.dispatchAction({ type: 'downplay', dataIndex: number });
  657. }
  658. number = param.dataIndex; //接住当前扇区的dataIndex
  659. _this.handleBookLiju(param.data.book_id);
  660. });
  661. }
  662. },
  663. // 鼠标进入
  664. gaolangbzt(index, id) {
  665. var compareChart = echarts.getInstanceByDom(document.getElementById(id));
  666. compareChart.dispatchAction({
  667. type: 'highlight',
  668. seriesIndex: 0,
  669. dataIndex: index,
  670. });
  671. },
  672. // 鼠标移出
  673. closegaolangbzt(index, id) {
  674. var compareChart = echarts.getInstanceByDom(document.getElementById(id));
  675. compareChart.dispatchAction({
  676. type: 'downplay',
  677. seriesIndex: 0,
  678. dataIndex: index,
  679. });
  680. },
  681. // 计算选中教材例句
  682. handleBookLiju(id) {
  683. if (!id) return false;
  684. if (this.selectLaiyuanBookIdList.indexOf(id) > -1) {
  685. this.selectLaiyuanBookIdList.splice(this.selectLaiyuanBookIdList.indexOf(id), 1);
  686. } else {
  687. this.selectLaiyuanBookIdList.push(id);
  688. }
  689. this.padingEvetn();
  690. this.page = 1;
  691. },
  692. changehzdata() {
  693. this.hzData = [];
  694. this.jfEvent(0);
  695. let arr = this.$route.query.keyword.trim().split('');
  696. arr.forEach((item) => {
  697. if (!/^[\u4e00-\u9fa5]/.test(item)) {
  698. return;
  699. }
  700. let result = pinyinUtil.getPinyin(item);
  701. let obj = {
  702. con: item,
  703. pinyin: result,
  704. hzDetail: {
  705. hz_json: null,
  706. },
  707. };
  708. this.hzData.push(obj);
  709. this.ShowHzData = JSON.parse(JSON.stringify(this.hzData));
  710. });
  711. this.gethzJSON();
  712. },
  713. handleRefresh() {
  714. this.pinyinShow = true;
  715. this.shiyiShow = true;
  716. this.fenciShow = true;
  717. this.sizeIndex = 1;
  718. this.sort = '';
  719. this.sortType = '';
  720. this.KWIC_sortIndex = 0;
  721. this.cutSize(1);
  722. this.getdata();
  723. this.page = 1;
  724. },
  725. getdata(flag) {
  726. this.loading = true;
  727. this.scoreAHitNumber = 0;
  728. let Mname = 'book-courseware_manager-GetCoursewareWordExampleSentenceList_Sort';
  729. let data = {
  730. // courseware_id: "003-20211012-17-BDUZ1JVCAN",
  731. courseware_id: '',
  732. // word: this.$route.query.keyword, // 单词
  733. word: this.$route.query.keyword.trim(),
  734. search_scope: 3, // 检索范围 0 【本章】,1【本教材】,2【本套教材】,3【系统所有教材】
  735. // 本章:同一本教材下,归属同一个第一级章节下的所有课件为同一章。
  736. is_contain_word_variants: false, // 是否包含单词变体例句
  737. is_contain_stat_data: true, //是否包统计数据
  738. is_filter_repetitive_sentence: 'true', // 过滤重复例句
  739. sort_mode: this.sort ? (this.sort == 'down' ? 'DESCENT' : 'ASCENT') : 'NO', // 排序模式 NO 【不排序】,ASCENT【顺序】,DESCENT【倒序】
  740. compare_mode: this.patternIndex === 0 ? 'LENGTH' : 'KWIC', // 排序比较模式,LENGTH【例句长度】,KWIC【KWIC 模式】
  741. kwic_arrange_type: this.KWIC_sortIndex === 0 ? 'LEFT' : this.KWIC_sortIndex === 1 ? 'MID' : 'RIGHT', // KWIC 排列类型, LEFT【左】,MID【中】,RIGHT【右】
  742. kwic_compare_by: this.sortType === 'pclength' ? 1 : 0, // KWIC 排序比较依据,0【字符】,1【相邻的搭配词出现的次数】
  743. book_publish_status: -1, // 教材发布状态 -1【全部】, 0【下架】1【上架】
  744. book_id_list: this.level, // 指定教材查询,空表示在检索范围内检索所有教材。
  745. sentence_fc_length_min:
  746. localStorage.getItem('seekPageData') && JSON.parse(localStorage.getItem('seekPageData')).sentenceStart
  747. ? Number(JSON.parse(localStorage.getItem('seekPageData')).sentenceStart)
  748. : -1, // 例句分词长度范围(最小值),-1 表示不检测最小值
  749. sentence_fc_length_max:
  750. localStorage.getItem('seekPageData') && JSON.parse(localStorage.getItem('seekPageData')).sentenceEnd
  751. ? Number(JSON.parse(localStorage.getItem('seekPageData')).sentenceEnd)
  752. : -1, // 例句分词长度范围(最大值),-1 表示不检测最大值
  753. };
  754. BookgetContent(Mname, data)
  755. .then((res) => {
  756. this.allList = {
  757. sentence_list: [],
  758. sentence_list_sort_left: [],
  759. sentence_list_sort_mid: [],
  760. sentence_list_sort_right: [],
  761. stat_list_sentence_source_book: res.stat_list_sentence_source_book,
  762. stat_list_word_definition: res.stat_list_word_definition,
  763. };
  764. if (res.sentence_list.length > 0) {
  765. res.stat_list_word_definition.forEach((item) => {
  766. item.book_name_s = item.definition;
  767. item.book_name = JSON.parse(JSON.stringify(item.definition)).replace(/<i>/g, '').replace(/<\/i>/g, '');
  768. });
  769. res.stat_list_sentence_source_book.forEach((item) => {
  770. item.book_name_s = item.book_name;
  771. });
  772. // 清理脏数据
  773. this.removeRubbishData(res);
  774. if (res.stat_list_word_definition.length === 0) {
  775. this.rightTopIndex = 1;
  776. }
  777. if (this.rightTopIndex === 0) {
  778. this.rightList = res.stat_list_word_definition;
  779. } else {
  780. this.rightList = res.stat_list_sentence_source_book;
  781. }
  782. this.getrightListdata();
  783. if (this.patternIndex === 0) {
  784. this.allList.sentence_list = this.handleExample(res.sentence_list);
  785. } else {
  786. if (this.KWIC_sortIndex === 0) {
  787. this.allList.sentence_list_sort_left = this.handleExample(res.sentence_list, 'left');
  788. } else if (this.KWIC_sortIndex === 1) {
  789. this.allList.sentence_list_sort_mid = this.handleExample(res.sentence_list, 'mid');
  790. } else {
  791. this.allList.sentence_list_sort_right = this.handleExample(res.sentence_list, 'right');
  792. }
  793. }
  794. this.CurrentList = JSON.parse(JSON.stringify(res.sentence_list));
  795. this.padingEvetn();
  796. } else {
  797. this.CurrentList = [];
  798. this.ShowList = [];
  799. this.rightList = [];
  800. this.getrightListdata();
  801. }
  802. if (this.$route.query.keyword.trim() && flag) {
  803. this.changehzdata();
  804. } else {
  805. this.loading = false;
  806. }
  807. if (res.word_pinyin_list) {
  808. res.word_pinyin_list.forEach((itemP, indexP) => {
  809. if (this.hzData[indexP]) {
  810. this.hzData[indexP].pinyin = itemP;
  811. }
  812. });
  813. }
  814. })
  815. .catch((err) => {
  816. this.loading = false;
  817. });
  818. },
  819. handleExample(list, type) {
  820. if (list.length > 0) {
  821. list = list.map((item, index) => {
  822. item.number = index + 1;
  823. let str = item.source_courseware_name_path;
  824. item.show_source_courseware_name_path = str.slice(0, 8) + '...';
  825. if (type == 'left') {
  826. let arr = JSON.parse(JSON.stringify(item.sentence_fc_list));
  827. arr.forEach((items, indexs) => {
  828. if (indexs == item.sentence_fc_list_word_index) {
  829. arr[indexs] = `<span style=color:#DE4444;font-weight:700;>${arr[indexs]}</span>`;
  830. }
  831. });
  832. let data = this.changefiveword(arr, item.sentence_fc_list_word_index, type);
  833. item.resArr = data;
  834. item.adjoin_fc_frequency_list_left = item.adjoin_fc_frequency_list.splice(
  835. 0,
  836. item.sentence_fc_list_word_index,
  837. );
  838. } else if (type == 'right') {
  839. let sentence = JSON.parse(JSON.stringify(item.sentence));
  840. let arr = JSON.parse(JSON.stringify(item.sentence_fc_list));
  841. arr.forEach((items, indexs) => {
  842. if (indexs == item.sentence_fc_list_word_index) {
  843. arr[indexs] = `<span style=color:#DE4444;font-weight:700;>${arr[indexs]}</span>`;
  844. }
  845. });
  846. let data = this.changefiveword(arr, item.sentence_fc_list_word_index, type);
  847. item.resArr = data;
  848. item.adjoin_fc_frequency_list_right = item.adjoin_fc_frequency_list.splice(
  849. item.sentence_fc_list_word_index + 1,
  850. );
  851. } else if (type == 'mid') {
  852. let sentence = JSON.parse(JSON.stringify(item.sentence));
  853. let arr = JSON.parse(JSON.stringify(item.sentence_fc_list));
  854. arr.forEach((items, indexs) => {
  855. if (indexs == item.sentence_fc_list_word_index) {
  856. arr[indexs] = `<span style=color:#DE4444;font-weight:700;>${arr[indexs]}</span>`;
  857. }
  858. });
  859. let data = this.changefiveword(arr, item.sentence_fc_list_word_index, type);
  860. item.resArr = data;
  861. } else {
  862. this.scoreAHitNumber += item.position_list.length;
  863. let sentence_fc_list_style = [];
  864. let newsentence = JSON.parse(JSON.stringify(item.sentence));
  865. let res = '';
  866. for (let i = 0; i < item.position_list.length; i++) {
  867. let part1 = '';
  868. let part2 = '';
  869. let part3 = '';
  870. if (item.position_list.length > 1) {
  871. if (i == 0) {
  872. part1 = newsentence.substring(0, item.position_list[i].begin);
  873. part2 = newsentence.substring(item.position_list[i].begin, item.position_list[i].end);
  874. part3 = newsentence.substring(item.position_list[i].end, item.position_list[i + 1].begin);
  875. } else if (i == item.position_list.length - 1) {
  876. part2 = newsentence.substring(item.position_list[i].begin, item.position_list[i].end);
  877. part3 = newsentence.substring(item.position_list[i].end);
  878. } else {
  879. part2 = newsentence.substring(item.position_list[i].begin, item.position_list[i].end);
  880. part3 = newsentence.substring(item.position_list[i].end, item.position_list[i + 1].begin);
  881. }
  882. } else {
  883. part1 = newsentence.substring(0, item.position_list[i].begin);
  884. part2 = newsentence.substring(item.position_list[i].begin, item.position_list[i].end);
  885. part3 = newsentence.substring(item.position_list[i].end);
  886. }
  887. res += part1 + '<span style="color:#DE4444;">' + part2 + '</span>' + part3;
  888. }
  889. item.res = res;
  890. item.sentence_fc_list.forEach((items, indexs) => {
  891. if (item.sentence_fc_list_word_index_list.indexOf(indexs) > -1) {
  892. sentence_fc_list_style.push('<span style="color:#DE4444;">' + items + '</span>');
  893. } else {
  894. sentence_fc_list_style.push(items);
  895. }
  896. });
  897. item.sentence_fc_list_style = sentence_fc_list_style;
  898. }
  899. return item;
  900. });
  901. return list;
  902. } else {
  903. return [];
  904. }
  905. },
  906. changefiveword(arr, index, type) {
  907. let num = 6;
  908. let colorIndex = 0;
  909. let colorList = ['#4D7EFF', '#A4430F', '#9342C5', '#FF8718', '#1DAA91'];
  910. for (let i = 1; i < num; i++) {
  911. if (type == 'left') {
  912. if (index - i >= 0) {
  913. if (this.chsFhList.indexOf(arr[index - i]) == -1) {
  914. arr[index - i] = `<span style=color:${colorList[colorIndex]};>${arr[index - i]}</span>`;
  915. colorIndex++;
  916. } else {
  917. num++;
  918. }
  919. }
  920. } else if (type == 'right') {
  921. if (index + i <= arr.length - 1) {
  922. if (this.chsFhList.indexOf(arr[index + i]) == -1) {
  923. arr[index + i] = `<span style=color:${colorList[colorIndex]};>${arr[index + i]}</span>`;
  924. colorIndex++;
  925. } else {
  926. num++;
  927. }
  928. }
  929. }
  930. }
  931. let newarr = [];
  932. let arr1 = [];
  933. let arr2 = [];
  934. let arr3 = [];
  935. arr.forEach((item, i) => {
  936. if (i < index) {
  937. arr1.push(item);
  938. } else if (i == index) {
  939. arr2.push(item);
  940. } else {
  941. arr3.push(item);
  942. }
  943. });
  944. newarr.push(arr1);
  945. newarr.push(arr2);
  946. newarr.push(arr3);
  947. return newarr;
  948. },
  949. // 处理分页
  950. padingEvetn() {
  951. let arr = JSON.parse(JSON.stringify(this.CurrentList));
  952. let arrs = [];
  953. if (this.selectLaiyuanBookIdList.length === 0) {
  954. arrs = arr;
  955. } else {
  956. arr.forEach((item) => {
  957. let path = item.source_courseware_id_path.split('/');
  958. if (path.length > 0 && this.selectLaiyuanBookIdList.indexOf(path[0]) > -1) {
  959. arrs.push(item);
  960. }
  961. });
  962. }
  963. this.selectCurrent = arrs.length;
  964. let newarr = arrs.splice((this.page - 1) * this.pageSize, this.pageSize);
  965. this.ShowList = JSON.parse(JSON.stringify(newarr));
  966. },
  967. // 删除脏数据
  968. removeRubbishData(data) {
  969. if (data.sentence_list.length > 0) {
  970. for (let i = data.sentence_list.length; i--; ) {
  971. if (
  972. data.sentence_list[i].sentence_fc_list.length <= 1 ||
  973. data.sentence_list[i].sentence_fc_list_word_index === -1
  974. ) {
  975. data.sentence_list.splice(i, 1);
  976. }
  977. }
  978. }
  979. },
  980. page1getdata(value) {
  981. if (value) {
  982. let checkedCount = value.length;
  983. this.checkAll = checkedCount === this.levelList.length;
  984. this.isIndeterminate = checkedCount > 0 && checkedCount < this.levelList.length;
  985. }
  986. },
  987. handleCheckAllChange(val) {
  988. this.level = val ? this.allLevels : [];
  989. this.isIndeterminate = false;
  990. },
  991. // 获取上架教材列表
  992. getLevelList() {
  993. this.allLevels = [];
  994. this.levelList = [];
  995. BookgetContent('book-book_manager-GetBookList', {
  996. publish_status: 1,
  997. }).then((res) => {
  998. this.loading = false;
  999. if (res.status === 1) {
  1000. res.book_list.forEach((item) => {
  1001. item.value = item.id;
  1002. item.label = item.name;
  1003. this.allLevels.push(item.id);
  1004. });
  1005. this.levelList = this.levelList.concat(res.book_list);
  1006. }
  1007. });
  1008. },
  1009. },
  1010. //生命周期 - 创建完成(可以访问当前this实例)
  1011. created() {
  1012. this.getLevelList();
  1013. },
  1014. //生命周期 - 挂载完成(可以访问DOM元素)
  1015. mounted() {
  1016. this.getdata(true);
  1017. },
  1018. //生命周期-创建之前
  1019. beforeCreated() {},
  1020. //生命周期-挂载之前
  1021. beforeMount() {},
  1022. //生命周期-更新之前
  1023. beforUpdate() {},
  1024. //生命周期-更新之后
  1025. updated() {},
  1026. //生命周期-销毁之前
  1027. beforeDestory() {},
  1028. //生命周期-销毁完成
  1029. destoryed() {},
  1030. //如果页面有keep-alive缓存功能,这个函数会触发
  1031. activated() {},
  1032. };
  1033. </script>
  1034. <style lang="scss" scoped>
  1035. /* @import url(); 引入css类 */
  1036. .result {
  1037. min-height: 100%;
  1038. > .main {
  1039. min-height: 100%;
  1040. padding-top: 33px;
  1041. padding-bottom: 66px;
  1042. background: #f2f2f2;
  1043. }
  1044. .hanzi_list {
  1045. position: relative;
  1046. box-sizing: border-box;
  1047. width: 1200px;
  1048. padding: 40px 13px;
  1049. margin: 0 auto;
  1050. background: #fff;
  1051. border-radius: 8px;
  1052. .selectBook {
  1053. position: absolute;
  1054. right: 13px;
  1055. top: 40px;
  1056. width: 180px;
  1057. .el-select__tags {
  1058. max-width: 135px;
  1059. }
  1060. }
  1061. .top_jf {
  1062. width: 128px;
  1063. }
  1064. .j_f {
  1065. display: flex;
  1066. width: 60px;
  1067. height: 24px;
  1068. margin-bottom: 16px;
  1069. margin-left: 33px;
  1070. > :nth-child(1) {
  1071. border-right: none;
  1072. border-top-left-radius: 2px;
  1073. border-bottom-left-radius: 2px;
  1074. }
  1075. > :nth-child(2) {
  1076. border-left: none;
  1077. border-top-right-radius: 2px;
  1078. border-bottom-right-radius: 2px;
  1079. }
  1080. div {
  1081. width: 30px;
  1082. height: 24px;
  1083. font-size: 14px;
  1084. font-weight: 400;
  1085. line-height: 24px;
  1086. color: #de4444;
  1087. text-align: center;
  1088. cursor: pointer;
  1089. border: 2px solid #de4444;
  1090. }
  1091. .sele {
  1092. color: #fff;
  1093. background: #de4444;
  1094. }
  1095. }
  1096. .list_one_box {
  1097. max-height: 750px;
  1098. padding: 0 27px;
  1099. &::-webkit-scrollbar-track-piece {
  1100. background: #fff;
  1101. }
  1102. &::-webkit-scrollbar {
  1103. width: 4px;
  1104. }
  1105. &::-webkit-scrollbar-thumb {
  1106. background: #d9d9d9;
  1107. border-radius: 20px;
  1108. }
  1109. }
  1110. .list_one {
  1111. display: flex;
  1112. align-items: flex-start;
  1113. margin-bottom: 20px;
  1114. .Highlight {
  1115. display: flex;
  1116. flex: 1;
  1117. flex-wrap: wrap;
  1118. margin-left: 22px;
  1119. .play_audio {
  1120. display: flex;
  1121. align-items: center;
  1122. width: 100%;
  1123. margin-bottom: 13px;
  1124. img {
  1125. width: 16px;
  1126. height: 16px;
  1127. cursor: pointer;
  1128. }
  1129. span {
  1130. margin-left: 5px;
  1131. font-family: 'League';
  1132. font-size: 12px;
  1133. font-weight: 400;
  1134. color: #000;
  1135. }
  1136. }
  1137. }
  1138. .row {
  1139. margin-right: 8px;
  1140. margin-bottom: 8px;
  1141. .number {
  1142. flex-shrink: 0;
  1143. width: 64px;
  1144. height: 20px;
  1145. margin-top: 9px;
  1146. line-height: 20px;
  1147. color: rgba(0, 0, 0, 50%);
  1148. text-align: center;
  1149. background: #f0f0f0;
  1150. border-radius: 22px;
  1151. }
  1152. }
  1153. }
  1154. .shouqi {
  1155. position: absolute;
  1156. right: 26px;
  1157. bottom: 13px;
  1158. display: flex;
  1159. justify-content: flex-end;
  1160. margin-top: 21;
  1161. span {
  1162. display: flex;
  1163. align-items: center;
  1164. font-size: 16px;
  1165. font-weight: 400;
  1166. line-height: 24px;
  1167. color: rgba(0, 0, 0, 50%);
  1168. cursor: pointer;
  1169. }
  1170. img {
  1171. width: 24px;
  1172. height: 24px;
  1173. margin-right: 4px;
  1174. }
  1175. }
  1176. }
  1177. .txt_imgtable {
  1178. display: flex;
  1179. width: 1200px;
  1180. margin: 0 auto;
  1181. margin-top: 8px;
  1182. .left {
  1183. position: relative;
  1184. width: 562px;
  1185. padding-bottom: 58px;
  1186. margin-right: 8px;
  1187. background: #fff;
  1188. border-bottom: 1px solid rgba(0, 0, 0, 8%);
  1189. border-radius: 8px;
  1190. > .top {
  1191. display: flex;
  1192. align-items: center;
  1193. justify-content: space-between;
  1194. height: 44px;
  1195. font-size: 12px;
  1196. font-weight: 400;
  1197. color: #000;
  1198. border-bottom: 1px solid rgba(0, 0, 0, 8%);
  1199. > div {
  1200. display: flex;
  1201. align-items: center;
  1202. }
  1203. .KWIC_sort {
  1204. display: flex;
  1205. margin-left: 24px;
  1206. span {
  1207. display: inline-block;
  1208. display: flex;
  1209. align-items: center;
  1210. justify-content: center;
  1211. width: 28px;
  1212. height: 28px;
  1213. cursor: pointer;
  1214. background: #fff;
  1215. border-radius: 4px;
  1216. }
  1217. .sele {
  1218. background: #f0f0f0;
  1219. }
  1220. .sort {
  1221. img {
  1222. width: 14px;
  1223. height: 12px;
  1224. }
  1225. }
  1226. .down {
  1227. img {
  1228. width: 16px;
  1229. height: 16px;
  1230. }
  1231. }
  1232. }
  1233. .pattern {
  1234. display: flex;
  1235. align-items: center;
  1236. justify-content: center;
  1237. width: 144px;
  1238. height: 28px;
  1239. margin-left: 16px;
  1240. background: #eee;
  1241. border-radius: 4px;
  1242. > div {
  1243. width: 68px;
  1244. height: 24px;
  1245. font-size: 12px;
  1246. font-weight: 400;
  1247. line-height: 24px;
  1248. color: #888;
  1249. text-align: center;
  1250. cursor: pointer;
  1251. border-radius: 2px;
  1252. }
  1253. .sele {
  1254. color: #000;
  1255. background: #fff;
  1256. box-shadow: 0 2px 2px rgba(0, 0, 0, 8%);
  1257. }
  1258. }
  1259. .refresh {
  1260. display: flex;
  1261. align-items: center;
  1262. justify-content: center;
  1263. width: 28px;
  1264. height: 28px;
  1265. margin-left: 8px;
  1266. cursor: pointer;
  1267. background: #eee;
  1268. border-radius: 4px;
  1269. img {
  1270. width: 16px;
  1271. height: 16px;
  1272. }
  1273. }
  1274. .size {
  1275. margin-right: 12px;
  1276. span {
  1277. padding: 4px;
  1278. font-size: 14px;
  1279. cursor: pointer;
  1280. }
  1281. .sele {
  1282. background: #e6e6e6;
  1283. border-radius: 4px;
  1284. }
  1285. }
  1286. }
  1287. .main {
  1288. // height: 95%;
  1289. .list {
  1290. margin-top: 16px;
  1291. .lang_sort {
  1292. display: flex;
  1293. align-items: center;
  1294. justify-content: center;
  1295. width: max-content;
  1296. cursor: pointer;
  1297. margin: 0 0 16px 16px;
  1298. border-radius: 20px;
  1299. border: 1px solid #e5e6eb;
  1300. padding: 4px 12px;
  1301. font-size: 14px;
  1302. &.active {
  1303. border-color: #4992ff;
  1304. background: #4992ff;
  1305. color: #fff;
  1306. }
  1307. img {
  1308. width: 16px;
  1309. height: 16px;
  1310. margin-left: 2px;
  1311. }
  1312. }
  1313. .one {
  1314. padding: 0 16px;
  1315. margin-bottom: 8px;
  1316. .top {
  1317. display: flex;
  1318. // align-items: center;
  1319. // flex-flow: wrap;
  1320. width: 100%;
  1321. .number {
  1322. flex-shrink: 0;
  1323. width: 22px;
  1324. margin-right: 8px;
  1325. font-size: 14px;
  1326. font-weight: 400;
  1327. line-height: 21px;
  1328. color: rgba(0, 0, 0, 30%);
  1329. text-align: right;
  1330. &-1-false {
  1331. margin-top: 3px;
  1332. }
  1333. &-0-true {
  1334. margin-top: 21px;
  1335. }
  1336. &-0-false {
  1337. margin-top: 5px;
  1338. }
  1339. &-2-true {
  1340. margin-top: 17px;
  1341. }
  1342. &-2-false {
  1343. margin-top: 1px;
  1344. }
  1345. }
  1346. img {
  1347. width: 16px;
  1348. height: 16px;
  1349. margin-right: 8px;
  1350. cursor: pointer;
  1351. &.speaker-1-false {
  1352. margin-top: 6px;
  1353. }
  1354. &.speaker-0-true {
  1355. margin-top: 24px;
  1356. }
  1357. &.speaker-0-false {
  1358. margin-top: 8px;
  1359. }
  1360. &.speaker-2-true {
  1361. margin-top: 20px;
  1362. }
  1363. &.speaker-2-false {
  1364. margin-top: 4px;
  1365. }
  1366. }
  1367. .words {
  1368. // display: flex;
  1369. // align-items: flex-end;
  1370. // flex-flow: wrap;
  1371. font-family: 'FZJCGFKTK';
  1372. word-break: break-all;
  1373. > div {
  1374. .pinyin {
  1375. margin-bottom: 2px;
  1376. font-family: 'League';
  1377. font-size: 12px;
  1378. font-weight: 500;
  1379. color: rgba(0, 0, 0, 50%);
  1380. text-align: center;
  1381. }
  1382. .con {
  1383. font-family: 'FZJCGFKTK';
  1384. font-size: 20px;
  1385. font-weight: 400;
  1386. color: #000;
  1387. text-align: center;
  1388. }
  1389. }
  1390. }
  1391. .shiyi {
  1392. font-size: 12px;
  1393. font-weight: 400;
  1394. line-height: 24px;
  1395. color: #48a3e6;
  1396. font-family: 'robot', 'FZJCGFKTK';
  1397. &-0 {
  1398. line-height: 32px;
  1399. }
  1400. &-1 {
  1401. line-height: 28px;
  1402. }
  1403. }
  1404. }
  1405. .bottom {
  1406. font-size: 12px;
  1407. font-weight: 400;
  1408. line-height: 150%;
  1409. color: rgba(0, 0, 0, 30%);
  1410. text-align: right;
  1411. }
  1412. }
  1413. .kwic_one {
  1414. display: flex;
  1415. align-items: center;
  1416. padding: 0 16px;
  1417. > :nth-child(1) {
  1418. justify-content: flex-end;
  1419. width: 16px;
  1420. margin-right: 16px;
  1421. }
  1422. .laiyuan {
  1423. width: 117px;
  1424. overflow: hidden;
  1425. font-size: 14px;
  1426. font-weight: 400;
  1427. line-height: 22px;
  1428. color: rgba(0, 0, 0, 65%);
  1429. text-overflow: ellipsis;
  1430. white-space: nowrap;
  1431. }
  1432. .word {
  1433. display: flex;
  1434. justify-content: center;
  1435. width: 361px;
  1436. height: 22px;
  1437. margin-left: 16px;
  1438. overflow: hidden;
  1439. font-family: 'FZJCGFKTK';
  1440. font-size: 14px;
  1441. font-weight: 400;
  1442. line-height: 22px;
  1443. color: #000;
  1444. white-space: nowrap;
  1445. opacity: 1;
  1446. > :nth-child(1) {
  1447. // direction: rtl;
  1448. // unicode-bidi: plaintext;
  1449. // text-align: right;
  1450. display: flex;
  1451. justify-content: flex-end;
  1452. width: 172px;
  1453. overflow: hidden;
  1454. white-space: nowrap;
  1455. }
  1456. > :nth-child(3) {
  1457. width: 172px;
  1458. overflow: hidden;
  1459. text-align: left;
  1460. white-space: nowrap;
  1461. direction: ltr;
  1462. unicode-bidi: plaintext;
  1463. }
  1464. }
  1465. }
  1466. }
  1467. .page {
  1468. position: absolute;
  1469. bottom: 16px;
  1470. box-sizing: border-box;
  1471. display: flex;
  1472. justify-content: space-between;
  1473. width: 562px;
  1474. padding: 0 10px 0 12px;
  1475. .text {
  1476. display: flex;
  1477. align-items: center;
  1478. margin-right: 16px;
  1479. font-size: 14px;
  1480. font-weight: 400;
  1481. line-height: 22px;
  1482. color: rgba(0, 0, 0, 60%);
  1483. text-align: center;
  1484. }
  1485. }
  1486. }
  1487. }
  1488. .right {
  1489. width: 630px;
  1490. padding-bottom: 39px;
  1491. background: #fff;
  1492. border-bottom: 1px solid rgba(0, 0, 0, 8%);
  1493. border-radius: 8px;
  1494. .top {
  1495. display: flex;
  1496. align-items: center;
  1497. height: 44px;
  1498. border-bottom: 1px solid rgba(0, 0, 0, 8%);
  1499. > div {
  1500. display: flex;
  1501. align-items: center;
  1502. justify-content: center;
  1503. // width: 84px;
  1504. padding: 0 2px;
  1505. height: 28px;
  1506. margin-left: 16px;
  1507. background: #eee;
  1508. border-radius: 4px;
  1509. > div {
  1510. width: 40px;
  1511. height: 24px;
  1512. font-size: 12px;
  1513. font-weight: 400;
  1514. line-height: 24px;
  1515. color: #888;
  1516. text-align: center;
  1517. cursor: pointer;
  1518. border-radius: 2px;
  1519. }
  1520. .sele {
  1521. color: #000;
  1522. background: #fff;
  1523. box-shadow: 0 2px 2px rgba(0, 0, 0, 8%);
  1524. }
  1525. }
  1526. }
  1527. .list {
  1528. width: 598px;
  1529. margin: 0 auto;
  1530. max-height: 1450px;
  1531. overflow: auto;
  1532. .one {
  1533. display: flex;
  1534. justify-content: space-between;
  1535. padding: 12px;
  1536. font-size: 14px;
  1537. font-weight: 400;
  1538. line-height: 22px;
  1539. color: #333;
  1540. cursor: pointer;
  1541. border-bottom: 1px solid #eee;
  1542. > :nth-child(1) {
  1543. text-align: left;
  1544. }
  1545. > div {
  1546. width: 186px;
  1547. text-align: right;
  1548. }
  1549. }
  1550. .all {
  1551. font-size: 14px;
  1552. font-weight: 600;
  1553. line-height: 22px;
  1554. color: #333;
  1555. border-bottom: none;
  1556. }
  1557. }
  1558. }
  1559. }
  1560. }
  1561. </style>
  1562. <style lang="scss">
  1563. .result {
  1564. .el-switch__core {
  1565. width: 26px !important;
  1566. height: 16px;
  1567. }
  1568. .el-switch__core::after {
  1569. top: 3px;
  1570. width: 8px;
  1571. height: 8px;
  1572. }
  1573. .el-switch.is-checked .el-switch__core::after {
  1574. margin-left: -10px;
  1575. }
  1576. .el-switch__label.is-active {
  1577. color: #000;
  1578. }
  1579. .page {
  1580. .el-pagination.is-background .el-pager li:not(.disabled).active {
  1581. background-color: #0052d9;
  1582. }
  1583. .el-pager li {
  1584. background: #fff;
  1585. border: 1px solid #dcdcdc;
  1586. border-radius: 3px;
  1587. }
  1588. }
  1589. }
  1590. .el-loading-mask {
  1591. z-index: 200000 !important;
  1592. }
  1593. .checkAllCheckbox {
  1594. width: 100%;
  1595. padding: 0 20px;
  1596. height: 34px;
  1597. line-height: 34px;
  1598. &:hover {
  1599. background-color: #f5f7fa;
  1600. }
  1601. .el-checkbox__input {
  1602. display: none;
  1603. }
  1604. .el-checkbox__label {
  1605. padding: 0;
  1606. }
  1607. }
  1608. .selectBook {
  1609. .el-tag {
  1610. max-width: 90px;
  1611. }
  1612. }
  1613. </style>