| | |
| | | >删 除 |
| | | </el-button> |
| | | <el-button |
| | | style="display:none" |
| | | type="warning" |
| | | size="small" |
| | | plain |
| | | icon="el-icon-download" |
| | | v-if="permission.accreditationRecords_export" |
| | | v-if="permission.accreditationRecords_paper_export" |
| | | @click="handleExport" |
| | | >保安员证信息导出 |
| | | >制证信息导出 |
| | | </el-button> |
| | | <el-button |
| | | type="primary" |
| | |
| | | import { mapGetters } from "vuex"; |
| | | import { mapState } from "vuex"; |
| | | import Qs from "qs"; |
| | | import website from "@/config/website"; |
| | | import { getToken } from "@/util/auth"; |
| | | export default { |
| | | data() { |
| | | return { |
| | |
| | | }, |
| | | //保安员证信息导出 |
| | | handleExport() { |
| | | this.$confirm("是否导出保安员证信息数据?", "提示", { |
| | | this.$confirm("是否导出证书制证信息数据?", "提示", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning", |
| | |
| | | this.questionBankSearch["endTime"] = releaseTimeRange[1]; |
| | | } |
| | | var data = { |
| | | type:2, |
| | | applyUnit:this.questionBankSearch.applyUnit, |
| | | auditStatus:this.questionBankSearch.auditStatus, |
| | | deptName: this.questionBankSearch.deptName, |
| | | idCardNo: this.questionBankSearch.idCardNo, |
| | | realName: this.questionBankSearch.realName, |
| | |
| | | startTime: this.questionBankSearch.startTime, |
| | | endTime: this.questionBankSearch.endTime, |
| | | }; |
| | | // data['Blade-Auth'] = getToken; |
| | | //导出 |
| | | // if ( |
| | | // this.userInfo.role_name == "保安公司管理员" || |
| | | // this.userInfo.role_name == "保安" |
| | | // ) { |
| | | // //如果是保安公司管理员 |
| | | // data["deptId"] = this.userInfo.dept_id; |
| | | // } |
| | | if (this.userInfo.role_name == "保安公司管理员") { |
| | | //如果是保安公司管理员 |
| | | data["deptId"] = this.userInfo.dept_id; |
| | | } |
| | | if (this.userInfo.role_name == "培训公司管理员") { |
| | | //如果是培训公司管理员 |
| | | data["trainUnitId"] = this.userInfo.dept_id; |
| | | data["createUser"] = this.userInfo.Id; |
| | | } |
| | | // data["examType"] = 2; |
| | | if (this.userInfo.role_name == "公安管理员") { |
| | | //如果是公安管理员 |
| | | data["jurisdiction"] = this.userInfo.jurisdiction; |
| | | } |
| | | //序列号url形式,用&拼接 |
| | | data = Qs.stringify(data); |
| | | window.open(`/api/accreditationRecords/export-security-paper?` + data); |
| | | window.open(`/api/accreditationRecords/export-security-book-paper?${this.website.tokenHeader}=${getToken()}&`+data); |
| | | }); |
| | | }, |
| | | }, |