index.vue 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855
  1. <template>
  2. <div class="full flex direction-column">
  3. <div class="flex items-center p-extra-small fill-blank header-view">
  4. <el-button class="m-r-auto" size="small" plain @click="back()">返回</el-button>
  5. <div class="data-item">
  6. <user-info></user-info>
  7. </div>
  8. <div class="data-item">
  9. <div class="icon-item">
  10. <lock-entry />
  11. </div>
  12. <div class="icon-item">
  13. <message :paper-path="current?.filePath" :secret-number="current?.secretNumber"></message>
  14. </div>
  15. </div>
  16. </div>
  17. <div class="flex-1 overflow-hidden flex direction-column">
  18. <div class="fill-blank filter-header flex items-center">
  19. <div class="flex-1 flex items-center">
  20. <span class="m-name">评卷员:{{ query.markerName }}</span>
  21. <base-form size="small" :items="formItems" :model="model">
  22. <!-- <template #form-item-search>
  23. <el-button type="primary" :loading="loading1 || loading2" @click="onSearch">刷新</el-button>
  24. </template> -->
  25. </base-form>
  26. </div>
  27. <el-button type="primary" :loading="loading1 || loading2" size="small" @click="onSearch">刷新</el-button>
  28. </div>
  29. <div class="flex-1 p-base flex direction-column overflow-hidden">
  30. <div class="flex-1 overflow-hidden mark-container">
  31. <splitpanes class="default-theme" style="height: 100%" @resize="setPaneSize">
  32. <pane
  33. max-size="80"
  34. :size="paneSize"
  35. class="flex flex-1 direction-column radius-base fill-blank mark-content"
  36. :class="{ 'text-center': center }"
  37. :style="{ 'background-color': backgroundColor }"
  38. >
  39. <span class="preview" @click="onPreview">
  40. <svg-icon name="preview"></svg-icon>
  41. </span>
  42. <p v-if="current" class="absolute question-info">{{ current.mainNumber + '-' + current.mainName }}</p>
  43. <p v-if="current" class="absolute mark-score">{{ current.markScore }}</p>
  44. <!-- <right-button class="next-button" @click="checkNext" /> -->
  45. <div class="flex-1 p-base scroll-auto mark-content-paper img-wrap">
  46. <img :src="dataUrl" alt="" class="paper-img" :style="{ 'background-color': frontColor }" />
  47. </div>
  48. <div class="flex items-center p-t-base">
  49. <el-button
  50. :disabled="!current?.taskId"
  51. class="m-l-base"
  52. size="small"
  53. type="primary"
  54. style="margin-bottom: 4px"
  55. @click="onSendBack"
  56. >打回</el-button
  57. >
  58. <el-button
  59. custom-1
  60. class="m-l-base m-r-auto"
  61. size="small"
  62. type="success"
  63. :disabled="!tableData?.length"
  64. style="margin-bottom: 4px"
  65. @click="multToggle"
  66. >{{ isMult ? '取消多选' : '多选' }}</el-button
  67. >
  68. <div class="flex-1 flex justify-end items-center">
  69. <scoring-panel-with-confirm
  70. :id="current?.taskId"
  71. v-model:visible="editScoreVisible"
  72. v-model:score="modelScore"
  73. :main-number="current?.mainNumber"
  74. :subject-code="query.subjectCode"
  75. modal
  76. :auto-visible="false"
  77. :cannot-toggle="true"
  78. @submit="onSubmit"
  79. ></scoring-panel-with-confirm>
  80. </div>
  81. </div>
  82. </pane>
  83. <pane
  84. max-size="80"
  85. :size="100 - paneSize"
  86. class="flex direction-column p-base radius-base fill-blank table-view"
  87. >
  88. <!-- <div class="flex items-center p-b-base m-b-base marker-name">
  89. <span>评卷员</span>
  90. <span>{{ query.markerName }}</span>
  91. </div> -->
  92. <div class="flex items-center justify-between detail-info-table-header">
  93. <div v-if="tableModel.score !== ''" class="choose-score-info">
  94. <span class="txt">{{ tableModel.score }}分段</span>
  95. <span class="close" @click="tableModel.score = ''">&times;</span>
  96. </div>
  97. <div v-else></div>
  98. <btn-pagination v-model="currentPage" :pagination="pagination"></btn-pagination>
  99. </div>
  100. <div class="flex-1 scroll-auto m-t-mini">
  101. <base-table
  102. ref="tableRef"
  103. border
  104. stripe
  105. size="small"
  106. v-bind="pagination"
  107. height="100%"
  108. :data="tableData"
  109. :columns="columns"
  110. :highlight-current-row="!isMult"
  111. :cell-style="{ padding: '6px 0' }"
  112. :memory-column="true"
  113. @current-change="onCurrentChange"
  114. @row-dblclick="onDbClick"
  115. @selection-change="handleSelectionChange"
  116. ></base-table>
  117. </div>
  118. </pane>
  119. </splitpanes>
  120. </div>
  121. <div class="chart-space m-t-base flex justify-between items-center">
  122. <div class="new-chart-box radius-base">
  123. <vue-echarts class="full" :option="markerSubjectiveChartsOption"></vue-echarts>
  124. </div>
  125. <div class="new-chart-box radius-base">
  126. <vue-echarts class="full" :option="markerObjectiveChartsOption"></vue-echarts>
  127. </div>
  128. </div>
  129. </div>
  130. </div>
  131. </div>
  132. <image-preview v-model="previewModalVisible" :url="current?.filePath"></image-preview>
  133. <!-- <send-back-mark
  134. :id="current?.taskId"
  135. v-model="sendBackVisible"
  136. type="custom-check"
  137. @rejected="onRejected"
  138. ></send-back-mark> -->
  139. <send-back-mark :id="rejectIds" v-model="sendBackVisible" type="custom-check" @rejected="onRejected"></send-back-mark>
  140. <mark-history-list
  141. :id="currentViewHistory?.taskId"
  142. v-model="visibleHistory"
  143. :task="currentViewHistory"
  144. ></mark-history-list>
  145. </template>
  146. <script setup lang="tsx" name="AnalysisPersonnelStatisticsMarker">
  147. /** 评卷员明细统计 */
  148. import { computed, reactive, ref, watch, nextTick } from 'vue'
  149. import { useRouter, useRoute } from 'vue-router'
  150. import { ElButton, ElMessage } from 'element-plus'
  151. import dayjs from 'dayjs'
  152. import VueEcharts from 'vue-echarts'
  153. import Message from '@/components/shared/message/Message.vue'
  154. import UserInfo from '@/components/shared/UserInfo.vue'
  155. import BaseTable from '@/components/element/BaseTable.vue'
  156. import BaseForm from '@/components/element/BaseForm.vue'
  157. import useFetch from '@/hooks/useFetch'
  158. import useTable from '@/hooks/useTable'
  159. import useTableCheck from '@/hooks/useTableCheck'
  160. import LockEntry from '@/components/common/LockEntry.vue'
  161. import { Splitpanes, Pane } from 'splitpanes'
  162. import { setPaneSize } from '@/utils/common'
  163. import SendBackMark from '@/components/shared/SendBackMark.vue'
  164. import useMarkHeader from '@/hooks/useMarkHeader'
  165. import MarkHistoryList from '@/components/shared/MarkHistoryList.vue'
  166. import { add } from '@/utils/common'
  167. import { useSetImgBg } from '@/hooks/useSetImgBg'
  168. import SvgIcon from '@/components/common/SvgIcon.vue'
  169. import useMainStore from '@/store/main'
  170. import ScoringPanelWithConfirm from '@/components/shared/ScoringPanelWithConfirm.vue'
  171. import ImagePreview from '@/components/shared/ImagePreview.vue'
  172. import BtnPagination from '@/components/common/BtnPagination.vue'
  173. import SecNumberStatus from '@/components/common/secNumberStatus.vue'
  174. import { ElIcon } from 'element-plus'
  175. import { Close } from '@element-plus/icons-vue'
  176. import type { EChartsOption } from 'echarts'
  177. import type { ExtractApiResponse } from '@/api/api'
  178. import type { EpTableColumn, EpFormItem } from 'global-type'
  179. import type { SetImgBgOption } from '@/hooks/useSetImgBg'
  180. const isMult = ref(false)
  181. const multipleSelection = ref<any>([])
  182. const handleSelectionChange = (val: any) => {
  183. multipleSelection.value = val
  184. }
  185. const mainStore = useMainStore()
  186. const paneSize = computed(() => {
  187. return mainStore.paneSizeConfig[location.pathname] || 70
  188. })
  189. const { back, push } = useRouter()
  190. const { query } = useRoute()
  191. /** 打回弹窗 */
  192. const sendBackVisible = ref<boolean>(false)
  193. /** 打回 */
  194. const onSendBack = () => {
  195. sendBackVisible.value = true
  196. }
  197. /** 打回成功 */
  198. const onRejected = () => {
  199. // onRefresh()
  200. ElMessage.success('打回成功')
  201. fetchTable()
  202. }
  203. /** 给分板 */
  204. const editScoreVisible = ref<boolean>(true)
  205. /** 图片预览 */
  206. const previewModalVisible = ref<boolean>(false)
  207. /** 分数 */
  208. const modelScore = ref<number[]>([])
  209. const {
  210. rotate,
  211. scale,
  212. center,
  213. frontColor,
  214. backgroundColor,
  215. onBack,
  216. onScaleChange,
  217. onCenter,
  218. onRotate,
  219. setBackgroundColor,
  220. setFrontColor,
  221. onViewStandard,
  222. } = useMarkHeader()
  223. /** 刷新 */
  224. const onRefresh = () => {
  225. fetchTable()
  226. }
  227. /** 预览试卷 */
  228. const onPreview = () => {
  229. previewModalVisible.value = true
  230. }
  231. const model = reactive({
  232. type: 'today',
  233. })
  234. const tableModel = reactive<any>({
  235. markerId: query.markerId,
  236. score: '',
  237. pageSize: 100,
  238. subjectCode: query.subjectCode as string,
  239. mainNumber: query.questionMainNumber as string,
  240. today: true,
  241. })
  242. watch(
  243. () => model.type,
  244. () => {
  245. tableModel.today = model.type === 'today'
  246. }
  247. )
  248. ;(window as any)._tableModel = tableModel
  249. const { pagination, currentPage, data, fetchTable } = useTable('getPersonalMarkDetail', tableModel)
  250. const {
  251. tableRef,
  252. tableData,
  253. current,
  254. currentView: currentViewHistory,
  255. next: checkNext,
  256. visibleHistory,
  257. onDbClick,
  258. onCurrentChange,
  259. nextRow,
  260. elTableRef,
  261. } = useTableCheck(data, true, null, false, isMult)
  262. /** 确定给分 */
  263. const { fetch: updatePersonalMarkDetailScore } = useFetch('updatePersonalMarkDetailScore')
  264. const onSubmit = async () => {
  265. if (current.value) {
  266. const scores = JSON.parse(JSON.stringify(modelScore.value))
  267. let res: any = await updatePersonalMarkDetailScore({
  268. taskId: current.value.taskId,
  269. scores: modelScore.value,
  270. source: (query.source as string) || '',
  271. })
  272. // current.value.markerScore = add(...scores)
  273. current.value.markScore = add(...scores)
  274. current.value.checked = res.checked
  275. current.value.corrected = res.corrected
  276. current.value.markerScore = res.markerScore
  277. current.value.objectiveScore = res.objectiveScore
  278. current.value.ratio = res.ratio
  279. current.value.markTime = res.markTime
  280. current.value.markerScore = res.markerScore
  281. ElMessage.success('修改成功')
  282. // editScoreVisible.value = false
  283. // onRefresh()
  284. nextRow()
  285. }
  286. }
  287. watch(current, () => {
  288. if (current.value) {
  289. useFetch('viewActiveCheck')
  290. .fetch({ taskId: current.value?.taskId })
  291. .then(() => {
  292. if (!current.value.checked) {
  293. current.value.checked = true
  294. }
  295. })
  296. }
  297. })
  298. const imgOption = computed<SetImgBgOption>(() => {
  299. return {
  300. image: current?.value?.filePath || '',
  301. rotate: rotate.value,
  302. scale: scale.value,
  303. }
  304. })
  305. const { drawing, dataUrl } = useSetImgBg(imgOption, frontColor, setFrontColor)
  306. onRefresh()
  307. watch(
  308. () => tableModel.score,
  309. () => {
  310. fetchTable()
  311. }
  312. )
  313. const formItems: EpFormItem[] = [
  314. {
  315. label: '统计方式',
  316. prop: 'type',
  317. slotType: 'radio',
  318. rowKey: 'row-1',
  319. slot: {
  320. options: [
  321. { label: 'total', slotLabel: '积累' },
  322. { label: 'today', slotLabel: '当天' },
  323. ],
  324. },
  325. // colProp: {
  326. // span: 4,
  327. // offset: 18,
  328. // },
  329. },
  330. // {
  331. // slotName: 'search',
  332. // rowKey: 'row-1',
  333. // colProp: {
  334. // span: 2,
  335. // },
  336. // },
  337. ]
  338. const {
  339. fetch: getStatisticObjectiveByMarker,
  340. result: objectiveByMarker,
  341. loading: loading1,
  342. } = useFetch('getStatisticObjectiveByMarker')
  343. const {
  344. fetch: getStatisticSubjectiveByMarker,
  345. result: subjectiveByMarker,
  346. loading: loading2,
  347. } = useFetch('getStatisticSubjectiveByMarker')
  348. type TableDataType = ExtractArrayValue<ExtractApiResponse<'getStatisticObjectiveByMarker'>['segmentsByAll']> & {
  349. groupCount: number
  350. groupRate: number
  351. allCount: number
  352. allRate: number
  353. }
  354. type GroupData = Record<number, { groupCount: number; groupRate: number }>
  355. type AllData = Record<number, { allCount: number; allRate: number }>
  356. const objectiveGroupData = computed<GroupData>(() => {
  357. return objectiveByMarker.value?.segmentsByGroup?.reduce((result, data) => {
  358. result[data.scoreStart] = { groupCount: data.count, groupRate: data.rate }
  359. return result
  360. }, {} as GroupData)
  361. })
  362. const objectiveAllData = computed<AllData>(() => {
  363. return objectiveByMarker.value?.segmentsByAll?.reduce((result, data) => {
  364. result[data.scoreStart] = { allCount: data.count, allRate: data.rate }
  365. return result
  366. }, {} as AllData)
  367. })
  368. const subjectiveGroupData = computed<GroupData>(() => {
  369. return subjectiveByMarker.value?.segmentsByGroup?.reduce((result, data) => {
  370. result[data.scoreStart] = { groupCount: data.count, groupRate: data.rate }
  371. return result
  372. }, {} as GroupData)
  373. })
  374. const subjectiveAllData = computed<AllData>(() => {
  375. return subjectiveByMarker.value?.segmentsByAll?.reduce((result, data) => {
  376. result[data.scoreStart] = { allCount: data.count, allRate: data.rate }
  377. return result
  378. }, {} as AllData)
  379. })
  380. const objectiveTableData = computed<TableDataType[]>(() => {
  381. return objectiveByMarker?.value?.segmentsByUser.map((d) => ({
  382. ...d,
  383. ...objectiveGroupData.value?.[d.scoreStart],
  384. ...objectiveAllData.value?.[d.scoreStart],
  385. }))
  386. })
  387. // const columns: EpTableColumn<any>[] = [
  388. // {
  389. // label: '评卷员',
  390. // prop: 'markerName',
  391. // minWidth: 90,
  392. // formatter(row: any) {
  393. // return (
  394. // <SecNumberStatus
  395. // secretNumber={row.markerName}
  396. // checked={row.checked}
  397. // corrected={row.corrected}
  398. // ></SecNumberStatus>
  399. // )
  400. // },
  401. // },
  402. // {
  403. // label: '密号',
  404. // prop: 'secretNumber',
  405. // minWidth: 110,
  406. // },
  407. // { label: '给分', prop: 'markerScore', minWidth: 70 },
  408. // { label: '客观分', prop: 'objectiveScore', minWidth: 70 },
  409. // { label: '客主比', prop: 'markerRatio', minWidth: 80 },
  410. // { label: '成绩客主比', prop: 'ratio', minWidth: 110 },
  411. // { label: '成绩', prop: 'markScore', minWidth: 70 },
  412. // ]
  413. const columns: any = computed(() => {
  414. let cols: any = [
  415. {
  416. label: '评卷员',
  417. prop: 'markerName',
  418. minWidth: 90,
  419. formatter(row: any) {
  420. return (
  421. <SecNumberStatus
  422. secretNumber={row.markerName}
  423. checked={row.checked}
  424. corrected={row.corrected}
  425. ></SecNumberStatus>
  426. )
  427. },
  428. },
  429. {
  430. label: '密号',
  431. prop: 'secretNumber',
  432. minWidth: 110,
  433. },
  434. { label: '给分', prop: 'markerScore', minWidth: 70 },
  435. { label: '客观分', prop: 'objectiveScore', minWidth: 70 },
  436. { label: '客主比', prop: 'markerRatio', minWidth: 80 },
  437. { label: '成绩客主比', prop: 'ratio', minWidth: 110 },
  438. { label: '成绩', prop: 'markScore', minWidth: 70 },
  439. ]
  440. if (isMult.value) {
  441. cols.unshift({
  442. type: 'selection',
  443. width: 55,
  444. })
  445. }
  446. return cols
  447. })
  448. const onSearch = () => {
  449. fetchTable()
  450. if (query.markerId) {
  451. const startTime = model.type === 'today' ? dayjs().startOf('day').format('YYYYMMDDHHmmss') : ''
  452. getStatisticObjectiveByMarker({
  453. markerId: query.markerId as string,
  454. startTime,
  455. endTime: '',
  456. })
  457. getStatisticSubjectiveByMarker({
  458. markerId: query.markerId as string,
  459. startTime,
  460. endTime: '',
  461. })
  462. }
  463. }
  464. type StatisticObjectiveByMarker = ExtractApiResponse<'getStatisticObjectiveByMarker'>
  465. type StatisticObjectiveByMarkerValues = StatisticObjectiveByMarker['segmentsByAll']
  466. const getXAxisData = <K extends keyof ExtractArrayValue<StatisticObjectiveByMarkerValues>>(
  467. field: K,
  468. data?: StatisticObjectiveByMarkerValues
  469. ) => {
  470. if (!data) {
  471. return []
  472. }
  473. const getValue = (key: K, item: ExtractArrayValue<StatisticObjectiveByMarkerValues>) => {
  474. return item[key]
  475. }
  476. return data?.map((v) => getValue(field, v))
  477. }
  478. const markerSubjectiveChartsOption = computed<EChartsOption>(() => {
  479. return {
  480. grid: {
  481. top: 50,
  482. bottom: 15,
  483. left: 30,
  484. right: 30,
  485. containLabel: true,
  486. },
  487. legend: {
  488. top: 10,
  489. itemWidth: 14,
  490. data: ['评卷员主观分布', '小组主观分布', '题组主观分布'],
  491. },
  492. tooltip: {
  493. trigger: 'axis',
  494. triggerOn: 'click',
  495. enterable: true,
  496. axisPointer: {
  497. type: 'line',
  498. crossStyle: {
  499. color: '#999',
  500. },
  501. lineStyle: {
  502. type: 'dashed',
  503. },
  504. },
  505. formatter: function (params: any) {
  506. let html = `
  507. <div>
  508. <div style="font-size:14px;color:#0091ff;font-weight:bold;text-decoration:underline;cursor:pointer;margin-bottom:8px" onclick="window._tableModel.score=${params[0].axisValue}">${params[0].axisValue}分段</div>
  509. <div>
  510. `
  511. for (let i = 0; i < params.length; i++) {
  512. let item = params[i]
  513. html += `
  514. <div style="margin: 0px 0 0">
  515. ${item.marker}
  516. <span style="font-size:14px;color:#666;font-weight:400;margin-left:2px">${item.seriesName}</span>
  517. <span style="float:right;margin-left:20px;font-size:14px;color:#666;font-weight:900">${item.data}</span>
  518. <div style="clear:both"></div>
  519. </div>
  520. </div>
  521. `
  522. }
  523. html += `
  524. </div>
  525. </div>
  526. `
  527. return html
  528. },
  529. },
  530. xAxis: {
  531. axisLine: { show: false },
  532. axisTick: { show: false },
  533. splitLine: { show: false },
  534. axisLabel: {
  535. align: 'right',
  536. },
  537. data: getXAxisData('scoreStart', subjectiveByMarker?.value?.segmentsByAll),
  538. },
  539. yAxis: [
  540. {
  541. type: 'value',
  542. },
  543. {
  544. type: 'value',
  545. axisLabel: {
  546. formatter: `{value}%`,
  547. },
  548. splitLine: { show: false },
  549. },
  550. ],
  551. series: [
  552. {
  553. name: '评卷员主观分布',
  554. type: 'line',
  555. itemStyle: {
  556. color: '#8ED14B',
  557. },
  558. data: getXAxisData('rate', subjectiveByMarker?.value?.segmentsByUser),
  559. },
  560. {
  561. name: '小组主观分布',
  562. type: 'line',
  563. itemStyle: {
  564. color: '#3B99D4',
  565. },
  566. data: getXAxisData('rate', subjectiveByMarker?.value?.segmentsByGroup),
  567. },
  568. {
  569. name: '题组主观分布',
  570. type: 'line',
  571. itemStyle: {
  572. color: '#ff0000',
  573. },
  574. data: getXAxisData('rate', subjectiveByMarker?.value?.segmentsByAll),
  575. },
  576. ],
  577. }
  578. })
  579. const markerObjectiveChartsOption = computed<EChartsOption>(() => {
  580. return {
  581. grid: {
  582. top: 50,
  583. bottom: 15,
  584. left: 30,
  585. right: 30,
  586. containLabel: true,
  587. },
  588. legend: {
  589. top: 10,
  590. itemWidth: 14,
  591. data: ['评卷员客观分布', '小组客观分布', '题组客观分布'],
  592. },
  593. tooltip: {
  594. trigger: 'axis',
  595. triggerOn: 'click',
  596. enterable: true,
  597. axisPointer: {
  598. type: 'line',
  599. crossStyle: {
  600. color: '#999',
  601. },
  602. lineStyle: {
  603. type: 'dashed',
  604. },
  605. },
  606. // formatter: function (params: any) {
  607. // let html = `
  608. // <div>
  609. // <div style="font-size:14px;color:#0091ff;font-weight:bold;text-decoration:underline;cursor:pointer;margin-bottom:8px">${params[0].axisValue}分段</div>
  610. // <div>
  611. // `
  612. // for (let i = 0; i < params.length; i++) {
  613. // let item = params[i]
  614. // html += `
  615. // <div style="margin: 0px 0 0">
  616. // ${item.marker}
  617. // <span style="font-size:14px;color:#666;font-weight:400;margin-left:2px">${item.seriesName}</span>
  618. // <span style="float:right;margin-left:20px;font-size:14px;color:#666;font-weight:900">${item.data}</span>
  619. // <div style="clear:both"></div>
  620. // </div>
  621. // </div>
  622. // `
  623. // }
  624. // html += `
  625. // </div>
  626. // </div>
  627. // `
  628. // return html
  629. // },
  630. },
  631. xAxis: {
  632. axisLine: { show: false },
  633. axisTick: { show: false },
  634. splitLine: { show: false },
  635. axisLabel: {
  636. align: 'right',
  637. },
  638. data: getXAxisData('scoreStart', objectiveByMarker?.value?.segmentsByAll),
  639. },
  640. yAxis: [
  641. {
  642. type: 'value',
  643. },
  644. {
  645. type: 'value',
  646. axisLabel: {
  647. formatter: `{value}%`,
  648. },
  649. splitLine: { show: false },
  650. },
  651. ],
  652. series: [
  653. {
  654. name: '评卷员客观分布',
  655. type: 'line',
  656. itemStyle: {
  657. color: '#8ED14B',
  658. },
  659. data: getXAxisData('rate', objectiveByMarker?.value?.segmentsByUser),
  660. },
  661. {
  662. name: '小组客观分布',
  663. type: 'line',
  664. itemStyle: {
  665. color: '#3B99D4',
  666. },
  667. data: getXAxisData('rate', objectiveByMarker?.value?.segmentsByGroup),
  668. },
  669. {
  670. name: '题组客观分布',
  671. type: 'line',
  672. itemStyle: {
  673. color: '#ff0000',
  674. },
  675. data: getXAxisData('rate', objectiveByMarker?.value?.segmentsByAll),
  676. },
  677. ],
  678. }
  679. })
  680. onSearch()
  681. const multToggle = () => {
  682. isMult.value = !isMult.value
  683. editScoreVisible.value = !isMult.value
  684. if (!isMult.value && tableData.value?.length && current.value) {
  685. nextTick(() => {
  686. let index = tableData.value.findIndex((task: any) => task.taskId == current.value?.taskId)
  687. elTableRef?.value?.setCurrentRow(tableData.value[index == -1 ? 0 : index])
  688. })
  689. }
  690. if (isMult.value) {
  691. elTableRef?.value?.clearSelection()
  692. }
  693. }
  694. const rejectIds = computed(() => {
  695. return isMult.value ? multipleSelection.value.map((item: any) => item.taskId) : [current.value?.taskId]
  696. })
  697. </script>
  698. <style scoped lang="scss">
  699. .header-view {
  700. background-color: #333;
  701. height: 60px;
  702. ::v-deep(.data-item) {
  703. // padding-left: 20px;
  704. padding-left: 15px;
  705. padding-right: 15px;
  706. position: relative;
  707. height: 100%;
  708. display: flex;
  709. align-items: center;
  710. color: #8a8a8a;
  711. .icon-item {
  712. // width: 45px;
  713. padding: 0 10px;
  714. height: 100%;
  715. display: flex;
  716. flex-direction: column;
  717. justify-content: flex-end;
  718. }
  719. &:first-child {
  720. margin-left: auto;
  721. }
  722. &:not(:last-child) {
  723. &:after {
  724. content: '';
  725. position: absolute;
  726. right: 0;
  727. top: 0;
  728. width: 1px;
  729. height: 100%;
  730. background-color: #464646;
  731. }
  732. }
  733. &.is-last:after {
  734. width: 0;
  735. }
  736. .main-ques-info {
  737. text-align: center;
  738. font-weight: bold;
  739. color: $color--primary;
  740. margin-bottom: 5px;
  741. max-width: 130px;
  742. }
  743. }
  744. }
  745. .chart-space {
  746. height: 220px;
  747. }
  748. .filter-header {
  749. border-top: 1px solid #eee;
  750. border-bottom: 1px solid #eee;
  751. padding: 8px 15px;
  752. .m-name {
  753. font-size: 12px;
  754. color: #666;
  755. margin-right: 40px;
  756. font-weight: bold;
  757. }
  758. :deep(.el-form-item--small) {
  759. margin-bottom: 0;
  760. }
  761. }
  762. .new-chart-box {
  763. height: 100%;
  764. width: calc(50% - 6px);
  765. background-color: #fff;
  766. }
  767. .mark-container {
  768. .mark-content {
  769. position: relative;
  770. .preview {
  771. position: absolute;
  772. cursor: pointer;
  773. top: 20px;
  774. right: 25px;
  775. font-size: 38px;
  776. }
  777. .next-button {
  778. position: absolute;
  779. right: -20px;
  780. top: 300px;
  781. }
  782. .mark-content-paper {
  783. img {
  784. max-width: 100%;
  785. }
  786. }
  787. }
  788. .table-view {
  789. // width: 580px;
  790. .detail-info-table-header {
  791. .choose-score-info {
  792. background: rgba(0, 186, 151, 0.1);
  793. display: flex;
  794. align-items: center;
  795. height: 32px;
  796. padding: 0 10px;
  797. border-radius: 4px;
  798. .txt {
  799. color: #00ba97;
  800. font-weight: bold;
  801. font-size: 12px;
  802. margin-right: 12px;
  803. }
  804. .close {
  805. color: #00ba97;
  806. font-weight: bold;
  807. cursor: pointer;
  808. font-size: 16px;
  809. margin-bottom: 2px;
  810. }
  811. }
  812. }
  813. .marker-name {
  814. border-bottom: $OnePixelLine;
  815. }
  816. .detail-info-label {
  817. .detail-info-label-num {
  818. min-width: 32px;
  819. height: 24px;
  820. line-height: 24px;
  821. background: #00987b;
  822. border-radius: 4px;
  823. }
  824. }
  825. }
  826. }
  827. </style>