xiangpei
2024-06-17 e58abcc99a332a96fa5005aff58fe91c48f354f2
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
<template>
  <div class="app-container">
    <el-row :gutter="20">
      <el-col :span="5">
        <div class="nameClass">
          <div class="bottom5">考试名称</div>
          <div class="title">{{examInfo.examName}}</div>
        </div>
      </el-col>
      <el-col :span="5">
        <div class="nameClass">
          <div class="bottom5">试卷名称</div>
          <div class="title">{{examInfo.examPaperName}}</div>
        </div>
      </el-col>
      <el-col :span="4">
        <div class="staticNum">
          <div class="bottom5">应考人数</div>
          <div class="title">{{examInfo.shouldJoinNum}}</div>
        </div>
      </el-col>
      <el-col :span="4">
        <div class="staticNum">
          <div class="bottom5">缺考人数</div>
          <div class="title">{{examInfo.missJoinNum}}</div>
        </div>
      </el-col>
      <el-col :span="4">
        <div class="staticNum">
          <div class="bottom5">参加但未完成人数</div>
          <div class="title">{{examInfo.joinButNotFinishNum}}</div>
        </div>
      </el-col>
    </el-row>
    <!-- 表格 -->
    <el-table
      :data="examInfo.studentExamInfoVOList"
      border
      style="width: 100%;margin-top: 20px"
    >
      <el-table-column
        align="center"
        prop="id"
        label="学号"
      >
      </el-table-column>
      <el-table-column
        align="center"
        prop="realName"
        label="姓名"
      >
      </el-table-column>
      <el-table-column
        align="center"
        prop="phone"
        label="电话"
      >
      </el-table-column>
      <el-table-column
        align="center"
        prop="phone"
        label="系统自动估分(选择题型)"
      >
      </el-table-column>
      <el-table-column
        label="操作"
        align="center"
        width="300px"
      >
        <template slot-scope="scope">
          <el-button @click="markPaper(scope.row)" type="warning">阅卷</el-button>
        </template>
      </el-table-column>
    </el-table>
  </div>
</template>
 
<script>
import { getExamMarkPaperInfo } from '@/api/exam'
 
export default {
  name: 'MarkPaper',
  mounted () {
    this.examInfo.examName = this.$route.query.examName
    this.examInfo.examId = this.$route.query.examId
    if (this.examInfo.examId) {
      this.getExamInfo()
    }
  },
  data () {
    return {
      examInfo: {
        examName: '',
        examPaperName: '',
        suggestTime: 0,
        shouldJoinNum: 0,
        joinNum: 0,
        missJoinNum: 0,
        joinButNotFinishNum: 0,
        examId: null,
        studentExamInfoVOList: []
      }
    }
  },
  methods: {
    markPaper (row) {
      // todo打开阅卷页面
    },
    getExamInfo () {
      getExamMarkPaperInfo(this.examInfo.examId).then(res => {
        this.examInfo = res.data.data
      })
    }
  }
}
</script>
 
<style scoped>
 
.title {
  font-size: 18px;
}
.bottom5 {
  margin-bottom: 5px;
}
.nameInfo {
  width: 100%;
  display: flex;
  flex-direction: column;
}
.nameClass {
  width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  height: 70px;
  background-color: #cb5858;
}
.staticNum {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background-color: #0a76a4;
  height: 70px;
}
</style>