|
@@ -34,7 +34,12 @@
|
|
|
</el-table-column>
|
|
|
<el-table-column label="人事审核" prop="hrAudit">
|
|
|
<template slot-scope="hrAudit">
|
|
|
- <span>{{ hrAudit.row.hrAudit == 1 ? "审核通过" : "未通过/未审核" }}</span>
|
|
|
+ <span v-if="hrAudit.row.hrAudit == 1">审核通过</span>
|
|
|
+ <span v-else-if="hrAudit.row.hrAudit == 2">审核未通过</span>
|
|
|
+ <span v-else>
|
|
|
+ <a style="color: cornflowerblue;" @click="hrAuditBtn(hrAudit.row.id, 1)">通过</a>
|
|
|
+ <a style="color: red;" @click="hrAuditBtn(hrAudit.row.id, 2)">拒绝</a>
|
|
|
+ </span>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
<el-table-column label="操作" width="180">
|
|
@@ -388,7 +393,7 @@ export default {
|
|
|
type: 'success',
|
|
|
message: '删除成功!'
|
|
|
});
|
|
|
- that.Department();
|
|
|
+ that.user();
|
|
|
} else {
|
|
|
that.$message.error(res.data.msg);
|
|
|
}
|
|
@@ -402,8 +407,47 @@ export default {
|
|
|
});
|
|
|
|
|
|
},
|
|
|
- //#region 添加
|
|
|
+ hrAuditBtn(id, HrAudit) {
|
|
|
+ debugger
|
|
|
+ this.$confirm('是否进行此操作?', '提示', {
|
|
|
+ confirmButtonText: '确定',
|
|
|
+ cancelButtonText: '取消',
|
|
|
+ type: 'warning'
|
|
|
+ }).then(() => {
|
|
|
+ var url = "/api/System/PersonnelAudit"
|
|
|
+ var that = this
|
|
|
+ this.$axios({
|
|
|
+ method: 'post',
|
|
|
+ url: url,
|
|
|
+ headers: {
|
|
|
+ Authorization: 'Bearer ' + this.token
|
|
|
+ },
|
|
|
+ data: {
|
|
|
+ Id: id,
|
|
|
+ isAudit: HrAudit
|
|
|
+ }
|
|
|
+ }).then(function (res) {
|
|
|
+ console.log(res)
|
|
|
|
|
|
+ if (res.data.code == 200) {
|
|
|
+ that.$message({
|
|
|
+ type: 'success',
|
|
|
+ message: '操作成功!'
|
|
|
+ });
|
|
|
+ that.user();
|
|
|
+ } else {
|
|
|
+ that.$message.error(res.data.msg);
|
|
|
+ }
|
|
|
+ })
|
|
|
+ }).catch(() => {
|
|
|
+ debugger
|
|
|
+ this.$message({
|
|
|
+ type: 'info',
|
|
|
+ message: '操作已取消!'
|
|
|
+ });
|
|
|
+ });
|
|
|
+
|
|
|
+ }
|
|
|
//#endregion
|
|
|
|
|
|
},
|