|
@@ -0,0 +1,184 @@
|
|
|
|
+<template>
|
|
|
|
+ <div>
|
|
|
|
+ <div class="part-box part-box-filter">
|
|
|
|
+ <el-form ref="FilterForm" label-position="left" label-width="90px" inline>
|
|
|
|
+ <template v-if="checkPrivilege('condition', 'condition')">
|
|
|
|
+ <secp-select
|
|
|
|
+ v-model="filterSe"
|
|
|
|
+ defaultSelectExam
|
|
|
|
+ @exam-default="search"
|
|
|
|
+ ></secp-select>
|
|
|
|
+ <el-form-item label="题卡类型:" label-width="90px">
|
|
|
|
+ <el-select
|
|
|
|
+ v-model="filter.cardType"
|
|
|
|
+ style="width: 120px"
|
|
|
|
+ placeholder="题卡类型"
|
|
|
|
+ clearable
|
|
|
|
+ >
|
|
|
|
+ <el-option
|
|
|
|
+ v-for="(val, key) in CARD_TYPE"
|
|
|
|
+ :key="key"
|
|
|
|
+ :value="key"
|
|
|
|
+ :label="val"
|
|
|
|
+ ></el-option>
|
|
|
|
+ </el-select>
|
|
|
|
+ </el-form-item>
|
|
|
|
+ <el-form-item label="状态:">
|
|
|
|
+ <el-select
|
|
|
|
+ v-model="filter.status"
|
|
|
|
+ placeholder="状态"
|
|
|
|
+ clearable
|
|
|
|
+ style="width: 120px"
|
|
|
|
+ >
|
|
|
|
+ <el-option
|
|
|
|
+ v-for="(val, key) in DATA_TASK_STATUS"
|
|
|
|
+ :key="key"
|
|
|
|
+ :value="key"
|
|
|
|
+ :label="val"
|
|
|
|
+ ></el-option>
|
|
|
|
+ </el-select>
|
|
|
|
+ </el-form-item>
|
|
|
|
+ </template>
|
|
|
|
+ <el-form-item>
|
|
|
|
+ <el-button
|
|
|
|
+ v-if="checkPrivilege('button', 'select')"
|
|
|
|
+ type="primary"
|
|
|
|
+ @click="toPage(1)"
|
|
|
|
+ >查询</el-button
|
|
|
|
+ >
|
|
|
|
+ </el-form-item>
|
|
|
|
+ </el-form>
|
|
|
|
+ <div class="box-justify">
|
|
|
|
+ <div></div>
|
|
|
|
+ <div>
|
|
|
|
+ <el-button
|
|
|
|
+ v-if="checkPrivilege('button', 'export')"
|
|
|
|
+ type="primary"
|
|
|
|
+ icon="el-icon-download"
|
|
|
|
+ :loading="loading"
|
|
|
|
+ @click="toExport"
|
|
|
|
+ >导出印刷进度</el-button
|
|
|
|
+ >
|
|
|
|
+ </div>
|
|
|
|
+ </div>
|
|
|
|
+ </div>
|
|
|
|
+
|
|
|
|
+ <div class="part-box part-box-pad">
|
|
|
|
+ <el-table ref="TableList" :data="dataList">
|
|
|
|
+ <el-table-column
|
|
|
|
+ type="index"
|
|
|
|
+ label="序号"
|
|
|
|
+ width="70"
|
|
|
|
+ :index="indexMethod"
|
|
|
|
+ ></el-table-column>
|
|
|
|
+ <el-table-column
|
|
|
|
+ prop="printPlanName"
|
|
|
|
+ label="印刷计划"
|
|
|
|
+ min-width="160"
|
|
|
|
+ ></el-table-column>
|
|
|
|
+ <el-table-column label="课程(代码)" min-width="260">
|
|
|
|
+ <template slot-scope="scope">
|
|
|
|
+ {{ scope.row.courseName | defaultFieldFilter }}({{
|
|
|
|
+ scope.row.courseCode | defaultFieldFilter
|
|
|
|
+ }})
|
|
|
|
+ </template>
|
|
|
|
+ </el-table-column>
|
|
|
|
+ <el-table-column prop="paperNumber" label="试卷编号" width="200">
|
|
|
|
+ </el-table-column>
|
|
|
|
+ <el-table-column prop="type" label="题卡类型" width="100">
|
|
|
|
+ <span slot-scope="scope">{{ scope.row.type | cardTypeFilter }}</span>
|
|
|
|
+ </el-table-column>
|
|
|
|
+ <el-table-column prop="openCollege" label="开课学院" min-width="160">
|
|
|
|
+ </el-table-column>
|
|
|
|
+ <el-table-column prop="createMethod" label="总考场数" width="100">
|
|
|
|
+ </el-table-column>
|
|
|
|
+ <el-table-column prop="createMethod" label="已生成/未生成" width="120">
|
|
|
|
+ </el-table-column>
|
|
|
|
+ <el-table-column prop="createMethod" label="已印刷/未印刷" width="120">
|
|
|
|
+ </el-table-column>
|
|
|
|
+ <el-table-column prop="createMethod" label="已打回/已作废" width="120">
|
|
|
|
+ </el-table-column>
|
|
|
|
+ <el-table-column prop="status" label="状态" width="100">
|
|
|
|
+ </el-table-column>
|
|
|
|
+ </el-table>
|
|
|
|
+ <div class="part-page">
|
|
|
|
+ <el-pagination
|
|
|
|
+ background
|
|
|
|
+ layout="total, sizes, prev, pager, next, jumper"
|
|
|
|
+ :pager-count="5"
|
|
|
|
+ :current-page="current"
|
|
|
|
+ :total="total"
|
|
|
|
+ :page-size="size"
|
|
|
|
+ @current-change="toPage"
|
|
|
|
+ @size-change="pageSizeChange"
|
|
|
|
+ >
|
|
|
|
+ </el-pagination>
|
|
|
|
+ </div>
|
|
|
|
+ </div>
|
|
|
|
+ </div>
|
|
|
|
+</template>
|
|
|
|
+
|
|
|
|
+<script>
|
|
|
|
+import { CARD_TYPE, DATA_TASK_STATUS } from "../../../constants/enumerate";
|
|
|
|
+import { printTaskStatListPage, printTaskStatExport } from "../api";
|
|
|
|
+import { downloadByApi } from "@/plugins/download";
|
|
|
|
+
|
|
|
|
+export default {
|
|
|
|
+ name: "print-task-stat",
|
|
|
|
+ data() {
|
|
|
|
+ return {
|
|
|
|
+ filter: {
|
|
|
|
+ semesterId: "",
|
|
|
|
+ examId: "",
|
|
|
|
+ printPlanId: "",
|
|
|
|
+ openCollegeId: "",
|
|
|
|
+ courseId: "",
|
|
|
|
+ paperNumber: "",
|
|
|
|
+ cardType: "",
|
|
|
|
+ status: "",
|
|
|
|
+ },
|
|
|
|
+ dataList: [],
|
|
|
|
+ CARD_TYPE,
|
|
|
|
+ DATA_TASK_STATUS,
|
|
|
|
+ current: 1,
|
|
|
|
+ size: this.GLOBAL.pageSize,
|
|
|
|
+ total: 0,
|
|
|
|
+ loading: false,
|
|
|
|
+ };
|
|
|
|
+ },
|
|
|
|
+ methods: {
|
|
|
|
+ async getList() {
|
|
|
|
+ if (!this.checkPrivilege("list", "list")) return;
|
|
|
|
+
|
|
|
|
+ const datas = {
|
|
|
|
+ ...this.filter,
|
|
|
|
+ pageNumber: this.current,
|
|
|
|
+ pageSize: this.size,
|
|
|
|
+ };
|
|
|
|
+ const data = await printTaskStatListPage(datas);
|
|
|
|
+ this.dataList = data.records;
|
|
|
|
+ this.total = data.total;
|
|
|
|
+ },
|
|
|
|
+ toPage(page) {
|
|
|
|
+ this.current = page;
|
|
|
|
+ this.getList();
|
|
|
|
+ },
|
|
|
|
+ search() {
|
|
|
|
+ this.toPage(1);
|
|
|
|
+ },
|
|
|
|
+ async toExport() {
|
|
|
|
+ if (this.loading) return;
|
|
|
|
+ this.loading = true;
|
|
|
|
+ const res = await downloadByApi(() => {
|
|
|
|
+ return printTaskStatExport(this.filter);
|
|
|
|
+ }, "").catch((e) => {
|
|
|
|
+ this.$message.error(e || "导出失败,请重新尝试!");
|
|
|
|
+ });
|
|
|
|
+ this.loading = false;
|
|
|
|
+
|
|
|
|
+ if (!res) return;
|
|
|
|
+ this.$message.success("导出成功!");
|
|
|
|
+ },
|
|
|
|
+ },
|
|
|
|
+};
|
|
|
|
+</script>
|