seekPage.vue 72 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307
  1. <template>
  2. <div class="corpus_seekpage result" v-loading="loading">
  3. <Header v-if="!userID" />
  4. <template v-if="showPage">
  5. <div class="title">
  6. <p>教材语料库</p>
  7. <!-- <p>Corpus Dictionary</p> -->
  8. </div>
  9. <div class="seek" @keydown="downSeek">
  10. <input type="text" v-model="keyword" />
  11. <button
  12. @click="
  13. page = 1;
  14. getdata(true);
  15. "
  16. >
  17. 搜索
  18. </button>
  19. <el-popover v-model="visibleOption" placement="bottom" width="335" trigger="click">
  20. <div class="set_corpus_dv">
  21. <span>教材</span>
  22. <!-- <el-select v-model="corpus.scope" style="width: 205px" placeholder="请选择">
  23. <el-option v-for="(itemD, indexD) in scopeList" :key="indexD" :label="itemD.label" :value="itemD.value" />
  24. </el-select> -->
  25. <el-cascader
  26. v-model="corpus.scope"
  27. placeholder=""
  28. :options="levelList"
  29. :props="{ multiple: true }"
  30. filterable
  31. collapse-tags
  32. ></el-cascader>
  33. </div>
  34. <div class="set_corpus_dv">
  35. <span>例句长度</span>
  36. <el-input
  37. v-model="corpus.sentenceStart"
  38. style="width: 55px; margin-right: 8px"
  39. onkeyup="value=value.replace(/^0+(\d)|[^\d]+/g,'')"
  40. class="numbre-input"
  41. />
  42. ——
  43. <el-input
  44. v-model="corpus.sentenceEnd"
  45. style="width: 55px; margin: 0 8px"
  46. onkeyup="value=value.replace(/^0+(\d)|[^\d]+/g,'')"
  47. class="numbre-input"
  48. />
  49. </div>
  50. <div class="set_corpus_submit">
  51. <div @click="visibleOption = false">取消</div>
  52. <div @click="sureCorpus">确认</div>
  53. </div>
  54. <div slot="reference" class="set_corpus" style="margin-left: 24px; cursor: pointer">筛选</div>
  55. </el-popover>
  56. </div>
  57. </template>
  58. <div class="txt">包含{{ book_count }}本教材、{{ word_count }}个字词,{{ sentence_count }}个例句</div>
  59. <div class="cx-list" v-if="showResult">
  60. <div class="cx-list-box">
  61. <span style="color: #de4444">{{ oldKey }}</span>
  62. <label v-for="(items, indexs) in allList.word_cx_list" :key="indexs"
  63. ><span>{{ items.cx_name }}</span
  64. ><span>{{ items.level_name }}</span></label
  65. >
  66. </div>
  67. <template v-if="editLiju">
  68. <el-row v-if="editLijuFlag">
  69. <el-button
  70. type="info"
  71. class="edit-cancle"
  72. @click="
  73. editLijuFlag = false;
  74. page = 1;
  75. padingEvetn();
  76. "
  77. >取消</el-button
  78. >
  79. <el-button
  80. type="primary"
  81. class="edit-sure"
  82. @click="
  83. editLijuFlag = false;
  84. page = 1;
  85. padingEvetn();
  86. "
  87. >完成</el-button
  88. ></el-row
  89. >
  90. <el-button
  91. v-else
  92. class="edit-liju"
  93. @click="
  94. editLijuFlag = true;
  95. selectDelLijuIds = [];
  96. page = 1;
  97. padingEvetn();
  98. "
  99. >例句编辑模式</el-button
  100. >
  101. </template>
  102. </div>
  103. <div
  104. class="txt_imgtable"
  105. v-if="showResult"
  106. :style="{ height: editLijuFlag ? '0' : '', overflow: editLijuFlag ? 'hidden' : '' }"
  107. >
  108. <div class="left">
  109. <div class="top">
  110. <div>
  111. <div class="pattern">
  112. <div :class="[patternIndex == 0 ? 'sele' : '']" @click="cutPattern(0)">引语模式</div>
  113. <div :class="[patternIndex == 1 ? 'sele' : '']" @click="cutPattern(1)">KWIC模式</div>
  114. </div>
  115. <template v-if="patternIndex == 1">
  116. <div class="KWIC_sort">
  117. <span
  118. :class="['sort', KWIC_sortIndex == 0 ? 'sele' : '']"
  119. @click="KWICsortEvent(0, 'sentence_list_sort_left')"
  120. >
  121. <img src="../../assets/teacherdev/analys-right.png" alt="" />
  122. </span>
  123. <span
  124. :class="['sort', KWIC_sortIndex == 1 ? 'sele' : '']"
  125. @click="KWICsortEvent(1, 'sentence_list_sort_mid')"
  126. >
  127. <img src="../../assets/teacherdev/analys-center.png" alt="" />
  128. </span>
  129. <span
  130. :class="['sort', KWIC_sortIndex == 2 ? 'sele' : '']"
  131. @click="KWICsortEvent(2, 'sentence_list_sort_right')"
  132. >
  133. <img src="../../assets/teacherdev/analys-left.png" alt="" />
  134. </span>
  135. </div>
  136. </template>
  137. <div class="refresh" @click="handleRefresh">
  138. <img src="../../assets/teacherdev/refresh.png" alt="" />
  139. </div>
  140. <template v-if="patternIndex == 0">
  141. <div class="lang_sort" :class="[sortType === 'length' ? 'active' : '']" @click="sortEvent('length')">
  142. 按长度
  143. <img
  144. v-if="sort == 'down' && sortType === 'length'"
  145. src="../../assets/teacherdev/ylk-sort-up.png"
  146. alt=""
  147. />
  148. <img
  149. v-else-if="sort == 'up' && sortType === 'length'"
  150. src="../../assets/teacherdev/ylk-sort-down.png"
  151. alt=""
  152. />
  153. <img v-else src="../../assets/teacherdev/ylk-sort-no.png" alt="" />
  154. </div>
  155. </template>
  156. <template v-else>
  157. <div style="display: flex">
  158. <!--<div
  159. class="lang_sort"
  160. :class="[sortType === 'zflength' ? 'active' : '']"
  161. @click="sortEvent('zflength')"
  162. >
  163. 按长度
  164. <img
  165. v-if="sort == 'down' && sortType === 'zflength'"
  166. src="../../assets/teacherdev/ylk-sort-up.png"
  167. alt=""
  168. />
  169. <img
  170. v-else-if="sort == 'up' && sortType === 'zflength'"
  171. src="../../assets/teacherdev/ylk-sort-down.png"
  172. alt=""
  173. />
  174. <img v-else src="../../assets/teacherdev/ylk-sort-no.png" alt="" />
  175. </div>-->
  176. <div
  177. class="lang_sort"
  178. :class="[sortType === 'pclength' ? 'active' : '']"
  179. @click="sortEvent('pclength')"
  180. >
  181. 按频次
  182. <img
  183. v-if="sort == 'down' && sortType === 'pclength'"
  184. src="../../assets/teacherdev/ylk-sort-up.png"
  185. alt=""
  186. />
  187. <img
  188. v-else-if="sort == 'up' && sortType === 'pclength'"
  189. src="../../assets/teacherdev/ylk-sort-down.png"
  190. alt=""
  191. />
  192. <img v-else src="../../assets/teacherdev/ylk-sort-no.png" alt="" />
  193. </div>
  194. </div>
  195. </template>
  196. </div>
  197. <div class="size">
  198. <template v-if="patternIndex == 0">
  199. <!-- <el-switch
  200. v-model="pinyinShow"
  201. active-text="拼音"
  202. active-color="#424242"
  203. style="margin-left: 24px"
  204. >
  205. </el-switch> -->
  206. <el-switch
  207. v-model="shiyiShow"
  208. active-text="释义"
  209. active-color="#424242"
  210. style="margin-left: 20px"
  211. @change="changeShiyi"
  212. >
  213. </el-switch>
  214. </template>
  215. <el-switch v-model="fenciShow" active-text="分词" active-color="#424242" style="margin-left: 8px">
  216. </el-switch>
  217. <span :class="[sizeIndex == 0 ? 'sele' : '']" @click="cutSize(0)">大</span>
  218. <span :class="[sizeIndex == 1 ? 'sele' : '']" @click="cutSize(1)">中</span>
  219. <span :class="[sizeIndex == 2 ? 'sele' : '']" @click="cutSize(2)">小</span>
  220. </div>
  221. </div>
  222. <div class="main">
  223. <div class="list">
  224. <template v-if="patternIndex == 0">
  225. <div v-for="(item, i) in ShowList" :key="i + 'sentence'" class="one">
  226. <div class="top">
  227. <!--
  228. :class="['number-' + sizeIndex + '-' + pinyinShow]"
  229. -->
  230. <div class="number">{{ item.number }}.</div>
  231. <!--
  232. :class="['speaker-' + sizeIndex + '-' + pinyinShow]"
  233. -->
  234. <!-- <img src="../../assets/teacherdev/speaker-one.png" alt="" /> -->
  235. <div class="words">
  236. <template v-if="item.sentence_fc_list_style && item.sentence_fc_list_style.length > 1">
  237. <span
  238. :style="{
  239. fontSize: conSize + 'px',
  240. padding: fenciShow ? '0 2px' : '',
  241. }"
  242. v-for="(items, indexs) in item.sentence_fc_list_style"
  243. :key="indexs"
  244. v-html="items"
  245. ></span>
  246. </template>
  247. <template v-else>
  248. <span
  249. :style="{
  250. fontSize: conSize + 'px',
  251. padding: fenciShow ? '0 2px' : '',
  252. }"
  253. v-html="item.res"
  254. ></span>
  255. </template>
  256. <template v-if="shiyiShow && item.word_definition_list.length > 0">
  257. <span class="shiyi">
  258. <span v-html="item.word_definition_list.join('; ')"> </span>
  259. </span>
  260. </template>
  261. </div>
  262. <!--
  263. :class="['shiyi-' + sizeIndex]"
  264. -->
  265. </div>
  266. <el-tooltip effect="dark" placement="bottom">
  267. <div slot="content">
  268. {{
  269. item.source_courseware_name_path_short
  270. ? item.source_courseware_name_path_short
  271. : item.source_courseware_name_path
  272. }}
  273. </div>
  274. <div class="bottom">
  275. {{
  276. item.source_courseware_name_path_short
  277. ? item.source_courseware_name_path_short
  278. : item.source_courseware_name_path
  279. }}
  280. </div>
  281. </el-tooltip>
  282. <!-- <div class="bottom">
  283. {{
  284. item.source_courseware_name_path_short
  285. ? item.source_courseware_name_path_short
  286. : item.source_courseware_name_path
  287. }}
  288. </div> -->
  289. </div>
  290. </template>
  291. <template v-else>
  292. <div v-for="(item, index) in ShowList" :key="'kwic' + index" class="kwic_one">
  293. <div class="number">{{ item.number }}</div>
  294. <div
  295. class="word"
  296. :style="{
  297. fontSize: conSize + 'px',
  298. }"
  299. >
  300. <div
  301. v-for="(txt, indexs) in item.resArr"
  302. :key="indexs"
  303. :style="{
  304. width:
  305. indexs === 1 || KWIC_sortIndex === 1
  306. ? ''
  307. : (KWIC_sortIndex === 0 && indexs === 2 && !showLeft) ||
  308. (KWIC_sortIndex === 2 && !showRight && indexs === 0)
  309. ? '944px'
  310. : (KWIC_sortIndex === 0 && indexs === 0 && !showLeft) ||
  311. (KWIC_sortIndex === 2 && !showRight && indexs === 2)
  312. ? '0px'
  313. : '',
  314. }"
  315. >
  316. <template
  317. v-if="
  318. (KWIC_sortIndex === 0 && ((indexs === 0 && showLeft) || indexs !== 0)) ||
  319. (KWIC_sortIndex === 2 && ((showRight && indexs === 2) || indexs !== 2)) ||
  320. KWIC_sortIndex === 1
  321. "
  322. >
  323. <div
  324. :style="{ padding: fenciShow ? '0 2px' : '', display: 'inline-block' }"
  325. v-for="(txts, indext) in txt"
  326. :key="indext"
  327. >
  328. <!-- <span v-html="txts"></span> -->
  329. <template v-if="sortType === 'pclength' && (KWIC_sortIndex === 0 || KWIC_sortIndex === 2)">
  330. <template v-if="indexs === 0 && KWIC_sortIndex === 0">
  331. <el-tooltip effect="dark" placement="bottom" style="display: inline">
  332. <div slot="content">
  333. {{
  334. item.adjoin_fc_frequency_list_left && item.adjoin_fc_frequency_list_left[indext]
  335. ? item.adjoin_fc_frequency_list_left[indext]
  336. : 1
  337. }}
  338. </div>
  339. <div class="">
  340. <span v-html="txts"></span>
  341. </div>
  342. </el-tooltip>
  343. </template>
  344. <template v-else-if="indexs === 2 && KWIC_sortIndex === 2">
  345. <el-tooltip effect="dark" placement="bottom" style="display: inline">
  346. <div slot="content">
  347. {{
  348. item.adjoin_fc_frequency_list_right && item.adjoin_fc_frequency_list_right[indext]
  349. ? item.adjoin_fc_frequency_list_right[indext]
  350. : 1
  351. }}
  352. </div>
  353. <div class="">
  354. <span v-html="txts"></span>
  355. </div>
  356. </el-tooltip>
  357. </template>
  358. <template v-else>
  359. <span v-html="txts"></span>
  360. </template>
  361. </template>
  362. <template v-else>
  363. <span v-html="txts"></span>
  364. </template>
  365. </div>
  366. </template>
  367. </div>
  368. </div>
  369. <el-tooltip effect="dark" placement="bottom">
  370. <div slot="content">
  371. {{
  372. item.source_courseware_name_path_short
  373. ? item.source_courseware_name_path_short
  374. : item.source_courseware_name_path
  375. }}
  376. </div>
  377. <div class="laiyuan">
  378. {{
  379. item.source_courseware_name_path_short
  380. ? item.source_courseware_name_path_short
  381. : item.source_courseware_name_path
  382. }}
  383. </div>
  384. </el-tooltip>
  385. </div>
  386. </template>
  387. </div>
  388. <div class="page">
  389. <el-pagination
  390. background
  391. @current-change="handleCurrentChange"
  392. :current-page.sync="page"
  393. :page-size="pageSize"
  394. layout="prev, pager, next"
  395. :total="selectCurrent ? selectCurrent : CurrentList.length"
  396. :pager-count="5"
  397. >
  398. </el-pagination>
  399. <span class="text">
  400. 共 {{ selectCurrent ? selectCurrent : CurrentList.length }} 条
  401. {{
  402. patternIndex === 0 && selectLaiyuanBookIdList.length === 0 && !shiyiShow
  403. ? ' 命中 ' + scoreAHitNumber + ' 次'
  404. : ''
  405. }}
  406. </span>
  407. </div>
  408. </div>
  409. </div>
  410. <div class="right">
  411. <div class="top">
  412. <div>
  413. <div
  414. v-if="allList.stat_list_word_definition && allList.stat_list_word_definition.length > 0"
  415. :class="[rightTopIndex == 0 ? 'sele' : '']"
  416. @click="cutsyly(0)"
  417. >
  418. 释义
  419. </div>
  420. <div :class="[rightTopIndex == 1 ? 'sele' : '']" @click="cutsyly(1)">来源</div>
  421. </div>
  422. </div>
  423. <div class="bottom">
  424. <div id="shanxing_main" style="width: 720px; height: 600px"></div>
  425. <div class="list" v-if="rightList.length > 0">
  426. <div class="one all" style="border-bottom: 1px solid #eee">
  427. <div style="width: 60%">{{ rightTopIndex == 1 ? '来源' : '释义' }}</div>
  428. <div style="width: 20%">
  429. <span>出现次数</span>
  430. </div>
  431. <div style="width: 20%">
  432. <span>占比</span>
  433. </div>
  434. </div>
  435. <div
  436. v-for="(item, i) in rightList"
  437. :key="i + 'right'"
  438. class="one"
  439. :style="{
  440. borderBottom: i == rightList.length - 1 ? 'none' : '1px solid #eeeeee',
  441. backgroundColor:
  442. selectLaiyuanBookIdList.indexOf(item.book_id) > -1 ||
  443. selectShiyiBookIdList.indexOf(item.definition) > -1
  444. ? '#F2F3F5'
  445. : '',
  446. }"
  447. @mouseover="gaolangbzt(i, 'shanxing_main')"
  448. @mouseout="closegaolangbzt(i, 'shanxing_main')"
  449. @click="handleBookLiju(item, rightTopIndex)"
  450. >
  451. <div style="width: 60%">
  452. <span></span>
  453. <span v-html="item.book_name"></span>
  454. </div>
  455. <div style="width: 20%">
  456. <span>{{ item.count }}</span>
  457. </div>
  458. <div style="width: 20%">
  459. <span>{{ item.percent }}%</span>
  460. </div>
  461. </div>
  462. <div class="one all">
  463. <div style="width: 60%">
  464. <span></span>
  465. <span>合计</span>
  466. </div>
  467. <div style="width: 20%">
  468. <span>{{ allNumber }}</span>
  469. </div>
  470. <div style="width: 20%">
  471. <span>{{ rightTopIndex == 1 ? allPercent.toFixed(2) : '100.00' }}%</span>
  472. </div>
  473. </div>
  474. </div>
  475. </div>
  476. </div>
  477. </div>
  478. <div class="edit-liju-box" v-if="editLijuFlag === true && showResult">
  479. <div class="top">
  480. <div>
  481. <span class="select-number">已选 {{ selectDelLijuIds.length }}</span>
  482. <el-button type="danger" plain @click="handleDelLiju"><i class="el-icon-delete"></i>删除选中</el-button>
  483. </div>
  484. <el-button type="primary" plain @click="handleEditLiju()"><i class="el-icon-plus"></i>增加例句</el-button>
  485. </div>
  486. <div class="main">
  487. <div class="list">
  488. <div v-for="(item, i) in ShowList" :key="i + 'sentence'" class="one">
  489. <div class="top">
  490. <!--
  491. :class="['number-' + sizeIndex + '-' + pinyinShow]"
  492. -->
  493. <el-checkbox v-model="selectDelLijuIds" :label="item.sentence_id"><br /></el-checkbox>
  494. <div class="number">{{ item.number }}.</div>
  495. <!--
  496. :class="['speaker-' + sizeIndex + '-' + pinyinShow]"
  497. -->
  498. <!-- <img src="../../assets/teacherdev/speaker-one.png" alt="" /> -->
  499. <div class="words">
  500. <template v-if="item.sentence_fc_list_style && item.sentence_fc_list_style.length > 1">
  501. <span
  502. :style="{
  503. fontSize: conSize + 'px',
  504. }"
  505. v-for="(items, indexs) in item.sentence_fc_list_style"
  506. :key="indexs"
  507. v-html="items"
  508. ></span>
  509. </template>
  510. <template v-else>
  511. <span
  512. :style="{
  513. fontSize: conSize + 'px',
  514. padding: fenciShow ? '0 2px' : '',
  515. }"
  516. v-html="item.res"
  517. ></span>
  518. </template>
  519. <template v-if="shiyiShow && item.word_definition_list.length > 0">
  520. <span class="shiyi">
  521. <span v-html="item.word_definition_list.join('; ')"> </span>
  522. </span>
  523. </template>
  524. </div>
  525. <!--
  526. :class="['shiyi-' + sizeIndex]"
  527. -->
  528. </div>
  529. <el-tooltip effect="dark" placement="bottom">
  530. <div slot="content">
  531. {{
  532. item.source_courseware_name_path_short
  533. ? item.source_courseware_name_path_short
  534. : item.source_courseware_name_path
  535. }}
  536. </div>
  537. <div class="bottom">
  538. {{
  539. item.source_courseware_name_path_short
  540. ? item.source_courseware_name_path_short
  541. : item.source_courseware_name_path
  542. }}
  543. </div>
  544. </el-tooltip>
  545. <i class="el-icon-edit-outline" @click="handleEditLiju(item)"></i>
  546. </div>
  547. </div>
  548. <div class="page">
  549. <el-pagination
  550. background
  551. @current-change="handleCurrentChange"
  552. :current-page.sync="page"
  553. :page-size="pageSize"
  554. layout="prev, pager, next"
  555. :total="allList.sentence_list.length"
  556. :pager-count="5"
  557. >
  558. </el-pagination>
  559. <span class="text"> 共 {{ allList.sentence_list.length }} 条 </span>
  560. </div>
  561. </div>
  562. </div>
  563. <el-dialog
  564. title=""
  565. :visible.sync="showEditLijuFlag"
  566. width="365px"
  567. :before-close="handleClose"
  568. :modal="false"
  569. v-if="actvieEditLijuItem"
  570. class="seekpage-dialog"
  571. >
  572. <label>{{ actvieEditLijuItem.sentence_id ? '修改例句' : '增加例句' }}</label>
  573. <el-input v-model="actvieEditLijuItem.sentence"></el-input>
  574. <b class="tips">关键字不能删除,分词用两个空格区分。</b>
  575. <label>来源</label>
  576. <el-input v-model="actvieEditLijuItem.source_path"></el-input>
  577. <b class="tips">路径间用“/”隔开。</b>
  578. <label>关键字</label>
  579. <p>{{ keyword }}</p>
  580. <label>词性</label>
  581. <el-input v-model="actvieEditLijuItem.cixing"></el-input>
  582. <b class="tips">多个词性用逗号分割</b>
  583. <label>释义</label>
  584. <el-input type="textarea" v-model="actvieEditLijuItem.definition_list"></el-input>
  585. <b class="tips">多条释义另起一行</b>
  586. <span slot="footer" class="dialog-footer">
  587. <el-button @click="handleClose">取 消</el-button>
  588. <el-button type="primary" @click="save" :loading="loading">确 定</el-button>
  589. </span>
  590. </el-dialog>
  591. </div>
  592. </template>
  593. <script>
  594. //这里可以导入其它文件(比如:组件,工具js,第三方插件js,json文件,图片文件等等)
  595. //例如:import 《组件名称》from ‘《组件路径》';
  596. import Header from '@/components/Header';
  597. import { getConfigInfor } from '@/utils/index';
  598. import { getStaticContent, BookgetContent, LearnWebSI } from '@/api/api';
  599. import { setToken, getToken } from '@/utils/auth';
  600. import * as echarts from 'echarts';
  601. export default {
  602. name: 'corpus_seekpage',
  603. //import引入的组件需要注入到对象中才能使用
  604. components: {
  605. Header,
  606. },
  607. props: {},
  608. data() {
  609. //这里存放数据
  610. return {
  611. keyword: this.$route.query.keyword ? this.$route.query.keyword : null,
  612. oldKey: '',
  613. AccessToken: this.$route.query.AccessToken,
  614. AppID: this.$route.query.AppID,
  615. showPage: false,
  616. userID: this.$route.query.UserID ? this.$route.query.UserID : '',
  617. book_count: 0,
  618. word_count: 0,
  619. sentence_count: 0,
  620. visibleOption: false,
  621. corpus: {
  622. difficlty: null,
  623. scope: [],
  624. sentenceStart: null,
  625. sentenceEnd: null,
  626. },
  627. scopeList: [
  628. {
  629. value: '',
  630. label: '全部',
  631. },
  632. ],
  633. page: 1,
  634. pageSize: 30,
  635. shiyiShow: false,
  636. fenciShow: false,
  637. pinyinShow: true,
  638. JFIndex: 0,
  639. hzData: [],
  640. ShowHzData: [],
  641. loading: true,
  642. lang: null,
  643. unfold: true,
  644. patternIndex: 0,
  645. rightTopIndex: 0,
  646. sizeIndex: 1,
  647. sort: '',
  648. sortType: '',
  649. rightList: [],
  650. KWIC_sortIndex: 0,
  651. allNumber: 0,
  652. allPercent: 0,
  653. conSize: 20,
  654. pinyinSize: 12,
  655. allList: [],
  656. CurrentList: [],
  657. ShowList: [],
  658. chsFhList: [',', '。', '”', ':', '》', '《', '?', '!', ';'],
  659. scoreAHitNumber: 0,
  660. checkAll: false,
  661. isIndeterminate: true,
  662. allLevels: [],
  663. levelList: [],
  664. selectLaiyuanBookIdList: [], // 选中右侧来源书籍列表id
  665. selectShiyiBookIdList: [], // 选中右侧释义书籍列表id
  666. selectCurrent: 0,
  667. showResult: false,
  668. shiyiList: [], //含有释义例句列表
  669. bookListObj: {}, //书籍id和名称对应关系
  670. bookSourceObj: {}, //书籍来源id对应关系
  671. editLiju: false, // 是否有编辑例句权限
  672. editLijuFlag: false, // 编辑例句模式
  673. selectDelLijuIds: [], // 选中删除例句id数组
  674. actvieEditLijuItem: null,
  675. showEditLijuFlag: false,
  676. showLeft: true, //左对齐显示左边
  677. showRight: true, //右对齐显示右边
  678. };
  679. },
  680. //计算属性 类似于data概念
  681. computed: {},
  682. //监控data中数据变化
  683. watch: {},
  684. //方法集合
  685. methods: {
  686. downSeek(e) {
  687. if (e.keyCode == 13) {
  688. this.page = 1;
  689. this.getdata(true);
  690. }
  691. },
  692. getTotalCount() {
  693. const Mname = 'book-data_stat-GetBookWordExampleSentenceTotalCount';
  694. BookgetContent(Mname, {}).then((res) => {
  695. if (res.status === 1) {
  696. this.book_count = res.book_count;
  697. this.word_count = res.word_count;
  698. this.sentence_count = res.example_sentence_count;
  699. }
  700. });
  701. },
  702. // 存储句长信息
  703. sureCorpus() {
  704. this.visibleOption = false;
  705. this.getdata(true);
  706. // if (this.seekOptions) this.seekresult();
  707. },
  708. // 获取上架教材列表
  709. getLevelList() {
  710. this.allLevels = [];
  711. this.levelList = [];
  712. this.bookListObj = {};
  713. BookgetContent('book-book_manager-GetBookList', {
  714. publish_status: 1,
  715. }).then((res) => {
  716. this.loading = false;
  717. this.levelList = [];
  718. if (res.status === 1) {
  719. res.book_list.forEach((item) => {
  720. item.value = item.id;
  721. item.label = item.name;
  722. this.allLevels.push(item.id);
  723. this.$set(this.bookListObj, item.id, item.name);
  724. });
  725. // this.levelList = this.levelList.concat(res.book_list);
  726. let tempdata = {};
  727. res.book_list.forEach((str) => {
  728. let sort = '';
  729. if (str.name.indexOf('发展汉语') > -1) {
  730. if (str.name.indexOf('初级') > -1) {
  731. sort += '1';
  732. } else if (str.name.indexOf('中级') > -1) {
  733. sort += '2';
  734. } else if (str.name.indexOf('高级') > -1) {
  735. sort += '3';
  736. }
  737. if (str.name.indexOf('综合') > -1) {
  738. sort += '1';
  739. } else if (str.name.indexOf('听力') > -1) {
  740. sort += '2';
  741. } else if (str.name.indexOf('口语') > -1) {
  742. sort += '3';
  743. } else if (str.name.indexOf('阅读') > -1) {
  744. sort += '4';
  745. } else if ((str.name.indexOf('写作') > -1) | (str.name.indexOf('读写') > -1)) {
  746. sort += '5';
  747. }
  748. }
  749. str.sort = Number(sort);
  750. if (tempdata[str.series_code] != null) {
  751. tempdata[str.series_code].push(str);
  752. } else {
  753. let every = [];
  754. every.push(str);
  755. tempdata[str.series_code] = every;
  756. }
  757. });
  758. for (const key in tempdata) {
  759. let obj = {
  760. value: tempdata[key][0].series_code,
  761. label: tempdata[key][0].series_code ? tempdata[key][0].series_code : '未分类',
  762. children: tempdata[key].sort(this.compare('sort')),
  763. };
  764. this.levelList.push(obj);
  765. }
  766. }
  767. });
  768. },
  769. compare(property) {
  770. return function (a, b) {
  771. var value1 = a[property];
  772. var value2 = b[property];
  773. return value1 - value2;
  774. };
  775. },
  776. getrightListdata() {
  777. this.inityuan();
  778. },
  779. inityuan() {
  780. var chartDom = document.getElementById('shanxing_main');
  781. var myChart = echarts.init(chartDom);
  782. var option;
  783. this.allNumber = 0;
  784. this.allPercent = 0;
  785. let newdata = JSON.parse(JSON.stringify(this.rightList));
  786. newdata.forEach((item) => {
  787. this.allNumber += item.count;
  788. this.allPercent += item.percent;
  789. let percent = item.percent;
  790. item.value = item.count;
  791. if (percent % 1 == 0) {
  792. item.name = item.book_name + ' ' + percent + '%';
  793. } else {
  794. item.name = item.book_name + ' ' + percent.toFixed(2) + '%';
  795. }
  796. });
  797. if (this.rightTopIndex === 1) {
  798. let data = [];
  799. let tempdata = {};
  800. if (this.corpus.scope.length === 0) {
  801. this.levelList.forEach((item) => {
  802. let obj = {
  803. name: item.label,
  804. value: 0,
  805. children: [],
  806. percent: 0,
  807. };
  808. item.children.forEach((items) => {
  809. let childObj = {
  810. name: '',
  811. value: 0,
  812. };
  813. if (this.bookSourceObj[items.id]) {
  814. childObj.name = items.name + ' ' + this.bookSourceObj[items.id].percent + '%';
  815. childObj.value = this.bookSourceObj[items.id].count;
  816. obj.value += this.bookSourceObj[items.id].count;
  817. obj.percent += this.bookSourceObj[items.id].percent;
  818. }
  819. obj.children.push(childObj);
  820. });
  821. if (obj.percent % 1 == 0) {
  822. obj.name = item.label + ' ' + obj.percent + '%';
  823. } else {
  824. obj.name = item.label + ' ' + obj.percent.toFixed(2) + '%';
  825. }
  826. data.push(obj);
  827. });
  828. } else {
  829. this.corpus.scope.forEach((str) => {
  830. if (!tempdata[str[0]]) {
  831. let obj = {
  832. name: str[0],
  833. value: 0,
  834. children: [],
  835. percent: 0,
  836. };
  837. tempdata[str[0]] = obj;
  838. }
  839. let childObj = {
  840. name: '',
  841. value: 0,
  842. percent: 0,
  843. };
  844. if (this.bookSourceObj[str[1]]) {
  845. childObj.name = this.bookSourceObj[str[1]].book_name + ' ' + this.bookSourceObj[str[1]].percent + '%';
  846. childObj.value = this.bookSourceObj[str[1]].count;
  847. tempdata[str[0]].value += this.bookSourceObj[str[1]].count;
  848. tempdata[str[0]].percent += this.bookSourceObj[str[1]].percent;
  849. }
  850. if (tempdata[str[0]].percent % 1 == 0) {
  851. tempdata[str[0]].name = str[0] + ' ' + tempdata[str[0]].percent + '%';
  852. } else {
  853. tempdata[str[0]].name = str[0] + ' ' + tempdata[str[0]].percent.toFixed(2) + '%';
  854. }
  855. tempdata[str[0]].children.push(childObj);
  856. });
  857. for (const key in tempdata) {
  858. data.push(tempdata[key]);
  859. }
  860. }
  861. newdata = data;
  862. // option = {
  863. // title: {
  864. // text: '',
  865. // subtext: '',
  866. // textStyle: {
  867. // fontSize: 14,
  868. // align: 'center',
  869. // },
  870. // subtextStyle: {
  871. // align: 'center',
  872. // },
  873. // sublink: '',
  874. // },
  875. // series: {
  876. // type: 'sunburst',
  877. // data: data,
  878. // radius: [0, '95%'],
  879. // sort: undefined,
  880. // emphasis: {
  881. // focus: 'ancestor',
  882. // },
  883. // levels: [
  884. // {},
  885. // {
  886. // r0: '3%',
  887. // r: '35%',
  888. // itemStyle: {
  889. // borderWidth: 2,
  890. // },
  891. // label: {
  892. // align: 'left',
  893. // },
  894. // },
  895. // {
  896. // r0: '35%',
  897. // r: '40%',
  898. // label: {
  899. // position: 'outside',
  900. // },
  901. // },
  902. // ],
  903. // },
  904. // };
  905. }
  906. // else {
  907. option = {
  908. series: [
  909. {
  910. name: 'Access From',
  911. type: 'pie',
  912. // radius: ["50%", "50%"],
  913. data: newdata.length > 0 ? newdata : [],
  914. itemStyle: {
  915. // borderColor: "#fff",
  916. // borderWidth: 2,
  917. },
  918. top: 50,
  919. emphasis: {
  920. itemStyle: {
  921. shadowBlur: 10,
  922. shadowOffsetX: 0,
  923. shadowColor: 'rgba(0, 0, 0, 0.5)',
  924. },
  925. },
  926. },
  927. ],
  928. xAxis: {
  929. show: false, //不显示坐标轴线、坐标轴刻度线和坐标轴上的文字
  930. axisTick: {
  931. show: false, //不显示坐标轴刻度线
  932. },
  933. axisLine: {
  934. show: false, //不显示坐标轴线
  935. },
  936. axisLabel: {
  937. show: false, //不显示坐标轴上的文字
  938. },
  939. },
  940. };
  941. // }
  942. option && myChart.setOption(option);
  943. let number = 0;
  944. let _this = this;
  945. myChart.on('click', function (param) {
  946. //添加点击事件
  947. myChart.dispatchAction({ type: 'highlight', dataIndex: param.dataIndex }); //激活点击区域高亮
  948. if (param.dataIndex !== number) {
  949. // 当鼠标点击的时候 消除上一个扇区的高亮
  950. myChart.dispatchAction({ type: 'downplay', dataIndex: number });
  951. }
  952. number = param.dataIndex; //接住当前扇区的dataIndex
  953. if (_this.rightTopIndex === 0) {
  954. _this.handleShiyiLiju(param.data.definition);
  955. } else {
  956. _this.handleBookLiju(param.data);
  957. }
  958. });
  959. },
  960. // 鼠标进入
  961. gaolangbzt(index, id) {
  962. if (this.rightTopIndex === 1) return;
  963. var compareChart = echarts.getInstanceByDom(document.getElementById(id));
  964. compareChart.dispatchAction({
  965. type: 'highlight',
  966. seriesIndex: 0,
  967. dataIndex: index,
  968. });
  969. },
  970. // 鼠标移出
  971. closegaolangbzt(index, id) {
  972. var compareChart = echarts.getInstanceByDom(document.getElementById(id));
  973. compareChart.dispatchAction({
  974. type: 'downplay',
  975. seriesIndex: 0,
  976. dataIndex: index,
  977. });
  978. },
  979. // 计算选中教材例句
  980. handleBookLiju(item, index) {
  981. if (index === 0) {
  982. this.handleShiyiLiju(item.definition);
  983. return false;
  984. }
  985. let id = item.book_id;
  986. if (!id) return false;
  987. if (this.selectLaiyuanBookIdList.indexOf(id) > -1) {
  988. this.selectLaiyuanBookIdList.splice(this.selectLaiyuanBookIdList.indexOf(id), 1);
  989. } else {
  990. this.selectLaiyuanBookIdList.push(id);
  991. }
  992. this.page = 1;
  993. this.padingEvetn();
  994. window.scrollTo(0, 0);
  995. },
  996. // 计算选中教材例句
  997. handleShiyiLiju(shiyi) {
  998. if (!shiyi) return false;
  999. if (this.selectShiyiBookIdList.indexOf(shiyi) > -1) {
  1000. this.selectShiyiBookIdList.splice(this.selectShiyiBookIdList.indexOf(shiyi), 1);
  1001. } else {
  1002. this.selectShiyiBookIdList.push(shiyi);
  1003. }
  1004. this.shiyiShow = this.selectShiyiBookIdList.length > 0;
  1005. this.page = 1;
  1006. this.padingEvetns();
  1007. window.scrollTo(0, 0);
  1008. },
  1009. changehzdata() {
  1010. this.hzData = [];
  1011. this.jfEvent(0);
  1012. let arr = this.keyword.trim().split('');
  1013. arr.forEach((item) => {
  1014. if (!/^[\u4e00-\u9fa5]/.test(item)) {
  1015. return;
  1016. }
  1017. let result = pinyinUtil.getPinyin(item);
  1018. let obj = {
  1019. con: item,
  1020. pinyin: result,
  1021. hzDetail: {
  1022. hz_json: null,
  1023. },
  1024. };
  1025. this.hzData.push(obj);
  1026. this.ShowHzData = JSON.parse(JSON.stringify(this.hzData));
  1027. });
  1028. },
  1029. handleRefresh() {
  1030. this.pinyinShow = true;
  1031. this.shiyiShow = true;
  1032. this.fenciShow = true;
  1033. this.sizeIndex = 1;
  1034. this.sort = '';
  1035. this.sortType = '';
  1036. this.KWIC_sortIndex = 0;
  1037. this.cutSize(1);
  1038. this.getdata();
  1039. this.page = 1;
  1040. },
  1041. getdata(flag) {
  1042. if (!this.keyword || !this.keyword.trim()) {
  1043. this.$message.warning('请输入要搜索的内容');
  1044. return;
  1045. }
  1046. this.loading = true;
  1047. this.oldKey = this.keyword.trim();
  1048. this.showResult = true;
  1049. this.scoreAHitNumber = 0;
  1050. let selectBookId = [];
  1051. this.corpus.scope.forEach((item) => {
  1052. selectBookId.push(item[1]);
  1053. });
  1054. this.bookSourceObj = {};
  1055. let Mname = 'book-courseware_manager-GetCoursewareWordExampleSentenceList_Sort';
  1056. let data = {
  1057. // courseware_id: "003-20211012-17-BDUZ1JVCAN",
  1058. courseware_id: '',
  1059. // word: this.$route.query.keyword, // 单词
  1060. word: this.keyword.trim(),
  1061. search_scope: 3, // 检索范围 0 【本章】,1【本教材】,2【本套教材】,3【系统所有教材】
  1062. // 本章:同一本教材下,归属同一个第一级章节下的所有课件为同一章。
  1063. is_contain_word_variants: false, // 是否包含单词变体例句
  1064. is_contain_stat_data: true, //是否包统计数据
  1065. is_filter_repetitive_sentence: 'true', // 过滤重复例句
  1066. sort_mode: this.sort ? (this.sort == 'down' ? 'DESCENT' : 'ASCENT') : 'NO', // 排序模式 NO 【不排序】,ASCENT【顺序】,DESCENT【倒序】
  1067. compare_mode: this.patternIndex === 0 ? 'LENGTH' : 'KWIC', // 排序比较模式,LENGTH【例句长度】,KWIC【KWIC 模式】
  1068. kwic_arrange_type: this.KWIC_sortIndex === 0 ? 'LEFT' : this.KWIC_sortIndex === 1 ? 'MID' : 'RIGHT', // KWIC 排列类型, LEFT【左】,MID【中】,RIGHT【右】
  1069. kwic_compare_by: this.sortType === 'pclength' ? 1 : 0, // KWIC 排序比较依据,0【字符】,1【相邻的搭配词出现的次数】
  1070. book_publish_status: 1, // 教材发布状态 -1【全部】, 0【下架】1【上架】
  1071. book_id_list: selectBookId, // 指定教材查询,空表示在检索范围内检索所有教材。
  1072. sentence_fc_length_min: this.corpus.sentenceStart ? Number(this.corpus.sentenceStart) : -1, // 例句分词长度范围(最小值),-1 表示不检测最小值
  1073. sentence_fc_length_max: this.corpus.sentenceEnd ? Number(this.corpus.sentenceEnd) : -1, // 例句分词长度范围(最大值),-1 表示不检测最大值
  1074. is_analyse_word_cx: 'true',
  1075. is_analyse_word_level: 'true',
  1076. };
  1077. BookgetContent(Mname, data, this.AppID, this.AccessToken)
  1078. .then((res) => {
  1079. this.shiyiList = [];
  1080. this.allList = {
  1081. sentence_list: [],
  1082. sentence_list_sort_left: [],
  1083. sentence_list_sort_mid: [],
  1084. sentence_list_sort_right: [],
  1085. stat_list_sentence_source_book: res.stat_list_sentence_source_book,
  1086. stat_list_sentence_source_book_series_code: res.stat_list_sentence_source_book_series_code,
  1087. stat_list_word_definition: res.stat_list_word_definition,
  1088. word_level_name: res.word_level_name,
  1089. word_cx_list: res.word_cx_level_list,
  1090. };
  1091. res.stat_list_sentence_source_book.forEach((itesb) => {
  1092. itesb.name = itesb.book_name;
  1093. itesb.value = itesb.count;
  1094. this.$set(this.bookSourceObj, itesb.book_id, itesb);
  1095. });
  1096. if (res.sentence_list.length > 0) {
  1097. res.stat_list_word_definition.forEach((item) => {
  1098. // item.book_name_s = item.definition;
  1099. item.book_name = JSON.parse(JSON.stringify(item.definition)).replace(/<i>/g, '').replace(/<\/i>/g, '');
  1100. });
  1101. res.stat_list_sentence_source_book_series_code.forEach((item) => {
  1102. item.book_name = item.series_code;
  1103. });
  1104. // 清理脏数据
  1105. this.removeRubbishData(res);
  1106. if (res.stat_list_word_definition.length === 0) {
  1107. this.rightTopIndex = 1;
  1108. }
  1109. if (this.rightTopIndex === 0) {
  1110. this.rightList = res.stat_list_word_definition;
  1111. } else {
  1112. this.rightList = res.stat_list_sentence_source_book;
  1113. }
  1114. this.getrightListdata();
  1115. this.allList.sentence_list = this.handleExample(res.sentence_list);
  1116. if (this.patternIndex === 1) {
  1117. if (this.KWIC_sortIndex === 0) {
  1118. this.allList.sentence_list_sort_left = this.handleExample(res.sentence_list, 'left');
  1119. } else if (this.KWIC_sortIndex === 1) {
  1120. this.allList.sentence_list_sort_mid = this.handleExample(res.sentence_list, 'mid');
  1121. } else {
  1122. this.allList.sentence_list_sort_right = this.handleExample(res.sentence_list, 'right');
  1123. }
  1124. }
  1125. this.CurrentList = JSON.parse(JSON.stringify(res.sentence_list));
  1126. let shiyiIndex = 1;
  1127. JSON.parse(JSON.stringify(res.sentence_list)).forEach((items) => {
  1128. if (items.word_definition_list && items.word_definition_list.length > 0) {
  1129. items.number = shiyiIndex;
  1130. this.shiyiList.push(items);
  1131. shiyiIndex++;
  1132. }
  1133. });
  1134. this.padingEvetn();
  1135. } else {
  1136. this.CurrentList = [];
  1137. this.ShowList = [];
  1138. this.rightList = [];
  1139. this.shiyiList = [];
  1140. this.getrightListdata();
  1141. }
  1142. if (this.keyword.trim() && flag) {
  1143. this.changehzdata();
  1144. } else {
  1145. this.loading = false;
  1146. }
  1147. if (res.word_pinyin_list) {
  1148. res.word_pinyin_list.forEach((itemP, indexP) => {
  1149. if (this.hzData[indexP]) {
  1150. this.hzData[indexP].pinyin = itemP;
  1151. }
  1152. });
  1153. }
  1154. })
  1155. .catch((err) => {
  1156. this.loading = false;
  1157. });
  1158. },
  1159. handleExample(list, type) {
  1160. if (list.length > 0) {
  1161. list = list.map((item, index) => {
  1162. item.number = index + 1;
  1163. let str = item.source_courseware_name_path;
  1164. item.show_source_courseware_name_path = str.slice(0, 8) + '...';
  1165. if (type == 'left') {
  1166. let arr = JSON.parse(JSON.stringify(item.sentence_fc_list));
  1167. arr.forEach((items, indexs) => {
  1168. if (indexs == item.sentence_fc_list_word_index) {
  1169. arr[indexs] = `<span style=color:#DE4444;font-weight:700;>${arr[indexs]}</span>`;
  1170. }
  1171. });
  1172. let data = this.changefiveword(arr, item.sentence_fc_list_word_index, type);
  1173. item.resArr = data;
  1174. item.adjoin_fc_frequency_list_left = item.adjoin_fc_frequency_list.splice(
  1175. 0,
  1176. item.sentence_fc_list_word_index,
  1177. );
  1178. } else if (type == 'right') {
  1179. let sentence = JSON.parse(JSON.stringify(item.sentence));
  1180. let arr = JSON.parse(JSON.stringify(item.sentence_fc_list));
  1181. arr.forEach((items, indexs) => {
  1182. if (indexs == item.sentence_fc_list_word_index) {
  1183. arr[indexs] = `<span style=color:#DE4444;font-weight:700;>${arr[indexs]}</span>`;
  1184. }
  1185. });
  1186. let data = this.changefiveword(arr, item.sentence_fc_list_word_index, type);
  1187. item.resArr = data;
  1188. item.adjoin_fc_frequency_list_right = item.adjoin_fc_frequency_list.splice(
  1189. item.sentence_fc_list_word_index + 1,
  1190. );
  1191. } else if (type == 'mid') {
  1192. let sentence = JSON.parse(JSON.stringify(item.sentence));
  1193. let arr = JSON.parse(JSON.stringify(item.sentence_fc_list));
  1194. arr.forEach((items, indexs) => {
  1195. if (indexs == item.sentence_fc_list_word_index) {
  1196. arr[indexs] = `<span style=color:#DE4444;font-weight:700;>${arr[indexs]}</span>`;
  1197. }
  1198. });
  1199. let data = this.changefiveword(arr, item.sentence_fc_list_word_index, type);
  1200. item.resArr = data;
  1201. } else {
  1202. this.scoreAHitNumber += item.position_list.length;
  1203. let sentence_fc_list_style = [];
  1204. let newsentence = JSON.parse(JSON.stringify(item.sentence));
  1205. let res = '';
  1206. for (let i = 0; i < item.position_list.length; i++) {
  1207. let part1 = '';
  1208. let part2 = '';
  1209. let part3 = '';
  1210. if (item.position_list.length > 1) {
  1211. if (i == 0) {
  1212. part1 = newsentence.substring(0, item.position_list[i].begin);
  1213. part2 = newsentence.substring(item.position_list[i].begin, item.position_list[i].end);
  1214. part3 = newsentence.substring(item.position_list[i].end, item.position_list[i + 1].begin);
  1215. } else if (i == item.position_list.length - 1) {
  1216. part2 = newsentence.substring(item.position_list[i].begin, item.position_list[i].end);
  1217. part3 = newsentence.substring(item.position_list[i].end);
  1218. } else {
  1219. part2 = newsentence.substring(item.position_list[i].begin, item.position_list[i].end);
  1220. part3 = newsentence.substring(item.position_list[i].end, item.position_list[i + 1].begin);
  1221. }
  1222. } else {
  1223. part1 = newsentence.substring(0, item.position_list[i].begin);
  1224. part2 = newsentence.substring(item.position_list[i].begin, item.position_list[i].end);
  1225. part3 = newsentence.substring(item.position_list[i].end);
  1226. }
  1227. res += part1 + '<span style="color:#DE4444;">' + part2 + '</span>' + part3;
  1228. }
  1229. item.res = res;
  1230. item.sentence_fc_list.forEach((items, indexs) => {
  1231. if (item.sentence_fc_list_word_index_list.indexOf(indexs) > -1) {
  1232. sentence_fc_list_style.push('<span style="color:#DE4444;">' + items + '</span>');
  1233. } else {
  1234. sentence_fc_list_style.push(items);
  1235. }
  1236. });
  1237. item.sentence_fc_list_style = sentence_fc_list_style;
  1238. }
  1239. return item;
  1240. });
  1241. return list;
  1242. } else {
  1243. return [];
  1244. }
  1245. },
  1246. changefiveword(arr, index, type) {
  1247. let num = 6;
  1248. let colorIndex = 0;
  1249. let colorList = ['#4D7EFF', '#A4430F', '#9342C5', '#FF8718', '#1DAA91'];
  1250. for (let i = 1; i < num; i++) {
  1251. if (type == 'left') {
  1252. if (index - i >= 0) {
  1253. if (this.chsFhList.indexOf(arr[index - i]) == -1) {
  1254. arr[index - i] = `<span style=color:${colorList[colorIndex]};>${arr[index - i]}</span>`;
  1255. colorIndex++;
  1256. } else {
  1257. num++;
  1258. }
  1259. }
  1260. } else if (type == 'right') {
  1261. if (index + i <= arr.length - 1) {
  1262. if (this.chsFhList.indexOf(arr[index + i]) == -1) {
  1263. arr[index + i] = `<span style=color:${colorList[colorIndex]};>${arr[index + i]}</span>`;
  1264. colorIndex++;
  1265. } else {
  1266. num++;
  1267. }
  1268. }
  1269. }
  1270. }
  1271. let newarr = [];
  1272. let arr1 = [];
  1273. let arr2 = [];
  1274. let arr3 = [];
  1275. arr.forEach((item, i) => {
  1276. if (i < index) {
  1277. arr1.push(item);
  1278. } else if (i == index) {
  1279. arr2.push(item);
  1280. } else {
  1281. arr3.push(item);
  1282. }
  1283. });
  1284. newarr.push(arr1);
  1285. newarr.push(arr2);
  1286. newarr.push(arr3);
  1287. return newarr;
  1288. },
  1289. // 处理分页
  1290. padingEvetn() {
  1291. let arr =
  1292. this.shiyiShow && this.patternIndex === 0
  1293. ? JSON.parse(JSON.stringify(this.shiyiList))
  1294. : JSON.parse(JSON.stringify(this.CurrentList));
  1295. let arrs = [];
  1296. if (this.editLijuFlag) {
  1297. arrs = JSON.parse(JSON.stringify(this.allList.sentence_list));
  1298. } else if (this.selectLaiyuanBookIdList.length === 0) {
  1299. arrs = arr;
  1300. } else {
  1301. arr.forEach((item) => {
  1302. let path = item.source_courseware_id_path.split('/');
  1303. if (path.length > 0 && this.selectLaiyuanBookIdList.indexOf(path[0]) > -1) {
  1304. arrs.push(item);
  1305. }
  1306. });
  1307. }
  1308. this.selectCurrent = arrs.length;
  1309. arrs.forEach((item, index) => {
  1310. item.number = index + 1;
  1311. });
  1312. let newarr = arrs.splice((this.page - 1) * this.pageSize, this.pageSize);
  1313. let showleft = false;
  1314. let showRight = false;
  1315. newarr.forEach((item) => {
  1316. if (item.resArr && item.resArr[0].length > 0) {
  1317. showleft = true;
  1318. }
  1319. if (item.resArr && item.resArr[2].length > 0) {
  1320. showRight = true;
  1321. }
  1322. });
  1323. this.showLeft = showleft;
  1324. this.showRight = showRight;
  1325. this.ShowList = JSON.parse(JSON.stringify(newarr));
  1326. },
  1327. padingEvetns() {
  1328. let arr = JSON.parse(JSON.stringify(this.shiyiList));
  1329. let arrs = [];
  1330. if (this.selectShiyiBookIdList.length === 0) {
  1331. arrs = JSON.parse(JSON.stringify(this.CurrentList));
  1332. } else {
  1333. arr.forEach((item) => {
  1334. if (item.word_definition_list.length > 0) {
  1335. this.selectShiyiBookIdList.forEach((items) => {
  1336. if (item.word_definition_list.indexOf(items) > -1) {
  1337. arrs.push(item);
  1338. }
  1339. });
  1340. }
  1341. });
  1342. }
  1343. this.selectCurrent = arrs.length;
  1344. arrs.forEach((item, index) => {
  1345. item.number = index + 1;
  1346. });
  1347. let newarr = arrs.splice((this.page - 1) * this.pageSize, this.pageSize);
  1348. let showleft = false;
  1349. let showRight = false;
  1350. newarr.forEach((item) => {
  1351. if (item.resArr && item.resArr[0].length > 0) {
  1352. showleft = true;
  1353. }
  1354. if (item.resArr && item.resArr[2].length > 0) {
  1355. showRight = true;
  1356. }
  1357. });
  1358. this.showLeft = showleft;
  1359. this.showRight = showRight;
  1360. this.ShowList = JSON.parse(JSON.stringify(newarr));
  1361. },
  1362. // 删除脏数据
  1363. removeRubbishData(data) {
  1364. if (data.sentence_list.length > 0) {
  1365. for (let i = data.sentence_list.length; i--; ) {
  1366. if (
  1367. data.sentence_list[i].sentence_fc_list.length <= 1 ||
  1368. data.sentence_list[i].sentence_fc_list_word_index === -1
  1369. ) {
  1370. data.sentence_list.splice(i, 1);
  1371. }
  1372. }
  1373. }
  1374. },
  1375. handleCurrentChange(val) {
  1376. this.page = val;
  1377. this.padingEvetn();
  1378. },
  1379. // KWIC排序
  1380. KWICsortEvent(index, type) {
  1381. if (this.KWIC_sortIndex == index) return;
  1382. this.KWIC_sortIndex = index;
  1383. // this.CurrentList = this.allList[type];
  1384. // this.padingEvetn();
  1385. this.getdata();
  1386. },
  1387. // 切换释义
  1388. changeShiyi() {
  1389. this.page = 1;
  1390. this.padingEvetn();
  1391. },
  1392. // 排序
  1393. sortEvent(type) {
  1394. if (type !== this.sortType) {
  1395. this.sortType = type;
  1396. this.sort = '';
  1397. }
  1398. if (this.sort == 'down' || !this.sort) {
  1399. this.sort = 'up';
  1400. } else {
  1401. this.sort = 'down';
  1402. }
  1403. this.getdata();
  1404. this.page = 1;
  1405. },
  1406. // 修改大小
  1407. cutSize(index) {
  1408. this.sizeIndex = index;
  1409. if (index == 0) {
  1410. //大
  1411. if (this.patternIndex == 0) {
  1412. this.conSize = 24;
  1413. this.pinyinSize = 12;
  1414. } else {
  1415. this.conSize = 20;
  1416. }
  1417. } else if (index == 1) {
  1418. //中
  1419. if (this.patternIndex == 0) {
  1420. this.conSize = 20;
  1421. this.pinyinSize = 12;
  1422. } else {
  1423. this.conSize = 17;
  1424. }
  1425. } else {
  1426. //小
  1427. if (this.patternIndex == 0) {
  1428. this.conSize = 16;
  1429. this.pinyinSize = 10;
  1430. } else {
  1431. this.conSize = 15;
  1432. }
  1433. }
  1434. },
  1435. // 切换模式
  1436. cutPattern(index) {
  1437. if (this.patternIndex == index) {
  1438. return;
  1439. }
  1440. this.patternIndex = index;
  1441. this.getdata();
  1442. // if (this.patternIndex == 0) {
  1443. // this.CurrentList = JSON.parse(JSON.stringify(this.allList.sentence_list));
  1444. // } else {
  1445. // this.CurrentList = JSON.parse(JSON.stringify(this.allList.sentence_list_sort_left));
  1446. // }
  1447. // this.padingEvetn();
  1448. this.page = 1;
  1449. },
  1450. // 切换释义来源
  1451. cutsyly(index) {
  1452. if (this.rightTopIndex == index) {
  1453. return;
  1454. }
  1455. this.rightTopIndex = index;
  1456. if (this.rightTopIndex == 0) {
  1457. this.rightList = this.allList.stat_list_word_definition;
  1458. } else {
  1459. this.rightList = this.allList.stat_list_sentence_source_book;
  1460. }
  1461. // if (this.rightList.length > 0) {
  1462. this.inityuan();
  1463. // }
  1464. },
  1465. //编辑例句
  1466. handleEditLiju(item) {
  1467. this.actvieEditLijuItem = {
  1468. sentence_id: item ? item.sentence_id : '',
  1469. new_word: this.keyword ? this.keyword.trim() : '',
  1470. cixing: '',
  1471. source_path: item ? item.source_courseware_name_path_short : '',
  1472. definition_list: item ? item.word_definition_list.join('\n') : '',
  1473. sentence: item ? item.sentence_fc_list.join(' ') : '',
  1474. };
  1475. this.showEditLijuFlag = true;
  1476. },
  1477. handleClose() {
  1478. this.showEditLijuFlag = false;
  1479. this.actvieEditLijuItem = null;
  1480. },
  1481. // 保存
  1482. save() {
  1483. this.loading = true;
  1484. let word_list = [];
  1485. this.actvieEditLijuItem.sentence.split(' ').forEach((item) => {
  1486. let obj = {
  1487. word: item,
  1488. };
  1489. word_list.push(obj);
  1490. });
  1491. let Mname = 'book-courseware_manager-AddWordExampleSentence';
  1492. if (this.actvieEditLijuItem.sentence_id) {
  1493. Mname = 'book-courseware_manager-UpdateWordExampleSentence';
  1494. }
  1495. BookgetContent(Mname, {
  1496. sentence_id: this.actvieEditLijuItem.sentence_id,
  1497. new_word: {
  1498. new_word: this.actvieEditLijuItem.new_word,
  1499. cixing: this.actvieEditLijuItem.cixing,
  1500. definition_list: this.actvieEditLijuItem.definition_list.split('\n'),
  1501. },
  1502. source_path: this.actvieEditLijuItem.source_path,
  1503. word_list: word_list,
  1504. })
  1505. .then((res) => {
  1506. this.loading = false;
  1507. this.showEditLijuFlag = false;
  1508. this.actvieEditLijuItem = null;
  1509. this.$message.success('保存成功');
  1510. this.page = 1;
  1511. this.getdata(true);
  1512. })
  1513. .catch((res) => {
  1514. this.loading = false;
  1515. });
  1516. },
  1517. // 删除例句
  1518. handleDelLiju() {
  1519. if (this.selectDelLijuIds.length === 0) return;
  1520. this.loading = true;
  1521. let Mname = 'book-courseware_manager-DeleteWordExampleSentence';
  1522. BookgetContent(Mname, {
  1523. sentence_id_list: this.selectDelLijuIds,
  1524. })
  1525. .then((res) => {
  1526. this.loading = false;
  1527. this.selectDelLijuIds = [];
  1528. this.$message.success('删除成功');
  1529. this.getLevelList();
  1530. this.page = 1;
  1531. this.getdata(true);
  1532. })
  1533. .catch((res) => {
  1534. this.loading = false;
  1535. });
  1536. },
  1537. },
  1538. //生命周期 - 创建完成(可以访问当前this实例)
  1539. async created() {
  1540. const _this = this;
  1541. if (this.AccessToken) {
  1542. const Mname = 'login_control-ParseAccessToken';
  1543. await getStaticContent(Mname, {
  1544. access_token: _this.AccessToken,
  1545. }).then((res) => {
  1546. res.access_token = _this.AccessToken;
  1547. setToken(res);
  1548. sessionStorage.setItem('GCLS_Token_Tc', JSON.stringify(res));
  1549. this.showPage = true;
  1550. });
  1551. await getConfigInfor();
  1552. }
  1553. localStorage.removeItem('seekPageData');
  1554. this.showPage = true;
  1555. this.getLevelList();
  1556. this.getTotalCount();
  1557. if (this.keyword && this.keyword.trim()) {
  1558. this.getdata(true);
  1559. }
  1560. let userInfor = getToken()
  1561. ? JSON.parse(getToken())
  1562. : sessionStorage.getItem('GCLS_Token_Tc')
  1563. ? JSON.parse(sessionStorage.getItem('GCLS_Token_Tc'))
  1564. : null;
  1565. // userInfor.popedom_code_list = [2000004, 2000001, 2000007, 9000001];
  1566. this.editLiju = userInfor && userInfor.popedom_code_list && userInfor.popedom_code_list.indexOf(9000001) > -1;
  1567. },
  1568. //生命周期 - 挂载完成(可以访问DOM元素)
  1569. mounted() {},
  1570. //生命周期-创建之前
  1571. beforeCreated() {},
  1572. //生命周期-挂载之前
  1573. beforeMount() {},
  1574. //生命周期-更新之前
  1575. beforUpdate() {},
  1576. //生命周期-更新之后
  1577. updated() {},
  1578. //生命周期-销毁之前
  1579. beforeDestory() {},
  1580. //生命周期-销毁完成
  1581. destoryed() {},
  1582. //如果页面有keep-alive缓存功能,这个函数会触发
  1583. activated() {},
  1584. };
  1585. </script>
  1586. <style lang="scss" scoped>
  1587. /* @import url(); 引入css类 */
  1588. .corpus_seekpage {
  1589. .title {
  1590. margin-top: 24px;
  1591. > :nth-child(1) {
  1592. font-weight: 700;
  1593. font-size: 32px;
  1594. line-height: 38px;
  1595. color: #000000;
  1596. }
  1597. > :nth-child(2) {
  1598. font-weight: 400;
  1599. font-size: 14px;
  1600. line-height: 16px;
  1601. }
  1602. > p {
  1603. margin: 0;
  1604. text-align: center;
  1605. }
  1606. }
  1607. .seek {
  1608. margin-top: 18px;
  1609. display: flex;
  1610. justify-content: center;
  1611. height: 51px;
  1612. position: relative;
  1613. input {
  1614. width: 468px;
  1615. height: 51px;
  1616. border: 1px solid #669aff;
  1617. outline: none;
  1618. box-sizing: border-box;
  1619. padding: 0 10px;
  1620. }
  1621. button {
  1622. width: 96px;
  1623. height: 100%;
  1624. background: #669aff;
  1625. border-width: 1px 1px 1px 0px;
  1626. border-style: solid;
  1627. border-color: #669aff;
  1628. text-align: center;
  1629. font-weight: 400;
  1630. font-size: 16px;
  1631. line-height: 51px;
  1632. color: #ffffff;
  1633. cursor: pointer;
  1634. box-sizing: border-box;
  1635. }
  1636. .set_corpus {
  1637. position: absolute;
  1638. top: 16px;
  1639. }
  1640. }
  1641. .txt {
  1642. margin-top: 24px;
  1643. text-align: center;
  1644. font-weight: 400;
  1645. font-size: 16px;
  1646. line-height: 19px;
  1647. color: #000000;
  1648. opacity: 0.65;
  1649. }
  1650. .txt_imgtable {
  1651. width: 1200px;
  1652. margin: 0 auto;
  1653. .left {
  1654. position: relative;
  1655. width: 100%;
  1656. padding-bottom: 68px;
  1657. margin-right: 8px;
  1658. background: #fff;
  1659. border: 1px solid rgba(0, 0, 0, 8%);
  1660. border-radius: 0 0 8px 8px;
  1661. > .top {
  1662. display: flex;
  1663. align-items: center;
  1664. justify-content: space-between;
  1665. height: 44px;
  1666. font-size: 12px;
  1667. font-weight: 400;
  1668. color: #000;
  1669. border-bottom: 1px solid rgba(0, 0, 0, 8%);
  1670. > div {
  1671. display: flex;
  1672. align-items: center;
  1673. column-gap: 16px;
  1674. }
  1675. .KWIC_sort {
  1676. display: flex;
  1677. span {
  1678. display: inline-block;
  1679. display: flex;
  1680. align-items: center;
  1681. justify-content: center;
  1682. width: 28px;
  1683. height: 28px;
  1684. cursor: pointer;
  1685. background: #fff;
  1686. border-radius: 4px;
  1687. }
  1688. .sele {
  1689. background: #f0f0f0;
  1690. }
  1691. .sort {
  1692. img {
  1693. width: 14px;
  1694. height: 12px;
  1695. }
  1696. }
  1697. .down {
  1698. img {
  1699. width: 16px;
  1700. height: 16px;
  1701. }
  1702. }
  1703. }
  1704. .pattern {
  1705. display: flex;
  1706. align-items: center;
  1707. justify-content: center;
  1708. width: 144px;
  1709. height: 28px;
  1710. margin-left: 16px;
  1711. background: #eee;
  1712. border-radius: 4px;
  1713. > div {
  1714. width: 68px;
  1715. height: 24px;
  1716. font-size: 12px;
  1717. font-weight: 400;
  1718. line-height: 24px;
  1719. color: #888;
  1720. text-align: center;
  1721. cursor: pointer;
  1722. border-radius: 2px;
  1723. }
  1724. .sele {
  1725. color: #000;
  1726. background: #fff;
  1727. box-shadow: 0 2px 2px rgba(0, 0, 0, 8%);
  1728. }
  1729. }
  1730. .refresh {
  1731. display: flex;
  1732. align-items: center;
  1733. justify-content: center;
  1734. width: 28px;
  1735. height: 28px;
  1736. cursor: pointer;
  1737. background: #eee;
  1738. border-radius: 4px;
  1739. img {
  1740. width: 16px;
  1741. height: 16px;
  1742. }
  1743. }
  1744. .size {
  1745. margin-right: 12px;
  1746. span {
  1747. padding: 4px;
  1748. font-size: 14px;
  1749. cursor: pointer;
  1750. }
  1751. .sele {
  1752. background: #e6e6e6;
  1753. border-radius: 4px;
  1754. }
  1755. }
  1756. }
  1757. .lang_sort {
  1758. display: flex;
  1759. align-items: center;
  1760. justify-content: center;
  1761. width: max-content;
  1762. cursor: pointer;
  1763. margin-right: 16px;
  1764. border-radius: 20px;
  1765. border: 1px solid #e5e6eb;
  1766. padding: 4px 12px;
  1767. font-size: 14px;
  1768. &.active {
  1769. border-color: #4992ff;
  1770. background: #4992ff;
  1771. color: #fff;
  1772. }
  1773. img {
  1774. width: 16px;
  1775. height: 16px;
  1776. margin-left: 2px;
  1777. }
  1778. }
  1779. }
  1780. .right {
  1781. width: 100%;
  1782. padding-bottom: 39px;
  1783. background: #fff;
  1784. border: 1px solid rgba(0, 0, 0, 8%);
  1785. border-radius: 8px;
  1786. margin-top: 16px;
  1787. .top {
  1788. display: flex;
  1789. align-items: center;
  1790. height: 44px;
  1791. // border-bottom: 1px solid rgba(0, 0, 0, 8%);
  1792. > div {
  1793. display: flex;
  1794. align-items: center;
  1795. justify-content: center;
  1796. // width: 84px;
  1797. padding: 0 2px;
  1798. height: 28px;
  1799. margin-left: 16px;
  1800. background: #eee;
  1801. border-radius: 4px;
  1802. > div {
  1803. width: 40px;
  1804. height: 24px;
  1805. font-size: 12px;
  1806. font-weight: 400;
  1807. line-height: 24px;
  1808. color: #888;
  1809. text-align: center;
  1810. cursor: pointer;
  1811. border-radius: 2px;
  1812. }
  1813. .sele {
  1814. color: #000;
  1815. background: #fff;
  1816. box-shadow: 0 2px 2px rgba(0, 0, 0, 8%);
  1817. }
  1818. }
  1819. }
  1820. .bottom {
  1821. display: flex;
  1822. }
  1823. .list {
  1824. width: 508px;
  1825. margin: 0 auto;
  1826. max-height: 1450px;
  1827. overflow: auto;
  1828. .one {
  1829. display: flex;
  1830. justify-content: space-between;
  1831. padding: 12px;
  1832. font-size: 14px;
  1833. font-weight: 400;
  1834. line-height: 22px;
  1835. color: #333;
  1836. cursor: pointer;
  1837. border-bottom: 1px solid #eee;
  1838. > :nth-child(1) {
  1839. text-align: left;
  1840. }
  1841. > div {
  1842. width: 186px;
  1843. text-align: center;
  1844. }
  1845. }
  1846. .all {
  1847. font-size: 14px;
  1848. font-weight: 600;
  1849. line-height: 22px;
  1850. color: #333;
  1851. border-bottom: none;
  1852. }
  1853. }
  1854. }
  1855. }
  1856. .cx-list {
  1857. width: 1200px;
  1858. margin: 24px auto 0 auto;
  1859. display: flex;
  1860. justify-content: space-between;
  1861. .cx-list-box {
  1862. display: flex;
  1863. padding: 8px 16px;
  1864. align-items: center;
  1865. gap: 16px;
  1866. border-radius: 8px 8px 0px 0px;
  1867. border: 1px solid #ebebeb;
  1868. background: #f7f7f7;
  1869. border-bottom: none;
  1870. width: max-content;
  1871. color: #000;
  1872. font-size: 16px;
  1873. line-height: 24px;
  1874. label {
  1875. display: flex;
  1876. padding: 4px 16px;
  1877. flex-wrap: wrap;
  1878. border-radius: 4px;
  1879. gap: 8px;
  1880. background: #fff;
  1881. color: #007eff;
  1882. font-size: 14px;
  1883. font-weight: 600;
  1884. line-height: 22px;
  1885. > :nth-child(2) {
  1886. color: #000;
  1887. font-weight: 400;
  1888. }
  1889. }
  1890. }
  1891. .el-button {
  1892. font-weight: 400;
  1893. height: 38px;
  1894. }
  1895. .edit-liju {
  1896. padding: 8px 16px;
  1897. border-radius: 4px;
  1898. border: 1px solid #669aff;
  1899. background: #fff;
  1900. color: #2164e4;
  1901. font-size: 14px;
  1902. line-height: 22px;
  1903. }
  1904. }
  1905. .main {
  1906. // height: 95%;
  1907. .list {
  1908. margin-top: 16px;
  1909. .one {
  1910. padding: 0 16px;
  1911. margin-bottom: 8px;
  1912. display: flex;
  1913. align-items: end;
  1914. .top {
  1915. display: flex;
  1916. // align-items: center;
  1917. // flex-flow: wrap;
  1918. width: 100%;
  1919. .number {
  1920. flex-shrink: 0;
  1921. width: 22px;
  1922. margin-right: 8px;
  1923. font-size: 14px;
  1924. font-weight: 400;
  1925. line-height: 21px;
  1926. color: rgba(0, 0, 0, 30%);
  1927. text-align: right;
  1928. &-1-false {
  1929. margin-top: 3px;
  1930. }
  1931. &-0-true {
  1932. margin-top: 21px;
  1933. }
  1934. &-0-false {
  1935. margin-top: 5px;
  1936. }
  1937. &-2-true {
  1938. margin-top: 17px;
  1939. }
  1940. &-2-false {
  1941. margin-top: 1px;
  1942. }
  1943. }
  1944. img {
  1945. width: 16px;
  1946. height: 16px;
  1947. margin-right: 8px;
  1948. cursor: pointer;
  1949. &.speaker-1-false {
  1950. margin-top: 6px;
  1951. }
  1952. &.speaker-0-true {
  1953. margin-top: 24px;
  1954. }
  1955. &.speaker-0-false {
  1956. margin-top: 8px;
  1957. }
  1958. &.speaker-2-true {
  1959. margin-top: 20px;
  1960. }
  1961. &.speaker-2-false {
  1962. margin-top: 4px;
  1963. }
  1964. }
  1965. .words {
  1966. // display: flex;
  1967. // align-items: flex-end;
  1968. // flex-flow: wrap;
  1969. font-family: 'FZJCGFKTK';
  1970. word-break: break-all;
  1971. > div {
  1972. .pinyin {
  1973. margin-bottom: 2px;
  1974. font-family: 'League';
  1975. font-size: 12px;
  1976. font-weight: 500;
  1977. color: rgba(0, 0, 0, 50%);
  1978. text-align: center;
  1979. }
  1980. .con {
  1981. font-family: 'FZJCGFKTK';
  1982. font-size: 20px;
  1983. font-weight: 400;
  1984. color: #000;
  1985. text-align: center;
  1986. }
  1987. }
  1988. }
  1989. .shiyi {
  1990. font-size: 12px;
  1991. font-weight: 400;
  1992. line-height: 24px;
  1993. color: #48a3e6;
  1994. font-family: 'robot', 'FZJCGFKTK';
  1995. &-0 {
  1996. line-height: 32px;
  1997. }
  1998. &-1 {
  1999. line-height: 28px;
  2000. }
  2001. }
  2002. }
  2003. .bottom {
  2004. font-size: 12px;
  2005. font-weight: 400;
  2006. line-height: 150%;
  2007. color: rgba(0, 0, 0, 30%);
  2008. text-align: right;
  2009. width: 117px;
  2010. overflow: hidden;
  2011. text-overflow: ellipsis;
  2012. white-space: nowrap;
  2013. flex-shrink: 0;
  2014. }
  2015. }
  2016. .kwic_one {
  2017. display: flex;
  2018. align-items: center;
  2019. padding: 0 16px;
  2020. justify-content: space-between;
  2021. > :nth-child(1) {
  2022. justify-content: flex-end;
  2023. width: 16px;
  2024. margin-right: 16px;
  2025. }
  2026. .laiyuan {
  2027. width: 117px;
  2028. overflow: hidden;
  2029. font-size: 14px;
  2030. font-weight: 400;
  2031. line-height: 22px;
  2032. color: rgba(0, 0, 0, 65%);
  2033. text-overflow: ellipsis;
  2034. white-space: nowrap;
  2035. }
  2036. .word {
  2037. display: flex;
  2038. justify-content: center;
  2039. // width: 361px;
  2040. height: 22px;
  2041. margin-left: 16px;
  2042. overflow: hidden;
  2043. font-family: 'FZJCGFKTK';
  2044. font-size: 14px;
  2045. font-weight: 400;
  2046. line-height: 22px;
  2047. color: #000;
  2048. white-space: nowrap;
  2049. opacity: 1;
  2050. > :nth-child(1) {
  2051. // direction: rtl;
  2052. // unicode-bidi: plaintext;
  2053. // text-align: right;
  2054. display: flex;
  2055. justify-content: flex-end;
  2056. width: 472px;
  2057. overflow: hidden;
  2058. white-space: nowrap;
  2059. }
  2060. > :nth-child(3) {
  2061. width: 472px;
  2062. overflow: hidden;
  2063. text-align: left;
  2064. white-space: nowrap;
  2065. direction: ltr;
  2066. unicode-bidi: plaintext;
  2067. }
  2068. }
  2069. }
  2070. }
  2071. .page {
  2072. position: absolute;
  2073. bottom: 0;
  2074. box-sizing: border-box;
  2075. display: flex;
  2076. justify-content: space-between;
  2077. align-items: center;
  2078. width: 100%;
  2079. height: 64px;
  2080. border-top: 1px solid rgba(0, 0, 0, 0.08);
  2081. padding: 16px;
  2082. .text {
  2083. display: flex;
  2084. align-items: center;
  2085. font-size: 14px;
  2086. font-weight: 400;
  2087. line-height: 22px;
  2088. color: rgba(0, 0, 0, 60%);
  2089. text-align: center;
  2090. }
  2091. }
  2092. }
  2093. .edit-liju-box {
  2094. width: 1200px;
  2095. margin: 0 auto;
  2096. border-radius: 0px 8px 8px 8px;
  2097. border: 1px solid rgba(0, 0, 0, 0.08);
  2098. background: #fff;
  2099. box-sizing: border-box;
  2100. > .top {
  2101. display: flex;
  2102. justify-content: space-between;
  2103. align-items: center;
  2104. border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  2105. padding: 8px 16px;
  2106. .select-number {
  2107. color: #669aff;
  2108. font-size: 14px;
  2109. font-weight: 500;
  2110. line-height: 22px;
  2111. margin-right: 16px;
  2112. }
  2113. .el-button {
  2114. padding: 4px 12px;
  2115. font-size: 14px;
  2116. font-weight: 400;
  2117. line-height: 22px;
  2118. border-radius: 20px;
  2119. }
  2120. }
  2121. .page {
  2122. position: inherit;
  2123. }
  2124. .el-icon-edit-outline {
  2125. cursor: pointer;
  2126. margin-left: 4px;
  2127. }
  2128. }
  2129. }
  2130. </style>
  2131. <style lang="scss">
  2132. .result {
  2133. .el-switch__core {
  2134. width: 26px !important;
  2135. height: 16px;
  2136. }
  2137. .el-switch__core::after {
  2138. top: 3px;
  2139. width: 8px;
  2140. height: 8px;
  2141. }
  2142. .el-switch.is-checked .el-switch__core::after {
  2143. margin-left: -10px;
  2144. }
  2145. .el-switch__label.is-active {
  2146. color: #000;
  2147. }
  2148. .page {
  2149. .el-pagination.is-background .el-pager li:not(.disabled).active {
  2150. background-color: #0052d9;
  2151. }
  2152. .el-pager li {
  2153. background: #fff;
  2154. border: 1px solid #dcdcdc;
  2155. border-radius: 3px;
  2156. }
  2157. }
  2158. }
  2159. .el-loading-mask {
  2160. z-index: 200000 !important;
  2161. }
  2162. .checkAllCheckbox {
  2163. width: 100%;
  2164. padding: 0 20px;
  2165. height: 34px;
  2166. line-height: 34px;
  2167. &:hover {
  2168. background-color: #f5f7fa;
  2169. }
  2170. .el-checkbox__input {
  2171. display: none;
  2172. }
  2173. .el-checkbox__label {
  2174. padding: 0;
  2175. }
  2176. }
  2177. .selectBook {
  2178. .el-tag {
  2179. max-width: 90px;
  2180. }
  2181. }
  2182. .el-button--primary,
  2183. .el-checkbox__input.is-checked .el-checkbox__inner,
  2184. .el-checkbox__input.is-indeterminate .el-checkbox__inner {
  2185. background-color: #669aff;
  2186. border-color: #669aff;
  2187. }
  2188. .el-button--primary.is-plain {
  2189. color: #669aff;
  2190. border-color: #669aff;
  2191. &:hover {
  2192. background-color: #669aff;
  2193. }
  2194. }
  2195. .el-checkbox__inner {
  2196. border-color: #669aff;
  2197. }
  2198. .seekpage-dialog {
  2199. .el-dialog__header {
  2200. padding: 0;
  2201. }
  2202. label {
  2203. color: #000;
  2204. font-size: 14px;
  2205. font-weight: 400;
  2206. line-height: 22px;
  2207. margin-bottom: 8px;
  2208. display: block;
  2209. }
  2210. .el-input {
  2211. margin-bottom: 8px;
  2212. }
  2213. .tips {
  2214. color: rgba(0, 0, 0, 0.4);
  2215. font-size: 14px;
  2216. font-weight: 400;
  2217. line-height: 22px;
  2218. margin-bottom: 8px;
  2219. display: block;
  2220. }
  2221. p {
  2222. color: #ff5757;
  2223. font-size: 24px;
  2224. font-weight: 400;
  2225. line-height: 32px;
  2226. margin-bottom: 8px;
  2227. }
  2228. }
  2229. </style>