From 929087ce8c7cec3afe297fdfc55b3f76ec7939d9 Mon Sep 17 00:00:00 2001
From: Administrator <admin>
Date: Fri, 17 Dec 2021 15:57:00 +0800
Subject: [PATCH] 考试成绩新增是否制证查询,已制证的无法再批量申请,可以单个申请补证
---
src/views/trainingRegistration/data.js | 418 +++++++++++++++++++++++-----------------------
src/views/trainExam/performance.vue | 75 +++++++
src/api/accreditationRecords/accreditationRecords.js | 10 +
3 files changed, 289 insertions(+), 214 deletions(-)
diff --git a/src/api/accreditationRecords/accreditationRecords.js b/src/api/accreditationRecords/accreditationRecords.js
index ed125f6..2570db0 100644
--- a/src/api/accreditationRecords/accreditationRecords.js
+++ b/src/api/accreditationRecords/accreditationRecords.js
@@ -33,7 +33,7 @@
})
}
-export const add = (row) => {
+export const submit = (row) => {
return request({
url: '/api/accreditationRecords/submit',
method: 'post',
@@ -41,6 +41,14 @@
})
}
+export const add = (row) => {
+ return request({
+ url: '/api/accreditationRecords/save',
+ method: 'post',
+ data: row
+ })
+}
+
export const update = (row) => {
return request({
url: '/api/accreditationRecords/update',
diff --git a/src/views/trainExam/performance.vue b/src/views/trainExam/performance.vue
index 38c608c..24ad83e 100644
--- a/src/views/trainExam/performance.vue
+++ b/src/views/trainExam/performance.vue
@@ -124,6 +124,14 @@
:type="type"
>申请修改成绩</el-button
>
+ <el-button
+ icon="el-icon-edit"
+ v-if="row.isPaper==6"
+ @click="securityPaperApply(row)"
+ :size="size"
+ :type="type"
+ >补证申请</el-button
+ >
</template>
</avue-crud>
@@ -274,7 +282,7 @@
} from "@/api/examapi/performance";
import { mapGetters } from "vuex";
import { getRoleDetail } from "@/api/system/role";
-import { securityApply } from "@/api/accreditationRecords/accreditationRecords";
+import { securityApply,add} from "@/api/accreditationRecords/accreditationRecords";
import Qs from "qs";
export default {
components: {
@@ -347,7 +355,7 @@
selection: true,
reserveSelection: true,
selectable: (row) => {
- if (row.qualified != "0") {
+ if (row.qualified != "0" || row.isPaper==6) {
return false;
} else {
return true;
@@ -366,7 +374,7 @@
dialogClickModal: false,
// 操作栏宽度
menu: true,
- menuWidth: 295,
+ menuWidth: 330,
labelWidth: 120,
...this.$store.state.control.clearOtherBut,
@@ -488,6 +496,7 @@
prop: "candidateNo",
search: true,
searchSpan: 4,
+ hide:true,
slot: true,
// 表单新增时是否禁止
addDisabled: false,
@@ -515,6 +524,7 @@
prop: "avatar",
type: "upload",
listType: "picture-img",
+ width:60,
},
{
label: "所属公司",
@@ -600,7 +610,7 @@
slot: true,
search: true,
searchSpan: 3,
- width: 60,
+ width: 80,
dicData: [
{
label: "发布成绩",
@@ -772,6 +782,32 @@
editDisplay: true,
// 表单编辑时是否为查看模式
editDetail: false,
+ },
+ {
+ label: "是否制证",
+ prop: "isPaper",
+ type: "select",
+ search: true,
+ width: 70,
+ searchSpan: 3,
+ addDisplay: false,
+ editDisplay: false,
+ // hide: true,
+ display: false,
+ dicData: [
+ {
+ label: "全部",
+ value: 10,
+ },
+ {
+ label: "已制证",
+ value: 6,
+ },
+ {
+ label: "未制证",
+ value: 7,
+ },
+ ],
},
{
label: "有无照片",
@@ -978,6 +1014,9 @@
const data = res.data.data;
data.records.forEach((item) => {
+ if (item.isPaper == null || item.isPaper == -1) {
+ item.isPaper = "";
+ }
if (item.theoryGrade == null && item.learnGrade == -1) {
item.qualified = "";
}
@@ -1000,6 +1039,34 @@
});
});
},
+ //补证申请
+ securityPaperApply(row,done,loading){
+ this.$confirm("当前保安员已制证,确定要继续申请制证?", {
+ confirmButtonText: "确定",
+ cancelButtonText: "取消",
+ type: "warning",
+ }).then(() => {
+ const data = {
+ createUser:this.userInfo.user_id,
+ type:2,
+ userId:row.userId
+ }
+ add(data).then(
+ () => {
+ this.questionBankOnLoad(this.questionBankPage);
+ this.$message({
+ type: "success",
+ message: "操作成功!",
+ });
+ done();
+ },
+ (error) => {
+ window.console.log(error);
+ loading();
+ }
+ );
+ });
+ },
//缺考标记
absent(row, done, loading) {
this.$confirm("确定缺考标记?", {
diff --git a/src/views/trainingRegistration/data.js b/src/views/trainingRegistration/data.js
index 65fd128..15554f3 100644
--- a/src/views/trainingRegistration/data.js
+++ b/src/views/trainingRegistration/data.js
@@ -19,228 +19,228 @@
var w = 160,
s = 12;
export var column = [{
- label: "学校名称",
- prop: "trainingUnitId",
- dicUrl: "/api/blade-system/dept/lazy-tree-type?parentId=1418458374477549569",
- cascaderItem: ["trainExamId"],
- props: {
- label: "title",
- value: "id"
+ label: "学校名称",
+ prop: "trainingUnitId",
+ dicUrl: "/api/blade-system/dept/lazy-tree-type?parentId=1418458374477549569",
+ cascaderItem: ["trainExamId"],
+ props: {
+ label: "title",
+ value: "id"
+ },
+ type: "select",
+ rules: [{
+ required: true,
+ message: "请输入学校名称",
+ trigger: "blur"
+ }],
+ searchSpan: 4,
+ searchLabelWidth: 110,
+ width: 200,
+ }, {
+ label: "姓名",
+ prop: "userId",
+ type: "select",
+ hide: true,
+ dicUrl: "/api/blade-user/page-security-unit?deptId={{key}}",
+ props: {
+ label: "realName",
+ value: "id"
+ },
+ searchSpan: 4,
+ rules: [{
+ required: true,
+ message: "请输入姓名",
+ trigger: "blur"
+ }],
+ }, {
+ label: "姓名",
+ prop: "realName",
+ search: true,
+ searchLabelWidth: 56,
+ editDisplay: false,
+ addDisplay: false,
+ searchSpan: 3,
+ }, {
+ label: "身份证号",
+ prop: "idCardNo",
+ rules: [{
+ required: true,
+ message: "请输入身份证号",
+ trigger: "blur"
+ }],
+ editDisplay: false,
+ addDisplay: false,
+ width: 160
+ }, {
+ label: "准考证号",
+ prop: "candidateNo",
+ rules: [{
+ required: true,
+ message: "请输入准考证号",
+ trigger: "blur"
+ }],
+ editDisplay: false,
+ addDisplay: false,
+ width: 160
},
- type: "select",
- rules: [{
- required: true,
- message: "请输入学校名称",
- trigger: "blur"
- }],
- searchSpan: 4,
- searchLabelWidth: 110,
- width: 200,
-}, {
- label: "姓名",
- prop: "userId",
- type: "select",
- hide: true,
- dicUrl: "/api/blade-user/page-security-unit?deptId={{key}}",
- props: {
- label: "realName",
- value: "id"
- },
- searchSpan: 4,
- rules: [{
- required: true,
- message: "请输入姓名",
- trigger: "blur"
- }],
-}, {
- label: "姓名",
- prop: "realName",
- search: true,
- searchLabelWidth: 56,
- editDisplay: false,
- addDisplay: false,
- searchSpan: 3,
-}, {
- label: "身份证号",
- prop: "idCardNo",
- rules: [{
- required: true,
- message: "请输入身份证号",
- trigger: "blur"
- }],
- editDisplay: false,
- addDisplay: false,
- width: 160
-}, {
- label: "准考证号",
- prop: "candidateNo",
- rules: [{
- required: true,
- message: "请输入准考证号",
- trigger: "blur"
- }],
- editDisplay: false,
- addDisplay: false,
- width: 160
-},
-// {
-// label: "电话",
-// prop: "phone",
-// // hide: true,
-// rules: [{
-// required: true,
-// message: "请输入电话",
-// trigger: "blur"
-// }],
-// editDisplay: false,
-// addDisplay: false,
-// width: 110,
-// },
-{
- label: "企业名称",
- prop: "deptId",
- // width: 70,
- // search: true,
- // searchSpan: 4,
- dicUrl: "/api/blade-system/dept/security_lazy-tree?parentId=1413470343230877697",
- cascaderItem: ["userId"],
- props: {
- label: "title",
- value: "id"
- },
- // search: true,
- type: "select",
- hide: true,
- rules: [{
- required: true,
- message: "请输入企业名称",
- trigger: "blur"
- }],
- overHidden: true
-}, {
- label: "企业名称",
- prop: "deptName",
- // hide: true,
- search: true,
- searchLabelWidth: 85,
- searchSpan: 5,
- rules: [{
- required: true,
- message: "请输入企业名称",
- trigger: "blur"
- }],
+ // {
+ // label: "电话",
+ // prop: "phone",
+ // // hide: true,
+ // rules: [{
+ // required: true,
+ // message: "请输入电话",
+ // trigger: "blur"
+ // }],
+ // editDisplay: false,
+ // addDisplay: false,
+ // width: 110,
+ // },
+ {
+ label: "企业名称",
+ prop: "deptId",
+ // width: 70,
+ // search: true,
+ // searchSpan: 4,
+ dicUrl: "/api/blade-system/dept/security_lazy-tree?parentId=1413470343230877697",
+ cascaderItem: ["userId"],
+ props: {
+ label: "title",
+ value: "id"
+ },
+ // search: true,
+ type: "select",
+ hide: true,
+ rules: [{
+ required: true,
+ message: "请输入企业名称",
+ trigger: "blur"
+ }],
+ overHidden: true
+ }, {
+ label: "企业名称",
+ prop: "deptName",
+ // hide: true,
+ search: true,
+ searchLabelWidth: 85,
+ searchSpan: 5,
+ rules: [{
+ required: true,
+ message: "请输入企业名称",
+ trigger: "blur"
+ }],
-},
-{
- label: "考试名称",
- prop: "trainExamName",
- width: 220,
-},
-{
- label: "考试证件",
- prop: "applyCard"
-},
-{
- label: "审核状态",
- search: true,
- searchLabelWidth: 110,
- type: "select",
- searchSpan: 4, searchLabelWidth: 85,
- prop: "auditStatus",
- searchValue: 4,
- dicData: [{
- label: '全部',
- value: 0,
},
{
- label: '审核通过',
- value: 1,
+ label: "考试名称",
+ prop: "trainExamName",
+ width: 220,
},
{
- label: '审核不通过',
- value: 2,
+ label: "考试证件",
+ prop: "applyCard"
},
{
- label: '已提交审核',
- value: 3,
+ label: "审核状态",
+ search: true,
+ type: "select",
+ searchSpan: 4,
+ prop: "auditStatus",
+ searchValue: 4,
+ dicData: [{
+ label: '全部',
+ value: 0,
+ },
+ {
+ label: '审核通过',
+ value: 1,
+ },
+ {
+ label: '审核不通过',
+ value: 2,
+ },
+ {
+ label: '已提交审核',
+ value: 3,
+ },
+ {
+ label: '未提交审核',
+ value: 4,
+ }
+ ],
+ props: {
+ label: "label",
+ value: "value"
+ },
+ editDisplay: false,
+ addDisplay: false,
+ width: 100,
},
{
- label: '未提交审核',
- value: 4,
- }
- ],
- props: {
- label: "label",
- value: "value"
- },
- editDisplay: false,
- addDisplay: false,
- width: 100,
-},
-{
- label: "报名状态",
- search: true,
- type: "select",
- searchSpan: 4,
- prop: "cancel",
- searchValue: 1, searchLabelWidth: 85,
- dicData: [{
- label: '全部',
- value: 0,
+ label: "报名状态",
+ search: true,
+ type: "select",
+ searchSpan: 4,
+ prop: "cancel",
+ searchValue: 1,
+ searchLabelWidth: 85,
+ dicData: [{
+ label: '全部',
+ value: 0,
+ },
+ {
+ label: '已报名',
+ value: 1,
+ },
+ {
+ label: '已取消',
+ value: 2,
+ }
+ ],
+ props: {
+ label: "label",
+ value: "value"
+ },
+ editDisplay: false,
+ addDisplay: false,
+ width: 100,
},
{
- label: '已报名',
- value: 1,
+ label: "考试状态",
+ search: true,
+ type: "select",
+ searchSpan: 4,
+ prop: "isExam",
+ searchValue: 1,
+ dicData: [{
+ label: '全部',
+ value: 0,
+ },
+ {
+ label: '未考试',
+ value: 1,
+ },
+ {
+ label: '考试结束',
+ value: 2,
+ },
+ {
+ label: '考试中',
+ value: 3,
+ },
+ {
+ label: '缺考',
+ value: 4,
+ }
+ ],
+ props: {
+ label: "label",
+ value: "value"
+ },
+ editDisplay: false,
+ addDisplay: false,
+ width: 100,
},
- {
- label: '已取消',
- value: 2,
- }
- ],
- props: {
- label: "label",
- value: "value"
- },
- editDisplay: false,
- addDisplay: false,
- width: 100,
-},
-{
- label: "考试状态",
- search: true,
- type: "select",
- searchSpan: 4,
- prop: "isExam",
- searchValue: 1,
- dicData: [{
- label: '全部',
- value: 0,
- },
- {
- label: '未考试',
- value: 1,
- },
- {
- label: '考试结束',
- value: 2,
- },
- {
- label: '考试中',
- value: 3,
- },
- {
- label: '缺考',
- value: 4,
- }
- ],
- props: {
- label: "label",
- value: "value"
- },
- editDisplay: false,
- addDisplay: false,
- width: 100,
-},
// {
// label: "确认截止时间",
// prop: "remainingTime",
--
Gitblit v1.9.3