Browse Source

科目代码相关公共组件2

zhangjie 1 year ago
parent
commit
f31499c15e
25 changed files with 73 additions and 77 deletions
  1. 2 2
      src/modules/analysis/components/baseConfig/DimensionAbilityList.vue
  2. 1 1
      src/modules/analysis/components/baseConfig/DimensionKnowledgeList.vue
  3. 6 6
      src/modules/base/api.js
  4. 1 1
      src/modules/base/components/course-simple/ModifyTargetEvaluation.vue
  5. 2 2
      src/modules/card/api.js
  6. 1 1
      src/modules/course/components/profession/AddProfessionalCourse.vue
  7. 2 2
      src/modules/course/components/profession/ProfessionalMatrix.vue
  8. 1 1
      src/modules/course/components/score/EndScoreManage.vue
  9. 1 1
      src/modules/course/components/score/NormalScoreManage.vue
  10. 4 4
      src/modules/exam/api.js
  11. 10 10
      src/modules/exam/components/ApplyContent.vue
  12. 1 1
      src/modules/exam/components/CreatePrintTask.vue
  13. 1 1
      src/modules/exam/components/ModifyTaskApply.vue
  14. 8 8
      src/modules/exam/components/ModifyTaskPaper.vue
  15. 2 2
      src/modules/exam/components/PublishPrintTask.vue
  16. 2 2
      src/modules/exam/components/createExamAndPrintTask/CreateExamAndPrintTask.vue
  17. 11 11
      src/modules/exam/components/createExamAndPrintTask/InfoExamTask.vue
  18. 6 6
      src/modules/exam/components/createExamAndPrintTask/InfoPrintTask.vue
  19. 5 9
      src/modules/exam/components/createExamAndPrintTask/ModifyExamTaskStudent.vue
  20. 1 1
      src/modules/exam/components/createExamAndPrintTask/SelectTikuPaperDialog.vue
  21. 1 1
      src/modules/mark/components/ModifyMarkSetting.vue
  22. 1 1
      src/modules/mark/components/markDetail/MarkDetailMarker.vue
  23. 1 1
      src/modules/mark/components/markDetail/MarkDetailProgress.vue
  24. 1 1
      src/modules/stmms/components/SelectTransferUser.vue
  25. 1 1
      src/modules/stmms/components/markParam/MarkParamStructure.vue

+ 2 - 2
src/modules/analysis/components/baseConfig/DimensionAbilityList.vue

@@ -142,7 +142,7 @@ export default {
 
       const res = await downloadByApi(() => {
         return paperDimensionExport({
-          courseCode: this.baseInfo.courseCode,
+          courseId: this.baseInfo.courseId,
           courseName: this.baseInfo.courseName,
           dimensionType: "ABILITY",
         });
@@ -176,7 +176,7 @@ export default {
     },
     toAdd() {
       this.curRow = {
-        courseCode: this.baseInfo.courseCode,
+        courseId: this.baseInfo.courseId,
         courseName: this.baseInfo.courseName,
       };
       this.$refs.ModifyAbilityDim.open();

+ 1 - 1
src/modules/analysis/components/baseConfig/DimensionKnowledgeList.vue

@@ -147,7 +147,7 @@ export default {
 
       const res = await downloadByApi(() => {
         return paperDimensionExport({
-          courseCode: this.baseInfo.courseCode,
+          courseId: this.baseInfo.courseId,
           courseName: this.baseInfo.courseName,
           dimensionType: "KNOWLEDGE",
         });

+ 6 - 6
src/modules/base/api.js

@@ -1,7 +1,7 @@
 import { $postParam, $post } from "@/plugins/axios";
 
-export const questionTeatherUserQuery = ({ courseCode, param }) => {
-  return $postParam("/api/admin/sys/user/user_list", { courseCode, param });
+export const questionTeatherUserQuery = ({ courseId, param }) => {
+  return $postParam("/api/admin/sys/user/user_list", { courseId, param });
 };
 export const unitQueryByType = (datas, dictionaryEnum) => {
   // dictionaryEnum: SEMESTER("学期"),COLLEGE("学院"),MAJOR("专业"),CLAZZ("班级"),STUDENT("学生"),COURSE("课程")
@@ -45,22 +45,22 @@ export const conditionListCourse = ({ semesterId, examId, printPlanId }) => {
 export const conditionListPaperNumber = ({
   semesterId,
   examId,
-  courseCode,
+  courseId,
   printPlanId,
 }) => {
   return $postParam("/api/admin/basic/condition/list_paper_number", {
     semesterId,
     examId,
-    courseCode,
+    courseId,
     printPlanId,
   });
 };
 // clazz
-export const conditionListClazz = ({ semesterId, examId, courseCode }) => {
+export const conditionListClazz = ({ semesterId, examId, courseId }) => {
   return $postParam("/api/admin/basic/condition/list_clazz", {
     semesterId,
     examId,
-    courseCode,
+    courseId,
   });
 };
 

+ 1 - 1
src/modules/base/components/course-simple/ModifyTargetEvaluation.vue

@@ -34,7 +34,7 @@
         label="评价方式"
         min-width="120"
       ></el-table-column>
-      <el-table-column prop="courseCode" label="权重" width="130">
+      <el-table-column label="权重" width="130">
         <template slot-scope="scope">
           <el-input-number
             v-model="scope.row.weight"

+ 2 - 2
src/modules/card/api.js

@@ -14,6 +14,6 @@ export const saveCard = (datas, config = {}) => {
     return $post("/api/admin/exam/card/save", datas, config);
   }
 };
-export const copyCard = (cardId, courseCode) => {
-  return $postParam("/api/admin/exam/card/copy", { id: cardId, courseCode });
+export const copyCard = (cardId, courseId) => {
+  return $postParam("/api/admin/exam/card/copy", { id: cardId, courseId });
 };

+ 1 - 1
src/modules/course/components/profession/AddProfessionalCourse.vue

@@ -132,7 +132,7 @@ export default {
         professionalId: this.rowData.id,
         courses: this.multipleSelection.map((item) => {
           return {
-            courseCode: item.courseCode,
+            courseId: item.courseId,
             courseName: item.courseName,
           };
         }),

+ 2 - 2
src/modules/course/components/profession/ProfessionalMatrix.vue

@@ -136,7 +136,7 @@ export default {
         if (!index) this.parseColumns(item.requirements);
 
         const nitem = {
-          courseCode: item.courseCode,
+          courseId: item.courseId,
           courseName: item.courseName,
           canEdit: item.canEdit,
         };
@@ -200,7 +200,7 @@ export default {
         this.$message.error(`${columnName}列总和大于1,当前修改值将不会保存!`);
 
         const rowIndex = this.dataList.findIndex(
-          (item) => item.courseCode === row.courseCode
+          (item) => item.courseId === row.courseId
         );
 
         this.updateErrorIndexs([rowIndex, columnIndex]);

+ 1 - 1
src/modules/course/components/score/EndScoreManage.vue

@@ -146,7 +146,7 @@ export default {
     return {
       filter: {
         examId: "",
-        courseCode: "",
+        courseId: "",
         teachCourseId: "",
       },
       current: 1,

+ 1 - 1
src/modules/course/components/score/NormalScoreManage.vue

@@ -104,7 +104,7 @@ export default {
     return {
       filter: {
         examId: "",
-        courseCode: "",
+        courseId: "",
         teachCourseId: "",
       },
       current: 1,

+ 4 - 4
src/modules/exam/api.js

@@ -131,10 +131,10 @@ export const deleteTaskApply = (id) => {
 export const taskAllFlowSetups = (flowId) => {
   return $postParam("/api/admin/flow/task/all", { flowId });
 };
-export const taskAllApproverPeople = ({ taskId, courseCode }) => {
+export const taskAllApproverPeople = ({ taskId, courseId }) => {
   return $postParam("/api/admin/flow/task/approver/people_all", {
     taskId,
-    courseCode,
+    courseId,
   });
 };
 
@@ -144,10 +144,10 @@ export const taskAllApproverExchangePeople = ({ taskId, realName }) => {
     realName,
   });
 };
-export const taskApproverNextPeople = ({ taskId, courseCode }) => {
+export const taskApproverNextPeople = ({ taskId, courseId }) => {
   return $postParam("/api/admin/flow/task/approver/next/people", {
     taskId,
-    courseCode,
+    courseId,
   });
 };
 // 命题老师创建命题任务

+ 10 - 10
src/modules/exam/components/ApplyContent.vue

@@ -692,7 +692,7 @@ const initTaskApply = {
   cardRuleId: "",
   makeMethod: "",
   remark: "",
-  courseCode: "",
+  courseId: "",
   courseName: "",
   drawCount: 1,
   exposedPaperType: "",
@@ -861,7 +861,7 @@ export default {
     },
     canCreateCard() {
       return (
-        this.curTaskApply.courseCode &&
+        this.curTaskApply.courseId &&
         this.curTaskApply.examId &&
         this.curTaskApply.cardRuleId !== COMMON_CARD_RULE_ID
       );
@@ -894,7 +894,7 @@ export default {
       this.curTaskApply.examId =
         this.curTaskApply.examId || this.examTask.examId;
       this.curTaskApply.examTaskId = this.examTask.id;
-      this.curTaskApply.courseCode = this.examTask.courseCode;
+      this.curTaskApply.courseId = this.examTask.courseId;
       this.curTaskApply.courseName = this.examTask.courseName;
       this.curTaskApply.cardRuleId = this.examTask.cardRuleId;
       this.curTaskApply.customCard = this.examTask.customCard;
@@ -979,9 +979,9 @@ export default {
       this.curTab = tab;
     },
     async getCardList() {
-      if (!this.curTaskApply.courseCode || !this.curTaskApply.examId) return;
+      if (!this.curTaskApply.courseId || !this.curTaskApply.examId) return;
       const data = await cardForSelectList({
-        courseCode: this.curTaskApply.courseCode,
+        courseId: this.curTaskApply.courseId,
         examId: this.curTaskApply.examId,
         paperNumber: this.curTaskApply.paperNumber,
       });
@@ -1163,7 +1163,7 @@ export default {
       this.curAttachment = { ...attachment };
       const newCardId = await copyCard(
         attachment.cardId,
-        this.curTaskApply.courseCode
+        this.curTaskApply.courseId
       );
       this.cardModified({ id: newCardId });
     },
@@ -1172,7 +1172,7 @@ export default {
       this.$ls.set("prepareTcPCard", {
         id: attachment.cardId,
         examTaskId: this.curTaskApply.examTaskId,
-        courseCode: this.curTaskApply.courseCode,
+        courseId: this.curTaskApply.courseId,
         courseName: this.curTaskApply.courseName,
         makeMethod: this.curTaskApply.makeMethod,
         cardRuleId: this.curTaskApply.cardRuleId,
@@ -1250,7 +1250,7 @@ export default {
       this.curAttachment = { ...attachment };
       // 这里只允许新建标准专卡
       this.$ls.set("prepareTcPCard", {
-        courseCode: this.examTask.courseCode,
+        courseId: this.examTask.courseId,
         courseName: this.examTask.courseName,
         schoolName: this.$ls.get("schoolName"),
         makeMethod: "SELF",
@@ -1364,14 +1364,14 @@ export default {
     toSelect(attachment) {
       this.curAttachment = {
         ...attachment,
-        courseCode: this.examTask.courseCode,
+        courseId: this.examTask.courseId,
       };
       this.$refs.SelectTikuPaperDialog.open();
     },
     async tikuPaperSelected(data) {
       this.cardBuildPresetData = {
         examId: this.examTask.examId,
-        courseCode: this.examTask.courseCode,
+        courseId: this.examTask.courseId,
         courseName: this.examTask.courseName,
         schoolName: this.$ls.get("schoolName"),
         makeMethod: "SELF",

+ 1 - 1
src/modules/exam/components/CreatePrintTask.vue

@@ -229,7 +229,7 @@ export default {
       this.classList = [];
       const data = await listTaskPrintClass({
         printPlanId: this.instance.printPlanId,
-        courseCode: this.instance.courseCode,
+        courseId: this.instance.courseId,
         paperNumber: this.instance.paperNumber,
         examTaskPrintId: this.instance.id,
       });

+ 1 - 1
src/modules/exam/components/ModifyTaskApply.vue

@@ -137,7 +137,7 @@ const initModalForm = {
   category: "",
   semesterId: "",
   semesterName: "",
-  courseCode: "",
+  courseId: "",
   courseName: "",
   specialty: "",
   paperNumber: "",

+ 8 - 8
src/modules/exam/components/ModifyTaskPaper.vue

@@ -292,7 +292,7 @@ const initTaskApply = {
   cardId: "",
   cardRuleId: "",
   makeMethod: "",
-  courseCode: "",
+  courseId: "",
   courseName: "",
   drawCount: 1,
   exposedPaperType: "",
@@ -343,7 +343,7 @@ export default {
     },
     canCreateCard() {
       return (
-        this.curTaskApply.courseCode &&
+        this.curTaskApply.courseId &&
         this.curTaskApply.examId &&
         this.curTaskApply.cardRuleId !== COMMON_CARD_RULE_ID
       );
@@ -370,9 +370,9 @@ export default {
   },
   methods: {
     async getCardList() {
-      if (!this.curTaskApply.courseCode || !this.curTaskApply.examId) return;
+      if (!this.curTaskApply.courseId || !this.curTaskApply.examId) return;
       const data = await cardForSelectList({
-        courseCode: this.curTaskApply.courseCode,
+        courseId: this.curTaskApply.courseId,
         examId: this.curTaskApply.examId,
         paperNumber: this.instance.paperNumber,
       });
@@ -384,7 +384,7 @@ export default {
     async visibleChange() {
       const data = await taskApplyDetail(this.instance.id);
       this.curTaskApply = this.$objAssign(initTaskApply, data || {});
-      this.curTaskApply.courseCode = this.instance.courseCode;
+      this.curTaskApply.courseId = this.instance.courseId;
       this.curTaskApply.courseName = this.instance.courseName;
       this.curTaskApply.cardRuleId = this.instance.cardRuleId;
       this.curTaskApply.includePaper =
@@ -483,7 +483,7 @@ export default {
       this.curAttachment = { ...attachment };
       const newCardId = await copyCard(
         attachment.cardId,
-        this.curTaskApply.courseCode
+        this.curTaskApply.courseId
       );
       this.cardModified({ id: newCardId });
     },
@@ -492,7 +492,7 @@ export default {
       this.$ls.set("prepareTcPCard", {
         id: attachment.cardId,
         examTaskId: this.curTaskApply.examTaskId,
-        courseCode: this.curTaskApply.courseCode,
+        courseId: this.curTaskApply.courseId,
         courseName: this.curTaskApply.courseName,
         makeMethod: this.curTaskApply.makeMethod,
         cardRuleId: this.curTaskApply.cardRuleId,
@@ -538,7 +538,7 @@ export default {
       this.curAttachment = { ...attachment };
       // 这里只允许新建标准专卡
       this.$ls.set("prepareTcPCard", {
-        courseCode: this.curTaskApply.courseCode,
+        courseId: this.curTaskApply.courseId,
         courseName: this.curTaskApply.courseName,
         schoolName: this.$ls.get("schoolName"),
         makeMethod: "SELF",

+ 2 - 2
src/modules/exam/components/PublishPrintTask.vue

@@ -161,7 +161,7 @@ export default {
         examEndTime: "",
         paperNumber: "",
         courseName: "",
-        courseCode: "",
+        courseId: "",
       },
       loading: false,
       curPlanSubmit: false,
@@ -204,7 +204,7 @@ export default {
     async getList() {
       const datas = {
         printPlanId: this.filter.printPlanId,
-        courseCode: this.instance.courseCode,
+        courseId: this.instance.courseId,
         paperNumber: this.instance.paperNumber,
         pageNumber: this.current,
         pageSize: this.size,

+ 2 - 2
src/modules/exam/components/createExamAndPrintTask/CreateExamAndPrintTask.vue

@@ -107,7 +107,7 @@ const initExamTask = {
   examId: "",
   examModel: "",
   category: "",
-  courseCode: "",
+  courseId: "",
   courseName: "",
   paperNumber: "",
   cardRuleId: "",
@@ -170,7 +170,7 @@ const initPrintTask = {
   examEndTime: "",
   paperNumber: "",
   courseName: "",
-  courseCode: "",
+  courseId: "",
   printCount: 1, // MODEL2专用
   printHouseId: "", // MODEL2专用
   classId: "", // MODEL2专用

+ 11 - 11
src/modules/exam/components/createExamAndPrintTask/InfoExamTask.vue

@@ -37,9 +37,9 @@
             </el-form-item>
           </el-col>
           <el-col :span="12">
-            <el-form-item prop="courseCode" label="课程(代码):">
+            <el-form-item prop="courseId" label="课程(代码):">
               <el-select
-                v-model="examTask.courseCode"
+                v-model="examTask.courseId"
                 placeholder="请选择"
                 filterable
                 class="width-full"
@@ -435,7 +435,7 @@ export default {
             trigger: "change",
           },
         ],
-        courseCode: [
+        courseId: [
           {
             required: true,
             message: "请选择课程",
@@ -492,7 +492,7 @@ export default {
     },
     canCreateCard() {
       return (
-        this.examTask.courseCode &&
+        this.examTask.courseId &&
         this.examTask.examId &&
         this.examTask.cardRuleId !== COMMON_CARD_RULE_ID
       );
@@ -562,9 +562,9 @@ export default {
       this.curTab = tab;
     },
     async getCardList() {
-      if (!this.examTask.courseCode || !this.examTask.examId) return;
+      if (!this.examTask.courseId || !this.examTask.examId) return;
       const data = await cardForSelectList({
-        courseCode: this.examTask.courseCode,
+        courseId: this.examTask.courseId,
         examId: this.examTask.examId,
       });
       this.cards = data || [];
@@ -669,7 +669,7 @@ export default {
       if (!res || res.action !== "confirm") return;
       this.curAttachment = { ...attachment };
       this.$ls.set("prepareTcPCard", {
-        courseCode: this.examTask.courseCode,
+        courseId: this.examTask.courseId,
         courseName: this.examTask.courseName,
         schoolName: this.$ls.get("schoolName"),
         makeMethod: "SELF",
@@ -685,7 +685,7 @@ export default {
       // 这里只允许新建标准专卡
       this.$ls.set("prepareTcPCard", {
         id: attachment.cardId,
-        courseCode: this.examTask.courseCode,
+        courseId: this.examTask.courseId,
         courseName: this.examTask.courseName,
         schoolName: this.$ls.get("schoolName"),
         makeMethod: "SELF",
@@ -710,7 +710,7 @@ export default {
       this.curAttachment = { ...attachment };
       const newCardId = await copyCard(
         attachment.cardId,
-        this.examTask.courseCode
+        this.examTask.courseId
       );
       this.cardModified({ id: newCardId });
     },
@@ -813,7 +813,7 @@ export default {
     toSelect(attachment) {
       this.curAttachment = {
         ...attachment,
-        courseCode: this.examTask.courseCode,
+        courseId: this.examTask.courseId,
       };
       this.$refs.SelectTikuPaperDialog.open();
       // this.tikuPaperSelected({ id: "1", name: "paper-name" });
@@ -821,7 +821,7 @@ export default {
     async tikuPaperSelected(data) {
       this.cardBuildPresetData = {
         examId: this.examTask.examId,
-        courseCode: this.examTask.courseCode,
+        courseId: this.examTask.courseId,
         courseName: this.examTask.courseName,
         schoolName: this.$ls.get("schoolName"),
         makeMethod: "SELF",

+ 6 - 6
src/modules/exam/components/createExamAndPrintTask/InfoPrintTask.vue

@@ -258,7 +258,7 @@
       ref="ModifyExamTaskStudent"
       :disabled-ids="disabledStudentIds"
       :filter-params="{
-        courseCode: infoExamTask.courseCode,
+        courseId: infoExamTask.courseId,
         examId: infoExamTask.examId,
         teachingRoomId: infoExamTask.teachingRoomId,
       }"
@@ -291,7 +291,7 @@ const initModalForm = {
   examEndTime: "",
   paperNumber: "",
   courseName: "",
-  courseCode: "",
+  courseId: "",
   totalSubjects: 1,
   printHouseId: "",
   backupCount: null,
@@ -354,7 +354,7 @@ export default {
     "infoExamTask.examId": function (val, oldval) {
       if (val !== oldval) this.initData();
     },
-    "infoExamTask.courseCode": function (val, oldval) {
+    "infoExamTask.courseId": function (val, oldval) {
       if (val !== oldval) this.initData();
     },
     "infoExamPrintPlan.backupCount": function (val, oldval) {
@@ -378,7 +378,7 @@ export default {
         {
           paperNumber: this.infoExamTask.paperNumber,
           courseName: this.infoExamTask.courseName,
-          courseCode: this.infoExamTask.courseCode,
+          courseId: this.infoExamTask.courseId,
         }
       );
 
@@ -555,7 +555,7 @@ export default {
       }
     },
     toAdd() {
-      if (!this.infoExamTask.courseCode) {
+      if (!this.infoExamTask.courseId) {
         this.$message.error("请先选择课程");
         return;
       }
@@ -714,7 +714,7 @@ export default {
     },
     // model2 select class
     toSelectClass() {
-      if (!this.infoExamTask.courseCode) {
+      if (!this.infoExamTask.courseId) {
         this.$message.error("请先选择课程");
         return;
       }

+ 5 - 9
src/modules/exam/components/createExamAndPrintTask/ModifyExamTaskStudent.vue

@@ -13,15 +13,11 @@
     <div class="user-search">
       <el-form inline>
         <el-form-item>
-          <el-select
-            v-model="filter.courseCode"
-            placeholder="请选择"
-            filterable
-          >
+          <el-select v-model="filter.courseId" placeholder="请选择" filterable>
             <el-option
               v-for="item in courses"
-              :key="item.code"
-              :value="item.code"
+              :key="item.id"
+              :value="item.id"
               :label="`${item.name}(${item.code})`"
             >
             </el-option>
@@ -125,7 +121,7 @@ export default {
       type: Object,
       default() {
         return {
-          courseCode: "",
+          courseId: "",
           examId: "",
           teachingRoomId: "",
         };
@@ -140,7 +136,7 @@ export default {
     return {
       modalIsShow: false,
       filter: {
-        courseCode: "",
+        courseId: "",
         examId: "",
         teacher: "",
         className: "",

+ 1 - 1
src/modules/exam/components/createExamAndPrintTask/SelectTikuPaperDialog.vue

@@ -125,7 +125,7 @@ export default {
     },
     async getList() {
       const datas = {
-        courseCode: this.row.courseCode,
+        courseId: this.row.courseId,
         ...this.filter,
         pageNumber: this.current,
         pageSize: this.size,

+ 1 - 1
src/modules/mark/components/ModifyMarkSetting.vue

@@ -194,7 +194,7 @@ export default {
       this.paperList = [];
       const data = await examStructureFindJpg({
         examId: this.instance.examId,
-        courseCode: this.instance.courseCode,
+        courseId: this.instance.courseId,
         paperNumber: this.instance.paperNumber,
         paperType: this.instance.paperType,
       });

+ 1 - 1
src/modules/mark/components/markDetail/MarkDetailMarker.vue

@@ -153,7 +153,7 @@
     <!-- ModifyMarkerBind -->
     <modify-marker-bind
       ref="ModifyMarkerBind"
-      :courseCode="baseInfo.courseCode"
+      :course-id="baseInfo.courseId"
       :data="curData"
       @modified="markerSelected"
     ></modify-marker-bind>

+ 1 - 1
src/modules/mark/components/markDetail/MarkDetailProgress.vue

@@ -280,7 +280,7 @@ export default {
       const res = await downloadByApi(() => {
         return markProgressMarkerExport({
           examId: this.baseInfo.examId,
-          courseCode: this.baseInfo.courseCode,
+          courseId: this.baseInfo.courseId,
           paperNumber: this.baseInfo.paperNumber,
         });
       }).catch((e) => {

+ 1 - 1
src/modules/stmms/components/SelectTransferUser.vue

@@ -96,7 +96,7 @@ export default {
 
       const res = await examTransferUser({
         transferId: this.modalForm.transferId,
-        courseCode: this.task.courseCode,
+        courseId: this.task.courseId,
         paperNumber: this.task.paperNumber,
         examId: this.task.examId,
       }).catch(() => {});

+ 1 - 1
src/modules/stmms/components/markParam/MarkParamStructure.vue

@@ -130,7 +130,7 @@ export default {
           thirdRelateId: null,
           thirdRelateName: "",
           courseName: "",
-          courseCode: "",
+          courseId: "",
           paperNumber: null,
           paperType: "",
           sequence: null,