flat: 企业审核
This commit is contained in:
@@ -124,3 +124,8 @@ export const stationModify =
|
|||||||
method: 'post',
|
method: 'post',
|
||||||
data: params
|
data: params
|
||||||
})
|
})
|
||||||
|
export const getInviteApproval = (params) => request({
|
||||||
|
url: '/api/jobslink-api/tenant/invite/approval',
|
||||||
|
method: 'post',
|
||||||
|
data: params
|
||||||
|
})
|
||||||
|
|||||||
@@ -2,6 +2,7 @@
|
|||||||
<basic-container>
|
<basic-container>
|
||||||
<avue-crud
|
<avue-crud
|
||||||
ref="crud"
|
ref="crud"
|
||||||
|
:table-loading="loading"
|
||||||
@date-change="dateChange"
|
@date-change="dateChange"
|
||||||
@current-change="currentChange"
|
@current-change="currentChange"
|
||||||
@size-change="sizeChange"
|
@size-change="sizeChange"
|
||||||
@@ -13,6 +14,7 @@
|
|||||||
@search-change="searchChange"
|
@search-change="searchChange"
|
||||||
@refresh-change="refreshChange"
|
@refresh-change="refreshChange"
|
||||||
@search-reset="searchReset"
|
@search-reset="searchReset"
|
||||||
|
@selection-change="selectionChange"
|
||||||
>
|
>
|
||||||
<template slot="menuLeft">
|
<template slot="menuLeft">
|
||||||
<el-button
|
<el-button
|
||||||
@@ -20,7 +22,14 @@
|
|||||||
@click.stop="distributionCodeDialog = true; isEdit = false; inviteCodeForm = {}"
|
@click.stop="distributionCodeDialog = true; isEdit = false; inviteCodeForm = {}"
|
||||||
type="primary"
|
type="primary"
|
||||||
v-show="vaildData(permission.manage_station_inviteCode_edituser, false)"
|
v-show="vaildData(permission.manage_station_inviteCode_edituser, false)"
|
||||||
>新增用户</el-button>
|
>新增用户
|
||||||
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
size="small"
|
||||||
|
@click.stop="handleCheck"
|
||||||
|
type="primary"
|
||||||
|
>审核
|
||||||
|
</el-button>
|
||||||
</template>
|
</template>
|
||||||
<template slot="menu" slot-scope="{row}">
|
<template slot="menu" slot-scope="{row}">
|
||||||
<el-button type="text" @click="rowUpdate(row)">编辑</el-button>
|
<el-button type="text" @click="rowUpdate(row)">编辑</el-button>
|
||||||
@@ -43,9 +52,11 @@
|
|||||||
:visible.sync="distributionCodeDialog"
|
:visible.sync="distributionCodeDialog"
|
||||||
append-to-body
|
append-to-body
|
||||||
width="30%">
|
width="30%">
|
||||||
<el-form :model="inviteCodeForm" :rules="inviteCodeRules" filterable ref="inviteCode" label-width="100px" class="demo-ruleForm">
|
<el-form :model="inviteCodeForm" :rules="inviteCodeRules" filterable ref="inviteCode" label-width="100px"
|
||||||
|
class="demo-ruleForm">
|
||||||
<el-form-item label="企业名称:" prop="companyId">
|
<el-form-item label="企业名称:" prop="companyId">
|
||||||
<el-select v-model="inviteCodeForm.inviteCompanyId" :disabled="isEdit" filterable placeholder="请选择企业" style="width: 260px" >
|
<el-select v-model="inviteCodeForm.inviteCompanyId" :disabled="isEdit" filterable placeholder="请选择企业"
|
||||||
|
style="width: 260px">
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item in enterpriseList"
|
v-for="item in enterpriseList"
|
||||||
:key="item.id"
|
:key="item.id"
|
||||||
@@ -64,7 +75,8 @@
|
|||||||
<el-input style="width: 260px" v-model="inviteCodeForm.phone" placeholder="请输入手机号"></el-input>
|
<el-input style="width: 260px" v-model="inviteCodeForm.phone" placeholder="请输入手机号"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="备注:" prop="remarks">
|
<el-form-item label="备注:" prop="remarks">
|
||||||
<el-input type="textarea" style="width: 260px" v-model="inviteCodeForm.remarks" placeholder="请输入备注" ></el-input>
|
<el-input type="textarea" style="width: 260px" v-model="inviteCodeForm.remarks"
|
||||||
|
placeholder="请输入备注"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<span slot="footer" class="dialog-footer">
|
<span slot="footer" class="dialog-footer">
|
||||||
@@ -82,9 +94,14 @@ import {
|
|||||||
getEnterpriseList,
|
getEnterpriseList,
|
||||||
saveEnterpriseItem,
|
saveEnterpriseItem,
|
||||||
getInvitationCodeList,
|
getInvitationCodeList,
|
||||||
getInvitationStatusUpdate
|
getInvitationStatusUpdate,
|
||||||
|
getInviteApproval
|
||||||
} from "@/api/manage/station";
|
} from "@/api/manage/station";
|
||||||
import {Message} from "element-ui";
|
import {Message} from "element-ui";
|
||||||
|
import lodash from "lodash";
|
||||||
|
import {recruitStatus} from "@/common/dic";
|
||||||
|
import {Auditing} from "@/api/manage/mission";
|
||||||
|
|
||||||
const inviteCodeRules = {
|
const inviteCodeRules = {
|
||||||
stationId: [
|
stationId: [
|
||||||
{required: true, message: '请选择企业', trigger: 'blur'}
|
{required: true, message: '请选择企业', trigger: 'blur'}
|
||||||
@@ -96,17 +113,24 @@ const inviteCodeRules = {
|
|||||||
{required: true, message: '请输入手机号', trigger: 'blur', pattern: /^1[3-9]{1}\d{9}/}
|
{required: true, message: '请输入手机号', trigger: 'blur', pattern: /^1[3-9]{1}\d{9}/}
|
||||||
],
|
],
|
||||||
idNumber: [
|
idNumber: [
|
||||||
{ required: true, message: '请输入身份证', trigger: 'blur', pattern: /^[1-9]\d{5}(19|20)\d{2}(0[1-9]|1[0-2])(0[1-9]|[1-2]\d|3[0-1])\d{3}[\dX]$/}
|
{
|
||||||
|
required: true,
|
||||||
|
message: '请输入身份证',
|
||||||
|
trigger: 'blur',
|
||||||
|
pattern: /^[1-9]\d{5}(19|20)\d{2}(0[1-9]|1[0-2])(0[1-9]|[1-2]\d|3[0-1])\d{3}[\dX]$/
|
||||||
|
}
|
||||||
],
|
],
|
||||||
}
|
}
|
||||||
const curdOptions = {
|
const curdOptions = {
|
||||||
dateBtn: false,
|
dateBtn: false,
|
||||||
addBtn: false,
|
addBtn: false,
|
||||||
|
tip: false,
|
||||||
editBtn: false,
|
editBtn: false,
|
||||||
delBtn: false,
|
delBtn: false,
|
||||||
height: "auto",
|
height: "auto",
|
||||||
border: true,
|
border: true,
|
||||||
searchMenuSpan: 48,
|
searchMenuSpan: 48,
|
||||||
|
selection: true,
|
||||||
index: true,
|
index: true,
|
||||||
indexLabel: "序号",
|
indexLabel: "序号",
|
||||||
column: [{
|
column: [{
|
||||||
@@ -147,6 +171,13 @@ const curdOptions = {
|
|||||||
prop: 'isEnabled',
|
prop: 'isEnabled',
|
||||||
slot: true,
|
slot: true,
|
||||||
width: 100
|
width: 100
|
||||||
|
}, {
|
||||||
|
label: '审核状态',
|
||||||
|
prop: 'reviewStatus',
|
||||||
|
width: 100,
|
||||||
|
type: 'select',
|
||||||
|
dicData: recruitStatus,
|
||||||
|
display: false,
|
||||||
}]
|
}]
|
||||||
}
|
}
|
||||||
const page = {
|
const page = {
|
||||||
@@ -154,6 +185,13 @@ const page = {
|
|||||||
currentPage: 1,
|
currentPage: 1,
|
||||||
total: 0,
|
total: 0,
|
||||||
}
|
}
|
||||||
|
const message = lodash.throttle(
|
||||||
|
function (options) {
|
||||||
|
Message(options);
|
||||||
|
},
|
||||||
|
3000,
|
||||||
|
{trailing: false}
|
||||||
|
);
|
||||||
export default {
|
export default {
|
||||||
name: "manage_station_inviteCode",
|
name: "manage_station_inviteCode",
|
||||||
data() {
|
data() {
|
||||||
@@ -163,10 +201,12 @@ export default {
|
|||||||
enterpriseList: [], // 企业列表
|
enterpriseList: [], // 企业列表
|
||||||
inviteCodeForm: {},
|
inviteCodeForm: {},
|
||||||
inviteCodeList: [],
|
inviteCodeList: [],
|
||||||
|
selectionList: [],
|
||||||
option: Object.assign({}, curdOptions),
|
option: Object.assign({}, curdOptions),
|
||||||
page: Object.assign({}, page),
|
page: Object.assign({}, page),
|
||||||
searchData: {},
|
searchData: {},
|
||||||
isEdit: false,
|
isEdit: false,
|
||||||
|
loading: false,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
activated() {
|
activated() {
|
||||||
@@ -176,6 +216,72 @@ export default {
|
|||||||
...mapGetters(["permission"]),
|
...mapGetters(["permission"]),
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
handleCheck() {
|
||||||
|
let self = this
|
||||||
|
if (this.selectionList.length < 1) {
|
||||||
|
message({
|
||||||
|
type: "warning",
|
||||||
|
message: "请至少选择一条数据",
|
||||||
|
});
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
let idList = this.selectionList.filter((item) => item.reviewStatus === 0).map((v) => v.id)
|
||||||
|
if (idList.length == 0) {
|
||||||
|
this.$message.error("只能提交【审核中】的任务");
|
||||||
|
} else {
|
||||||
|
let h = this.$createElement;
|
||||||
|
this.$prompt(
|
||||||
|
h("p", {style: "color: #F56C6C"}, "一旦驳回无法进行后续操作"),
|
||||||
|
"请核对招聘信息后再进行审核通过",
|
||||||
|
{
|
||||||
|
distinguishCancelAndClose: true,
|
||||||
|
confirmButtonText: "通 过",
|
||||||
|
cancelButtonText: "驳 回",
|
||||||
|
type: "warning",
|
||||||
|
center: true,
|
||||||
|
inputType: "textarea",
|
||||||
|
inputPlaceholder: "备注驳回原因",
|
||||||
|
beforeClose: function (action, instance, done) {
|
||||||
|
if (action === 'cancel') {
|
||||||
|
if (!instance.inputValue) {
|
||||||
|
return this.$message({
|
||||||
|
type: "info",
|
||||||
|
message: "请输入驳回原因!",
|
||||||
|
});
|
||||||
|
}
|
||||||
|
self.handelFetchAuditing(idList, 9, instance.inputValue, "成功驳回, 操作成功!").then(() => done())
|
||||||
|
} else if (action === 'confirm') {
|
||||||
|
self.handelFetchAuditing(idList, 1, instance.inputValue).then(() => done())
|
||||||
|
} else {
|
||||||
|
done()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
handelFetchAuditing(idList, reviewState, msg, message) {
|
||||||
|
return new Promise((resolve, reject) => {
|
||||||
|
let arr = idList.map((item) => ({
|
||||||
|
id: item,
|
||||||
|
reviewStatus: reviewState,
|
||||||
|
reviewMsg: msg || '',
|
||||||
|
}))
|
||||||
|
this.loading = true;
|
||||||
|
getInviteApproval(arr).then(() => {
|
||||||
|
this.loading = false;
|
||||||
|
this.onLoad();
|
||||||
|
this.$message({
|
||||||
|
type: message ? "info" : "success",
|
||||||
|
message: message || "审核通过,操作成功!",
|
||||||
|
});
|
||||||
|
resolve()
|
||||||
|
}).catch(() => {
|
||||||
|
this.loading = false;
|
||||||
|
reject()
|
||||||
|
});
|
||||||
|
})
|
||||||
|
},
|
||||||
rowUpdate(row) {
|
rowUpdate(row) {
|
||||||
this.isEdit = true
|
this.isEdit = true
|
||||||
this.distributionCodeDialog = true
|
this.distributionCodeDialog = true
|
||||||
@@ -211,7 +317,11 @@ export default {
|
|||||||
});
|
});
|
||||||
this.refreshChange();
|
this.refreshChange();
|
||||||
})
|
})
|
||||||
.catch(() => { });
|
.catch(() => {
|
||||||
|
});
|
||||||
|
},
|
||||||
|
selectionChange(list) {
|
||||||
|
this.selectionList = list;
|
||||||
},
|
},
|
||||||
async onLoad() {
|
async onLoad() {
|
||||||
this.getInvitationCode()
|
this.getInvitationCode()
|
||||||
@@ -253,7 +363,9 @@ export default {
|
|||||||
current: this.page.currentPage,
|
current: this.page.currentPage,
|
||||||
size: this.page.pageSize,
|
size: this.page.pageSize,
|
||||||
}
|
}
|
||||||
|
this.loading = true
|
||||||
let resData = await getInvitationCodeList(params)
|
let resData = await getInvitationCodeList(params)
|
||||||
|
this.loading = false
|
||||||
if (resData.data.code === 200) {
|
if (resData.data.code === 200) {
|
||||||
const {size, records, current, total} = resData.data.data
|
const {size, records, current, total} = resData.data.data
|
||||||
this.inviteCodeList = records
|
this.inviteCodeList = records
|
||||||
|
|||||||
Reference in New Issue
Block a user