| | |
| | | append-to-body |
| | | :visible.sync="dialogBatchFormVisible" |
| | | width="1000px" |
| | | @close='closeDialog' |
| | | @close="closeDialog" |
| | | > |
| | | <avue-form |
| | | ref="formBatchApply" |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | import { addApply, cancelApplyNotApplyId, remove } from "@/api/examapi/applyexam"; |
| | | import { getListApply,addBatchApply } from "@/api/securityGuard/securityGuard"; |
| | | import { |
| | | addApply, |
| | | cancelApplyNotApplyId, |
| | | remove, |
| | | } from "@/api/examapi/applyexam"; |
| | | import { getListApply, addBatchApply } from "@/api/securityGuard/securityGuard"; |
| | | import { mapState } from "vuex"; |
| | | |
| | | var DIC = { |
| | |
| | | tip: false, |
| | | searchShow: true, |
| | | searchMenuSpan: 6, |
| | | border: false, |
| | | border: true, //liu |
| | | index: true, |
| | | stripe: true, |
| | | viewBtn: false, |
| | |
| | | tip: false, |
| | | searchShow: true, |
| | | searchMenuSpan: 6, |
| | | border: false, |
| | | border: true, //liu |
| | | index: true, |
| | | stripe: true, |
| | | viewBtn: true, |
| | |
| | | value: "id", |
| | | }, |
| | | //不包含父节点值 |
| | | leafOnly:true, |
| | | leafOnly: true, |
| | | multiple: true, |
| | | searchSpan: 5, |
| | | rules: [ |
| | |
| | | // } |
| | | |
| | | this.optionBatchApply.column[0].dicUrl = |
| | | "/api/blade-user/security-apply-tree?deptId=" + |
| | | this.userInfo.dept_id; |
| | | "/api/blade-user/security-apply-tree?deptId=" + this.userInfo.dept_id; |
| | | }, |
| | | mounted() { |
| | | |
| | | }, |
| | | mounted() {}, |
| | | computed: { |
| | | ...mapState({ |
| | | userInfo: (state) => state.user.userInfo, |
| | |
| | | }) |
| | | .then(() => { |
| | | row.applyStatus = 4; |
| | | row['userId'] = row.id; |
| | | row["userId"] = row.id; |
| | | return cancelApplyNotApplyId(row); |
| | | }) |
| | | .then(() => { |
| | |
| | | handleBatchApply() { |
| | | // this.dialogBatchFormVisible = true; |
| | | if (this.questionBankSelectionList.length === 0) { |
| | | this.$confirm("确定全部人员报名?", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning", |
| | | }).then(() => { |
| | | var userIds = ""; |
| | | addBatchApply(userIds,this.userInfo.dept_id).then( |
| | | (res) => { |
| | | this.questionBankOnLoad(this.questionBankPage); |
| | | if (res.data.data == 201) { |
| | | this.$message({ |
| | | type: "warning", |
| | | message: "已报名,不能重复报名", |
| | | }); |
| | | } else if (res.data.data == 201) { |
| | | this.$message({ |
| | | type: "warning", |
| | | message: "报名失败", |
| | | }); |
| | | } else { |
| | | this.$message({ |
| | | type: "success", |
| | | message: "报名成功", |
| | | }); |
| | | this.$refs.formBatchApply.resetFields(); |
| | | this.dialogBatchFormVisible = false; |
| | | } |
| | | }, |
| | | (error) => { |
| | | window.console.log(error); |
| | | this.$confirm("确定全部人员报名?", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning", |
| | | }).then(() => { |
| | | var userIds = ""; |
| | | addBatchApply(userIds, this.userInfo.dept_id).then( |
| | | (res) => { |
| | | this.questionBankOnLoad(this.questionBankPage); |
| | | if (res.data.data == 201) { |
| | | this.$message({ |
| | | type: "warning", |
| | | message: "已报名,不能重复报名", |
| | | }); |
| | | } else if (res.data.data == 201) { |
| | | this.$message({ |
| | | type: "warning", |
| | | message: "报名失败", |
| | | }); |
| | | } else { |
| | | this.$message({ |
| | | type: "success", |
| | | message: "报名成功", |
| | | }); |
| | | this.$refs.formBatchApply.resetFields(); |
| | | this.dialogBatchFormVisible = false; |
| | | } |
| | | ); |
| | | }) |
| | | }else{ |
| | | }, |
| | | (error) => { |
| | | window.console.log(error); |
| | | } |
| | | ); |
| | | }); |
| | | } else { |
| | | this.$confirm("确定选择人员报名?", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning", |
| | | }).then(() => { |
| | | addBatchApply(this.ids,this.userInfo.dept_id).then( |
| | | (res) => { |
| | | this.questionBankOnLoad(this.questionBankPage); |
| | | if (res.data.data == 201) { |
| | | this.$message({ |
| | | type: "warning", |
| | | message: "已报名,不能重复报名", |
| | | }); |
| | | } else if (res.data.data == 201) { |
| | | this.$message({ |
| | | type: "warning", |
| | | message: "报名失败", |
| | | }); |
| | | } else { |
| | | this.$message({ |
| | | type: "success", |
| | | message: "报名成功", |
| | | }); |
| | | this.$refs.formBatchApply.resetFields(); |
| | | this.dialogBatchFormVisible = false; |
| | | } |
| | | }, |
| | | (error) => { |
| | | window.console.log(error); |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning", |
| | | }).then(() => { |
| | | addBatchApply(this.ids, this.userInfo.dept_id).then( |
| | | (res) => { |
| | | this.questionBankOnLoad(this.questionBankPage); |
| | | if (res.data.data == 201) { |
| | | this.$message({ |
| | | type: "warning", |
| | | message: "已报名,不能重复报名", |
| | | }); |
| | | } else if (res.data.data == 201) { |
| | | this.$message({ |
| | | type: "warning", |
| | | message: "报名失败", |
| | | }); |
| | | } else { |
| | | this.$message({ |
| | | type: "success", |
| | | message: "报名成功", |
| | | }); |
| | | this.$refs.formBatchApply.resetFields(); |
| | | this.dialogBatchFormVisible = false; |
| | | } |
| | | ); |
| | | }) |
| | | }, |
| | | (error) => { |
| | | window.console.log(error); |
| | | } |
| | | ); |
| | | }); |
| | | } |
| | | }, |
| | | |
| | |
| | | // }, |
| | | |
| | | //关闭窗口清除数据 |
| | | closeDialog(){ |
| | | this.$refs.formBatchApply.resetFields(); |
| | | closeDialog() { |
| | | this.$refs.formBatchApply.resetFields(); |
| | | }, |
| | | |
| | | questionBankHandleDelete() { |