Przeglądaj źródła

feat: 题卡调试

zhangjie 3 miesięcy temu
rodzic
commit
b8681e5ab3

+ 2 - 0
src/components/SecpSelect.vue

@@ -15,6 +15,7 @@
         :semester-id="filter.semesterId"
         :clearable="!defaultSelectExam"
         :default-select="defaultSelectExam"
+        :exam-model="examModel"
         @change="examChange"
         @default-selected="examDefaultSelect"
       ></exam-select>
@@ -95,6 +96,7 @@ export default {
     },
     defaultSelectSemester: { type: Boolean, default: false },
     defaultSelectExam: { type: Boolean, default: false },
+    examModel: { type: String, default: "" },
   },
   data() {
     return {

+ 2 - 1
src/components/base/ExamSelect.vue

@@ -31,6 +31,7 @@ export default {
     semesterId: { type: String, default: "" },
     enable: { type: Boolean, default: null },
     category: { type: String, default: "" },
+    examModel: { type: String, default: "" },
     defaultSelect: { type: Boolean, default: false },
   },
   data() {
@@ -79,7 +80,7 @@ export default {
       let data = {
         semesterId: this.semesterId,
         category: this.category || undefined,
-        examModel: this.examModel || undefined,
+        model: this.examModel || undefined,
       };
       if (this.enable !== null) data.enable = this.enable;
       const res = await conditionListExam(data);

+ 34 - 2
src/modules/base/api.js

@@ -20,7 +20,7 @@ export const conditionListSemester = (datas, config) => {
 };
 // exam
 export const conditionListExam = (
-  { semesterId, category, enable, examModel },
+  { semesterId, category, enable, model },
   config = {}
 ) => {
   return $postParam(
@@ -29,7 +29,7 @@ export const conditionListExam = (
       semesterId,
       category,
       enable,
-      examModel,
+      model,
     },
     config
   );
@@ -274,6 +274,38 @@ export const downloadCardFile = (id) => {
 export const ableCard = ({ id, enable }) => {
   return $postParam("/api/admin/exam/card/enable", { id, enable });
 };
+// mode-card-manage
+export const modeCardListPage = (datas) => {
+  return $postParam("/api/admin/exam/model_4/card/page", datas);
+};
+export const updateModeCard = (datas) => {
+  return $post("/api/admin/exam/model_4/card/save_generic", datas);
+};
+export const deleteModeCard = (id) => {
+  return $postParam("/api/admin/exam/model_4/card/delete_generic", { id });
+};
+export const convertModeCardImage = (id) => {
+  return $postParam("/api/admin/exam/model_4/card/convert_image", { id });
+};
+export const downloadModeCardFile = (id) => {
+  return $postParam(
+    "/api/admin/exam/model_4/card/download_card",
+    { id },
+    {
+      responseType: "blob",
+    }
+  );
+};
+export const downloadBatchModeCardFile = (ids) => {
+  return $postParam(
+    "/api/admin/exam/model_4/card/batch_download_card",
+    { ids },
+    {
+      responseType: "blob",
+    }
+  );
+};
+
 // course-manage
 export const courseListPage = (datas) => {
   return $postParam("/api/admin/basic/course/list", datas);

+ 8 - 8
src/modules/base/components/ModifyExamConfigDetail.vue

@@ -127,15 +127,15 @@
             </p>
           </div>
         </el-form-item>
-        <el-form-item label="默认抽取卷型:" prop="defaultDrawPaperType">
-          <el-radio-group v-model="modalForm.defaultDrawPaperType">
+        <el-form-item label="默认抽取卷型:" prop="defaultSerialNumber">
+          <el-radio-group v-model="modalForm.defaultSerialNumber">
             <el-radio :label="0">随机</el-radio>
             <el-radio :label="1">卷1/A卷</el-radio>
             <el-radio :label="2">卷2/B卷</el-radio>
           </el-radio-group>
         </el-form-item>
-        <el-form-item label="交卷数量:" prop="submitTwoPaper">
-          <el-checkbox v-model="modalForm.submitTwoPaper">
+        <el-form-item label="交卷数量:" prop="twoPaperEnable">
+          <el-checkbox v-model="modalForm.twoPaperEnable">
             一个命题任务至少交AB两套试卷
           </el-checkbox>
         </el-form-item>
@@ -305,8 +305,8 @@ const initModalForm = {
   backupMethod: "ROOM",
   backupCount: 1,
   drawRule: "ONE",
-  defaultDrawPaperType: 1,
-  submitTwoPaper: false,
+  defaultSerialNumber: 0,
+  twoPaperEnable: false,
   outputFileType: [],
   variableContent: [
     {
@@ -440,14 +440,14 @@ export default {
             trigger: "change",
           },
         ],
-        defaultDrawPaperType: [
+        defaultSerialNumber: [
           {
             required: true,
             message: "请选择默认抽取卷型",
             trigger: "change",
           },
         ],
-        submitTwoPaper: [
+        twoPaperEnable: [
           {
             required: true,
             message: "请选择交卷数量",

+ 21 - 12
src/modules/base/components/ModifyModeCardInfo.vue

@@ -15,14 +15,14 @@
       :rules="rules"
       :model="modalForm"
     >
-      <el-form-item label="学期:">
+      <el-form-item label="学期:" prop="semesterId">
         <semester-select
           v-model.trim="modalForm.semesterId"
           placeholder="学期"
           :disabled="isEdit"
         ></semester-select>
       </el-form-item>
-      <el-form-item label="考试:">
+      <el-form-item label="考试:" prop="examId">
         <exam-select
           v-model="modalForm.examId"
           :semester-id="modalForm.semesterId"
@@ -31,7 +31,7 @@
           @change="examChange"
         ></exam-select>
       </el-form-item>
-      <el-form-item label="课程(代码):">
+      <el-form-item label="课程(代码):" prop="courseId">
         <course-select
           v-model.trim="modalForm.courseId"
           :semester-id="modalForm.semesterId"
@@ -41,6 +41,14 @@
           @change="courseChange"
         ></course-select>
       </el-form-item>
+      <el-form-item prop="cardRuleId" label="题卡规则:">
+        <card-rule-select
+          ref="CardRuleSelect"
+          v-model.trim="modalForm.cardRuleId"
+          placeholder="请选择"
+          clearable
+        ></card-rule-select>
+      </el-form-item>
       <el-form-item prop="title" label="题卡名称:">
         <el-input
           v-model.trim="modalForm.title"
@@ -72,14 +80,14 @@
 </template>
 
 <script>
-import { updateCard } from "../api";
-import { examConfigByExamIdOrgId } from "@/modules/base/api";
+import { updateModeCard } from "../api";
 
 const initModalForm = {
   id: null,
   semesterId: "",
   examId: "",
   courseId: "",
+  cardRuleId: "",
   title: "",
   remark: "",
   courseName: "",
@@ -135,6 +143,13 @@ export default {
             trigger: "change",
           },
         ],
+        cardRuleId: [
+          {
+            required: true,
+            message: "请选择题卡规则",
+            trigger: "change",
+          },
+        ],
         title: [
           {
             required: true,
@@ -175,14 +190,8 @@ export default {
       if (!valid) return;
 
       if (!this.isEdit) {
-        const examPrintPlan = await examConfigByExamIdOrgId({
-          examId: this.modalForm.examId,
-          orgId: this.curExam.orgId,
-        });
-
         const datas = {
           ...this.modalForm,
-          cardRuleId: examPrintPlan.cardRuleId,
           schoolName: this.$ls.get("schoolName"),
         };
         this.$emit("new-card", datas);
@@ -195,7 +204,7 @@ export default {
       let datas = {
         ...this.modalForm,
       };
-      const data = await updateCard(datas).catch(() => {});
+      const data = await updateModeCard(datas).catch(() => {});
       this.isSubmit = false;
       if (!data) return;
 

+ 6 - 0
src/modules/base/router.js

@@ -11,6 +11,7 @@ import FlowManage from "./views/FlowManage.vue";
 import ApproveRecordManage from "./views/ApproveRecordManage.vue";
 import SmsManage from "./views/SmsManage.vue";
 import CardManage from "./views/CardManage.vue";
+import ModeCardManage from "./views/ModeCardManage.vue";
 // dict
 import StudentManage from "./views/StudentManage.vue";
 import CourseManage from "./views/CourseManage.vue";
@@ -135,6 +136,11 @@ export default [
     name: "CardManage",
     component: CardManage,
   },
+  {
+    path: "/base/mode-card-manage",
+    name: "ModeCardManage",
+    component: ModeCardManage,
+  },
   {
     path: "/base/exam-student-manage",
     name: "BasicExamStudentManage",

+ 0 - 20
src/modules/base/views/CardManage.vue

@@ -73,13 +73,6 @@
           @click="toAdd"
           >新增</el-button
         >
-        <el-button
-          v-if="checkPrivilege('button', 'add')"
-          type="primary"
-          icon="el-icon-circle-plus-outline"
-          @click="toAddModeCard"
-          >新增题卡</el-button
-        >
       </div>
     </div>
     <div class="part-box part-box-pad">
@@ -231,13 +224,6 @@
       @new-card="toNewCard"
       @modified="getList"
     ></modify-card-info>
-    <!-- ModifyModeCardInfo -->
-    <modify-mode-card-info
-      ref="ModifyModeCardInfo"
-      :instance="curCard"
-      @new-card="toNewCard"
-      @modified="getList"
-    ></modify-mode-card-info>
     <!-- ModifyCard -->
     <modify-card ref="ModifyCard" @modified="getList"></modify-card>
     <!-- image-preview -->
@@ -274,14 +260,12 @@ import ModifyCard from "../../card/components/ModifyCard";
 import SimpleImagePreview from "@/components/SimpleImagePreview";
 import CardPreviewDialog from "../../card/components/CardPreviewDialog.vue";
 import { downloadByApi } from "@/plugins/download";
-import ModifyModeCardInfo from "../components/ModifyModeCardInfo";
 
 export default {
   name: "card-manage",
   components: {
     ModifyCardInfo,
     ModifyCard,
-    ModifyModeCardInfo,
     SimpleImagePreview,
     CardPreviewDialog,
   },
@@ -342,10 +326,6 @@ export default {
       this.curCard = {};
       this.$refs.ModifyCardInfo.open();
     },
-    toAddModeCard() {
-      this.curCard = {};
-      this.$refs.ModifyModeCardInfo.open();
-    },
     toPreview(row) {
       this.curCard = row;
       this.$refs.CardPreviewDialog.open();

+ 2 - 1
src/modules/base/views/ExamManage.vue

@@ -105,7 +105,8 @@
             >
             <el-button
               v-if="
-                checkPrivilege('link', 'Set') && scope.row.examModel != 'MODEL4'
+                checkPrivilege('link', 'Set') &&
+                scope.row.examModel !== 'MODEL4'
               "
               class="btn-primary"
               type="text"

+ 372 - 0
src/modules/base/views/ModeCardManage.vue

@@ -0,0 +1,372 @@
+<template>
+  <div class="card-manage">
+    <div class="part-box part-box-filter part-box-flex">
+      <el-form ref="FilterForm" label-position="left" label-width="85px" inline>
+        <template v-if="checkPrivilege('condition', 'condition')">
+          <secp-select
+            v-model="filter"
+            exam-model="MODEL4"
+            defaultSelectExam
+            @exam-default="search"
+          ></secp-select>
+        </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="part-box-action">
+        <el-button
+          v-if="checkPrivilege('button', 'add')"
+          type="primary"
+          icon="el-icon-circle-plus-outline"
+          @click="toAdd"
+          >新增题卡</el-button
+        >
+        <el-button
+          v-if="checkPrivilege('button', 'batchDownload')"
+          type="primary"
+          icon="el-icon-download"
+          @click="toBatchDownload"
+          >批量下载</el-button
+        >
+      </div>
+    </div>
+    <div class="part-box part-box-pad">
+      <el-table
+        ref="TableList"
+        :data="cardList"
+        @selection-change="handleSelectionChange"
+      >
+        <el-table-column
+          type="selection"
+          fixed="left"
+          width="55"
+          align="center"
+        ></el-table-column>
+        <el-table-column
+          type="index"
+          label="序号"
+          width="70"
+          :index="indexMethod"
+        ></el-table-column>
+        <el-table-column
+          prop="title"
+          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="type" label="类型" width="100">
+          <span slot-scope="scope">{{ scope.row.type | cardTypeFilter }}</span>
+        </el-table-column>
+        <el-table-column prop="status" label="状态" width="100">
+          <span
+            :class="{ 'color-danger': scope.row.status !== 'SUBMIT' }"
+            slot-scope="scope"
+            >{{ scope.row.status === "SUBMIT" ? "提交" : "暂存" }}</span
+          >
+        </el-table-column>
+        <el-table-column
+          class-name="action-column"
+          label="操作"
+          width="230"
+          fixed="right"
+        >
+          <template slot-scope="scope">
+            <el-button
+              v-if="checkPrivilege('link', 'preview')"
+              class="btn-primary"
+              type="text"
+              @click="toPreview(scope.row)"
+              >查看</el-button
+            >
+            <el-button
+              v-if="
+                checkPrivilege('link', 'ConvertImage') && !scope.row.imageUrls
+              "
+              class="btn-primary"
+              type="text"
+              @click="toConvertImage(scope.row)"
+              >生成图片</el-button
+            >
+            <el-button
+              v-if="
+                checkPrivilege('link', 'ConvertImage') && scope.row.imageUrls
+              "
+              class="btn-primary"
+              type="text"
+              @click="toPreviewImage(scope.row)"
+              >预览图片</el-button
+            >
+            <el-button
+              v-if="
+                checkPrivilege('link', 'edit') &&
+                scope.row.createMethod !== 'UPLOAD'
+              "
+              class="btn-primary"
+              type="text"
+              @click="toEditCard(scope.row)"
+              >编辑题卡</el-button
+            >
+            <el-button
+              v-if="
+                checkPrivilege('link', 'edit') &&
+                scope.row.type !== 'CUSTOM' &&
+                !scope.row.used
+              "
+              class="btn-primary"
+              type="text"
+              @click="toEditInfo(scope.row)"
+              >编辑信息</el-button
+            >
+            <el-button
+              v-if="checkPrivilege('link', 'Download')"
+              class="btn-primary"
+              type="text"
+              @click="toDownload(scope.row)"
+              >下载题卡</el-button
+            >
+            <el-button
+              v-if="checkPrivilege('link', 'delete')"
+              class="btn-danger"
+              type="text"
+              @click="toDelete(scope.row)"
+              >删除</el-button
+            >
+          </template>
+        </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>
+
+    <!-- ModifyModeCardInfo -->
+    <modify-mode-card-info
+      ref="ModifyModeCardInfo"
+      :instance="curCard"
+      @new-card="toNewCard"
+      @modified="getList"
+    ></modify-mode-card-info>
+    <!-- ModifyCard -->
+    <modify-card ref="ModifyCard" @modified="getList"></modify-card>
+    <!-- image-preview -->
+    <simple-image-preview
+      :cur-image="curImage"
+      @on-prev="toPrevImage"
+      @on-next="toNextImage"
+      ref="SimpleImagePreview"
+    ></simple-image-preview>
+    <!-- card-preview-dialog -->
+    <card-preview-dialog
+      ref="CardPreviewDialog"
+      :card-id="curCard.id"
+      is-model-four
+      show-watermark
+    ></card-preview-dialog>
+  </div>
+</template>
+
+<script>
+import {
+  modeCardListPage,
+  deleteModeCard,
+  convertModeCardImage,
+  downloadModeCardFile,
+  downloadBatchModeCardFile,
+} from "../api";
+import ModifyCard from "../../card/components/ModifyCard.vue";
+import SimpleImagePreview from "@/components/SimpleImagePreview.vue";
+import CardPreviewDialog from "../../card/components/CardPreviewDialog.vue";
+import { downloadByApi } from "@/plugins/download";
+import ModifyModeCardInfo from "../components/ModifyModeCardInfo.vue";
+
+export default {
+  name: "card-manage",
+  components: {
+    ModifyCard,
+    ModifyModeCardInfo,
+    SimpleImagePreview,
+    CardPreviewDialog,
+  },
+  data() {
+    return {
+      filter: {
+        semesterId: "",
+        examId: "",
+        openCollegeId: "",
+        courseId: "",
+        paperNumber: "",
+      },
+      current: 1,
+      size: this.GLOBAL.pageSize,
+      total: 0,
+      cardList: [],
+      curCard: {},
+      multipleSelection: [],
+      // image-preview
+      imageList: [],
+      curImage: {},
+      curImageIndex: 0,
+    };
+  },
+  methods: {
+    async getList() {
+      if (!this.checkPrivilege("list", "list")) return;
+
+      const datas = {
+        ...this.filter,
+        pageNumber: this.current,
+        pageSize: this.size,
+      };
+      if (this.createTime) {
+        datas.createStartTime = this.createTime[0];
+        datas.createEndTime = this.createTime[1];
+      }
+      const data = await modeCardListPage(datas);
+      this.cardList = data.records;
+      this.total = data.total;
+    },
+    toPage(page) {
+      this.current = page;
+      this.getList();
+    },
+    search() {
+      this.toPage(1);
+    },
+    handleSelectionChange(val) {
+      this.multipleSelection = val.map((item) => item.id);
+    },
+    toAdd() {
+      this.curCard = {};
+      this.$refs.ModifyModeCardInfo.open();
+    },
+    toPreview(row) {
+      this.curCard = row;
+      this.$refs.CardPreviewDialog.open();
+    },
+    toNewCard(data) {
+      this.$ls.set("prepareTcPCard", {
+        ...data,
+        cardName: data.title,
+        isModel4: true,
+      });
+      this.$refs.ModifyCard.open();
+    },
+    toEditCard(row) {
+      this.curCard = row;
+      this.$ls.set("prepareTcPCard", {
+        id: row.id,
+        title: row.title,
+        cardName: row.title,
+        type: row.type,
+        createMethod: row.createMethod,
+        makeMethod: row.makeMethod,
+        remark: row.remark,
+        courseCode: row.courseCode,
+        courseName: row.courseName,
+        cardRuleId: row.cardRuleId,
+        semesterId: row.semesterId,
+        examId: row.examId,
+        courseId: row.courseId,
+        isModel4: true,
+      });
+      this.$refs.ModifyCard.open();
+    },
+    toEditInfo(row) {
+      this.curCard = row;
+      this.$refs.ModifyModeCardInfo.open();
+    },
+    toDelete(row) {
+      this.$confirm(`确定要删除题卡【${row.title}】吗?`, "提示", {
+        type: "warning",
+      })
+        .then(async () => {
+          await deleteModeCard(row.id);
+          this.$message.success("删除成功!");
+          this.deletePageLastItem();
+        })
+        .catch(() => {});
+    },
+    async toConvertImage(row) {
+      await convertModeCardImage(row.id);
+      this.$message.success("操作成功!");
+    },
+    async toDownload(row) {
+      const res = await downloadByApi(() => {
+        return downloadModeCardFile(row.id);
+      }, "").catch((e) => {
+        this.$message.error(e || "下载失败,请重新尝试!");
+      });
+
+      if (!res) return;
+      this.$message.success("下载成功!");
+    },
+    async toBatchDownload() {
+      if (!this.multipleSelection.length) {
+        this.$message.warning("请选择要下载的题卡!");
+        return;
+      }
+      const res = await downloadByApi(() => {
+        return downloadBatchModeCardFile(this.multipleSelection.join(","));
+      }, "").catch((e) => {
+        this.$message.error(e || "下载失败,请重新尝试!");
+      });
+
+      if (!res) return;
+      this.$message.success("下载成功!");
+    },
+    // image-preview
+    toPreviewImage(row) {
+      this.imageList = row.imageUrls;
+      this.curImageIndex = 0;
+      this.selectImage(0);
+      this.$refs.SimpleImagePreview.open();
+    },
+    selectImage(index) {
+      this.curImage = {
+        url: this.imageList[index],
+        filename: Math.floor(index / 2) + 1 + "-" + ((index % 2) + 1),
+      };
+    },
+    toPrevImage() {
+      if (this.curImageIndex === 0) {
+        this.curImageIndex = this.imageList.length - 1;
+      } else {
+        this.curImageIndex--;
+      }
+
+      this.selectImage(this.curImageIndex);
+    },
+    toNextImage() {
+      if (this.curImageIndex === this.imageList.length - 1) {
+        this.curImageIndex = 0;
+      } else {
+        this.curImageIndex++;
+      }
+
+      this.selectImage(this.curImageIndex);
+    },
+  },
+};
+</script>

+ 8 - 9
src/modules/card/api.js

@@ -5,16 +5,11 @@ import { isNull } from "@/plugins/utils";
 export const cardConfigInfos = (id) => {
   return $postParam("/api/admin/basic/card_rule/get_one", { id });
 };
-export const cardDetail = (cardId) => {
-  return $postParam("/api/admin/exam/card/get_one", { cardId });
-};
-
-export const saveCard1 = (datas, config = {}) => {
-  if (datas.type === "GENERIC") {
-    return $post("/api/admin/exam/card/save_generic", datas, config);
-  } else {
-    return $post("/api/admin/exam/card/save", datas, config);
+export const cardDetail = (cardId, isModel4 = false) => {
+  if (isModel4) {
+    return $postParam("/api/admin/exam/model_4/card/get_one", { id: cardId });
   }
+  return $postParam("/api/admin/exam/card/get_one", { cardId });
 };
 
 export const saveCard = async (datas, config = {}) => {
@@ -36,6 +31,10 @@ export const saveCard = async (datas, config = {}) => {
     }
   }
 
+  if (datas.isModel4) {
+    return $post("/api/admin/exam/model_4/card/save_generic", formData, config);
+  }
+
   if (datas.type === "GENERIC") {
     return $post("/api/admin/exam/card/save_generic", formData, config);
   } else {

+ 5 - 0
src/modules/card/components/CardPreviewDialog.vue

@@ -21,6 +21,7 @@
       :card-data="cardData"
       :view-type="viewType"
       :card-id="cardId"
+      :is-model-four="isModelFour"
       @confirm="confirm"
     ></card-preview>
   </el-dialog>
@@ -49,6 +50,10 @@ export default {
       type: Boolean,
       default: false,
     },
+    isModelFour: {
+      type: Boolean,
+      default: false,
+    },
   },
   data() {
     return {

+ 4 - 1
src/modules/card/views/CardEdit.vue

@@ -133,7 +133,10 @@ export default {
       return titleRule;
     },
     async getCardTempDetail() {
-      const detData = await cardDetail(this.cardId);
+      const detData = await cardDetail(
+        this.cardId,
+        this.prepareTcPCard.isModel4
+      );
       // 可能存在题卡内容没有记录的情况
       if (detData.content || detData.stageContent) {
         const content = detData.stageContent || detData.content;

+ 5 - 1
src/modules/card/views/CardPreview.vue

@@ -39,6 +39,10 @@ export default {
       type: String,
       default: null,
     },
+    isModelFour: {
+      type: Boolean,
+      default: false,
+    },
   },
   data() {
     return {
@@ -129,7 +133,7 @@ export default {
         this.$message.error("题卡id丢失!");
         return;
       }
-      const detData = await cardDetail(cardId);
+      const detData = await cardDetail(cardId, this.isModelFour);
       this.cardCreateMethod = detData.createMethod;
       this.cardType = detData.type;
 

+ 0 - 3
src/modules/exam/api.js

@@ -298,6 +298,3 @@ export const savePreviewLog = (datas) => {
 export const pdfBuildListPage = (datas) => {
   return $postParam("/api/admin/data/task/page_pdf_create", datas);
 };
-export const stopPrintTaskPdf = (id) => {
-  return $postParam("/api/admin/data/task/stop_pdf_create", { id });
-};

+ 1 - 23
src/modules/exam/views/PdfBuildManage.vue

@@ -162,17 +162,6 @@
               @click="toResetCreatePdf(scope.row)"
               >重新生成</el-button
             >
-            <el-button
-              v-if="
-                checkPrivilege('link', 'createPdf') &&
-                scope.row.status === 'RUNNING'
-              "
-              class="btn-danger"
-              type="text"
-              :disabled="loading"
-              @click="toStopCreatePdf(scope.row)"
-              >中止</el-button
-            >
           </template>
         </el-table-column>
       </el-table>
@@ -236,7 +225,7 @@
 
 <script>
 import { DATA_TASK_STATUS, DATA_TASK_RESULT } from "@/constants/enumerate";
-import { pdfBuildListPage, stopPrintTaskPdf } from "../api";
+import { pdfBuildListPage } from "../api";
 import pickerOptions from "@/constants/datePickerOptions";
 import { getPrintTaskPdf, rebuildPrintTaskPdf } from "@/modules/print/api";
 
@@ -348,17 +337,6 @@ export default {
         this.padViewDialogVisible = true;
       }
     },
-    async toStopCreatePdf(row) {
-      const action = await this.$confirm(`确定要中止该印刷任务吗?`, "提示", {
-        type: "warning",
-      }).catch(() => {});
-      if (action !== "confirm") return;
-
-      const res = await stopPrintTaskPdf(row.id).catch(() => {});
-      if (!res) return;
-      this.$message.success("操作成功!");
-      this.getList();
-    },
     async rebuildPdf(item) {
       const action = await this.$confirm(
         `确定要重新生成该印刷任务PDF吗?`,