修正接口
This commit is contained in:
@@ -297,40 +297,6 @@ export default {
|
||||
slot: true,
|
||||
width:110
|
||||
},
|
||||
{
|
||||
label: "最新保期",
|
||||
prop: "period",
|
||||
searchSpan: 5,
|
||||
display: false,
|
||||
slot:true,
|
||||
width:190
|
||||
},
|
||||
{
|
||||
label: "商保状态",
|
||||
prop: "serviceStatus",
|
||||
searchSpan: 5,
|
||||
display: false,
|
||||
type: 'select',
|
||||
dicData: [
|
||||
{
|
||||
label: '未生效',
|
||||
value: 0
|
||||
},
|
||||
{
|
||||
label: '生效中',
|
||||
value: 1
|
||||
},
|
||||
{
|
||||
label: '即将失效',
|
||||
value: 2
|
||||
},
|
||||
{
|
||||
label: '已失效',
|
||||
value: 3
|
||||
},
|
||||
],
|
||||
slot:true,
|
||||
},
|
||||
{
|
||||
label: "工种",
|
||||
prop: "workTypes",
|
||||
|
||||
@@ -1,419 +0,0 @@
|
||||
<template>
|
||||
<basic-container>
|
||||
<el-drawer title="评价" append-to-body :visible.sync="drawer" size="60%">
|
||||
<avue-crud :option="option" :table-loading="loading" :data="data" :page.sync="page" ref="crud" v-model="obj"
|
||||
:permission="permissionList" @search-change="searchChange" @search-reset="searchReset"
|
||||
@selection-change="selectionChange" @current-change="currentChange" @size-change="sizeChange"
|
||||
@refresh-change="refreshChange" class="customPage" @on-load="getList">
|
||||
<!--自定义列-->
|
||||
<template slot="resume" slot-scope="{ row }">
|
||||
<div>
|
||||
<el-button type="text" size="mini" @click="$refs.resume.openDialog(row)"
|
||||
v-if="row.userId && row.userId !== '0'">查看简历</el-button>
|
||||
<div v-else>暂无简历</div>
|
||||
</div>
|
||||
</template>
|
||||
<template slot="scoreAll" slot-scope="{ row }">
|
||||
<div @click="rowAppraise(row)">
|
||||
<el-rate v-model="row.scoreAll" disabled></el-rate>
|
||||
</div>
|
||||
</template>
|
||||
<!--/自定义列-->
|
||||
<!--自定义按钮-->
|
||||
<template slot="menuLeft">
|
||||
<el-button type="primary" icon="el-icon-plus" @click="handleImport" size="small"
|
||||
:disabled="!selectionList.length">导入人才库</el-button>
|
||||
</template>
|
||||
<!--/自定义按钮-->
|
||||
</avue-crud>
|
||||
<!--评价dialog-->
|
||||
<el-dialog title :close-on-click-modal="false" :close-on-press-escape="false" :append-to-body="true" width="500px"
|
||||
:visible.sync="box" @closed="closed">
|
||||
<el-form :model="form" :rules="rules" ref="appraiseForm">
|
||||
<el-form-item prop="scoreAll">
|
||||
评价:
|
||||
<el-rate :disabled="!isCanRate && !rateLoading" v-model="form.scoreAll"
|
||||
style="display: inline-block; vertical-align: text-bottom"></el-rate>
|
||||
</el-form-item>
|
||||
<el-form-item prop="remarks">
|
||||
<el-input type="textarea" placeholder="请输入您的评价" v-model="form.remarks" minlength="0" maxlength="50"
|
||||
show-word-limit :disabled="!isCanRate && !rateLoading" :autosize="{ minRows: 5, maxRows: 5 }"></el-input>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button icon="el-icon-check" type="primary" size="small" :loading="rateLoading" @click="submit"
|
||||
v-show="isCanRate === true">提 交</el-button>
|
||||
<el-button icon="el-icon-circle-close" :loading="rateLoading" size="small" @click="box = false"
|
||||
v-show="isCanRate === true">取 消</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
<!--/评价dialog-->
|
||||
<!--导入人才库dialog-->
|
||||
<el-dialog title="导入人才库" append-to-body :visible.sync="importBox" :close-on-click-modal="false"
|
||||
:close-on-press-escape="false" @closed="closedGorups" width="555px">
|
||||
<avue-form ref="groups" :option="importOption" v-model="importForm" @submit="submitImport">
|
||||
<template slot-scope="{ disabled }" slot="menuForm">
|
||||
<!-- <el-button type="primary" icon="el-icon-check" @click="copy" :disabled="formLoading">提交</el-button> -->
|
||||
<el-button icon="el-icon-circle-close" @click="importBox = false" :loading="disabled">取消</el-button>
|
||||
</template>
|
||||
</avue-form>
|
||||
</el-dialog>
|
||||
<!--/导入dialog-->
|
||||
</el-drawer>
|
||||
<Resume ref="resume"></Resume>
|
||||
<!--导入人才库提示错误信息-->
|
||||
<el-dialog title="提示" :visible.sync="errorDialogVisible" width="30%" :before-close="handleClose" append-to-body>
|
||||
<span style="margin-top: -10px;display: block;"><p v-for="(item,index) in errorTipList" :key="index">{{item}}</p></span>
|
||||
</el-dialog>
|
||||
</basic-container>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import {
|
||||
getRateList,
|
||||
getRateDetail,
|
||||
submitRate,
|
||||
importTalents,
|
||||
} from "@/api/tenant/postzp";
|
||||
import Resume from "@/components/resume/index";
|
||||
// import { isExcel } from "@/util/validate";
|
||||
// import {mapGetters} from "vuex";
|
||||
|
||||
export default {
|
||||
comments: {},
|
||||
components: {
|
||||
Resume,
|
||||
},
|
||||
data() {
|
||||
const validateRate = (rule, value, callback) => {
|
||||
if (value > 0) {
|
||||
callback();
|
||||
} else {
|
||||
callback(new Error("请选择评分"));
|
||||
}
|
||||
};
|
||||
return {
|
||||
errorDialogVisible:false,
|
||||
errorTipList:[],
|
||||
missionId: "",
|
||||
worktypeNames: "",
|
||||
userId: "",
|
||||
loading: false,
|
||||
rateLoading: false,
|
||||
isIndeterminate: false,
|
||||
checkAll: false,
|
||||
checked: false,
|
||||
isCanRate: false,
|
||||
form: {},
|
||||
rules: {
|
||||
scoreAll: [
|
||||
{ required: true, validator: validateRate, trigger: "change" },
|
||||
],
|
||||
remarks: [
|
||||
{
|
||||
min: 0,
|
||||
max: 50,
|
||||
message: "长度在 0 到 50 个字符",
|
||||
trigger: "blur",
|
||||
},
|
||||
],
|
||||
},
|
||||
selectionList: [],
|
||||
page: {
|
||||
pageSize: 20,
|
||||
currentPage: 1,
|
||||
total: 0,
|
||||
},
|
||||
query: {},
|
||||
drawer: false,
|
||||
box: false,
|
||||
data: [],
|
||||
obj: {},
|
||||
option: {
|
||||
height: "auto",
|
||||
calcHeight: 30,
|
||||
align: "center",
|
||||
menuAlign: "center",
|
||||
menu: false,
|
||||
tip: false,
|
||||
addBtn: false,
|
||||
viewBtn: false,
|
||||
delBtn: false,
|
||||
editBtn: false,
|
||||
excelBtn: false,
|
||||
columnBtn: false,
|
||||
searchBtn: true,
|
||||
searchShow: true,
|
||||
searchMenuSpan: 7,
|
||||
border: true,
|
||||
index: true,
|
||||
indexLabel: "序号",
|
||||
selection: true,
|
||||
dialogType: "drawer",
|
||||
dialogWidth: "60%",
|
||||
dialogClickModal: false,
|
||||
column: [
|
||||
{
|
||||
label: "姓名",
|
||||
prop: "realName",
|
||||
search: true,
|
||||
searchLabelWidth: 45,
|
||||
searchSpan: 7
|
||||
},
|
||||
{
|
||||
label: "性别",
|
||||
prop: "sex",
|
||||
type: "select",
|
||||
dicData: [
|
||||
{
|
||||
label: "男",
|
||||
value: 1,
|
||||
},
|
||||
{
|
||||
label: "女",
|
||||
value: 2,
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
label: "年龄",
|
||||
prop: "age",
|
||||
},
|
||||
// {
|
||||
// label: "简历",
|
||||
// prop: "resume",
|
||||
// slot: true
|
||||
// },
|
||||
{
|
||||
label: "评价",
|
||||
prop: "scoreAll",
|
||||
slot: true,
|
||||
width: 180,
|
||||
},
|
||||
],
|
||||
},
|
||||
importForm: {},
|
||||
importOption: {
|
||||
menuPosition: "right",
|
||||
menuBtn: true,
|
||||
submitBtn: true,
|
||||
submitText: "导入",
|
||||
emptyBtn: false,
|
||||
column: [
|
||||
{
|
||||
label: "所属分组",
|
||||
prop: "groupId",
|
||||
type: "tree",
|
||||
span: 24,
|
||||
display: true,
|
||||
dicUrl: `/api/jobslink-api/tenant/talents/group/listAll`,
|
||||
dicMethod: "get",
|
||||
dicFormatter: (res) => {
|
||||
return res.data.list; //返回字典的层级结构
|
||||
},
|
||||
props: {
|
||||
label: "groupName",
|
||||
value: "id",
|
||||
},
|
||||
rules: [
|
||||
{
|
||||
required: true,
|
||||
message: "请选择分组",
|
||||
trigger: "change",
|
||||
},
|
||||
],
|
||||
placeholder: "请选择分组",
|
||||
},
|
||||
],
|
||||
},
|
||||
importBox: false,
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
// ...mapGetters(["permission"]),
|
||||
// permissionList() {
|
||||
// return {
|
||||
// addBtn: this.vaildData(this.permission.topmenu_add, false),
|
||||
// viewBtn: this.vaildData(this.permission.topmenu_view, false),
|
||||
// delBtn: this.vaildData(this.permission.topmenu_delete, false),
|
||||
// editBtn: this.vaildData(this.permission.topmenu_edit, false)
|
||||
// };
|
||||
// },
|
||||
ids() {
|
||||
let ids = [];
|
||||
this.selectionList.forEach((ele) => {
|
||||
ids.push(ele.id);
|
||||
});
|
||||
return ids.join(",");
|
||||
},
|
||||
},
|
||||
watch: {},
|
||||
methods: {
|
||||
/*打开drawer*/
|
||||
openDialog(row) {
|
||||
this.missionId = row.missionNo;
|
||||
this.worktypeNames = row.worktypeNames;
|
||||
if (this.$refs.crud) {
|
||||
this.$refs.crud.searchReset();
|
||||
} else {
|
||||
this.query = {};
|
||||
this.getList(this.page, this.query);
|
||||
}
|
||||
this.drawer = true;
|
||||
},
|
||||
/*关闭评分dialog*/
|
||||
closed() {
|
||||
if (this.$refs.appraiseForm) {
|
||||
this.$refs.appraiseForm.resetFields();
|
||||
}
|
||||
},
|
||||
/*关闭导入人才库dialog*/
|
||||
closedGorups() {
|
||||
this.importForm = {};
|
||||
this.$refs.groups.init();
|
||||
this.$refs.groups.clearValidate();
|
||||
this.$refs.groups.resetForm();
|
||||
},
|
||||
/*评价人员*/
|
||||
rowAppraise(row) {
|
||||
this.userId = row.userId;
|
||||
if (row.id === "0") {
|
||||
this.isCanRate = true;
|
||||
this.box = true;
|
||||
this.form = {};
|
||||
} else {
|
||||
//打开评价弹框
|
||||
this.isCanRate = false;
|
||||
this.rateLoading = true;
|
||||
getRateDetail(row.id).then((res) => {
|
||||
this.form = res.data.data;
|
||||
this.rateLoading = false;
|
||||
this.box = true;
|
||||
});
|
||||
}
|
||||
},
|
||||
/*提交评价*/
|
||||
submit() {
|
||||
this.rateLoading = true;
|
||||
this.$refs.appraiseForm.validate((valid) => {
|
||||
if (valid) {
|
||||
submitRate(
|
||||
{
|
||||
scoreAll: this.form.scoreAll,
|
||||
remarks: this.form.remarks,
|
||||
},
|
||||
this.missionId,
|
||||
this.userId
|
||||
).then(
|
||||
() => {
|
||||
this.box = false;
|
||||
this.rateLoading = true;
|
||||
this.$message({
|
||||
type: "success",
|
||||
message: "操作成功!",
|
||||
});
|
||||
this.rateLoading = false;
|
||||
this.getList(this.page, this.query);
|
||||
},
|
||||
(error) => {
|
||||
window.console.log(error);
|
||||
this.rateLoading = false;
|
||||
}
|
||||
);
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
});
|
||||
},
|
||||
/*导入人才库 */
|
||||
handleImport() {
|
||||
if (this.selectionList.length === 0) {
|
||||
this.$message.warning("请选择至少一条数据");
|
||||
return;
|
||||
}
|
||||
this.importBox = true;
|
||||
},
|
||||
/*提交导入人才库 */
|
||||
submitImport(form, done) {
|
||||
var arr = [];
|
||||
this.selectionList.forEach((ele) => {
|
||||
arr.push({
|
||||
userId: ele.userId,
|
||||
name: ele.realName,
|
||||
idNumber: ele.cardNumber,
|
||||
telphone: ele.telphone,
|
||||
});
|
||||
});
|
||||
//导入分组接口
|
||||
importTalents(form.groupId, this.worktypeNames, arr).then(
|
||||
(res) => {
|
||||
this.importBox = false;
|
||||
const data=res.data.data;
|
||||
this.errorTipList=[];
|
||||
if(Object.getOwnPropertyNames(data).length!=0 && data.length!=0){
|
||||
for(var i=0;i<data.length;i++){
|
||||
this.errorTipList[i]=data[i];
|
||||
}
|
||||
this.errorDialogVisible=true;
|
||||
}
|
||||
else{
|
||||
this.$message({
|
||||
type: "success",
|
||||
message: "操作成功!",
|
||||
});
|
||||
}
|
||||
this.getList(this.page, this.query);
|
||||
done();
|
||||
},
|
||||
(error) => {
|
||||
window.console.log(error);
|
||||
done();
|
||||
}
|
||||
);
|
||||
},
|
||||
searchReset() {
|
||||
this.query = {};
|
||||
this.getList(this.page);
|
||||
},
|
||||
searchChange(params, done) {
|
||||
this.query = params;
|
||||
this.page.currentPage = 1;
|
||||
this.getList(this.page, params);
|
||||
done();
|
||||
},
|
||||
selectionChange(list) {
|
||||
this.selectionList = list;
|
||||
},
|
||||
selectionClear() {
|
||||
this.selectionList = [];
|
||||
this.$refs.crud.toggleSelection();
|
||||
},
|
||||
currentChange(currentPage) {
|
||||
this.page.currentPage = currentPage;
|
||||
},
|
||||
sizeChange(pageSize) {
|
||||
this.page.pageSize = pageSize;
|
||||
},
|
||||
/*刷新本页 带搜索参数*/
|
||||
refreshChange() {
|
||||
this.getList(this.page);
|
||||
},
|
||||
/*加载数据*/
|
||||
getList(page, params = {}) {
|
||||
this.loading = true;
|
||||
getRateList(
|
||||
page.currentPage,
|
||||
page.pageSize,
|
||||
Object.assign(params, this.query),
|
||||
this.missionId
|
||||
).then((res) => {
|
||||
const data = res.data.data;
|
||||
this.page.total = data.total;
|
||||
this.data = data.records;
|
||||
this.loading = false;
|
||||
this.selectionClear();
|
||||
});
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
@@ -1,188 +0,0 @@
|
||||
<template>
|
||||
<basic-container>
|
||||
<el-drawer
|
||||
title="比对人才库"
|
||||
append-to-body
|
||||
:visible.sync="drawer"
|
||||
size="65%"
|
||||
class="drawer"
|
||||
>
|
||||
<avue-crud
|
||||
:option="personListOption"
|
||||
:table-loading="loading"
|
||||
:data="data"
|
||||
:page.sync="page"
|
||||
ref="crud"
|
||||
:permission="permissionList"
|
||||
@search-change="searchChange"
|
||||
@search-reset="searchReset"
|
||||
@selection-change="selectionChange"
|
||||
@current-change="currentChange"
|
||||
@size-change="sizeChange"
|
||||
@refresh-change="refreshChange"
|
||||
class="customPage"
|
||||
|
||||
>
|
||||
<!--/自定义按钮-->
|
||||
</avue-crud>
|
||||
<!-- <Resume ref="resume"></Resume> -->
|
||||
<div style="float:right;font-size:18px;">
|
||||
<el-button type="primary" size="small" @click="submitContrastBtn()">提交比对</el-button>
|
||||
<el-button size="small" @click="resetBtn">重置</el-button>
|
||||
</div>
|
||||
</el-drawer>
|
||||
<NoEmployed ref="noEmployed" v-show="false"></NoEmployed>
|
||||
</basic-container>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import {personCountList} from "@/api/tenant/postzp";
|
||||
import { mapGetters } from "vuex";
|
||||
import NoEmployed from "../Dialog/noEmployed"
|
||||
export default {
|
||||
data () {
|
||||
return {
|
||||
isIndeterminate: false,
|
||||
checkAll: false,
|
||||
checked: false,
|
||||
missionId: "",
|
||||
missionTitle: "",
|
||||
stime: "",
|
||||
drawer: false,
|
||||
selectionList: [],
|
||||
loading: false,
|
||||
query: {},
|
||||
page: {
|
||||
pageSize: 10,
|
||||
currentPage: 1,
|
||||
total: 0,
|
||||
},
|
||||
personListOption: {
|
||||
dialogWidth: "50%",
|
||||
align: "center",
|
||||
menuAlign: "center",
|
||||
rowKey: "id",
|
||||
tip: false,
|
||||
menu: false,
|
||||
addBtn: false,
|
||||
columnBtn: false,
|
||||
searchBtn: true,
|
||||
searchShow: true,
|
||||
searchMenuSpan: 6,
|
||||
searchLabelWidth: 45,
|
||||
menuPosition: "center",
|
||||
labelPosition: "right",
|
||||
border: true,
|
||||
index: true,
|
||||
indexLabel: "序号",
|
||||
selection: true,
|
||||
viewBtn: false,
|
||||
dialogType: "dialog",
|
||||
dialogClickModal: false,
|
||||
column: [
|
||||
{
|
||||
label: "分组名称",
|
||||
prop: "groupName",
|
||||
search: false,
|
||||
span: 24,
|
||||
},
|
||||
{
|
||||
label: "人数",
|
||||
prop: "sumNum",
|
||||
search: false,
|
||||
span: 24,
|
||||
},
|
||||
],
|
||||
},
|
||||
excelBox: false,
|
||||
data: [],
|
||||
};
|
||||
},
|
||||
components: {
|
||||
// Resume,
|
||||
NoEmployed
|
||||
},
|
||||
watch: {
|
||||
|
||||
},
|
||||
computed: {
|
||||
...mapGetters(["userInfo", "permission"]),
|
||||
ids () {
|
||||
let ids = [];
|
||||
this.selectionList.forEach((ele) => {
|
||||
ids.push(ele.id);
|
||||
});
|
||||
return ids.join(",");
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
//提交对比
|
||||
submitContrastBtn(){
|
||||
if(this.selectionList.length > 0){
|
||||
this.$refs.noEmployed.openDialog(this.missionId,this.ids);
|
||||
}else{
|
||||
this.$message({
|
||||
type: "error",
|
||||
message: "请选择要比对的人才库!",
|
||||
});
|
||||
}
|
||||
|
||||
},
|
||||
//重置
|
||||
resetBtn(){
|
||||
this.onLoad();
|
||||
},
|
||||
/*打开drawer*/
|
||||
openDialog (row) {
|
||||
this.missionId = row.missionNo;
|
||||
this.missionTitle = row.missionTitle;
|
||||
this.stime = row.stime;
|
||||
if (this.$refs.crud) {
|
||||
this.$refs.crud.searchReset();
|
||||
} else {
|
||||
this.query = {};
|
||||
this.onLoad();
|
||||
}
|
||||
this.drawer = true;
|
||||
},
|
||||
searchReset () {
|
||||
this.query = {};
|
||||
this.onLoad();
|
||||
},
|
||||
searchChange (params, done) {
|
||||
this.query = params;
|
||||
this.page.currentPage = 1;
|
||||
this.onLoad();
|
||||
done();
|
||||
},
|
||||
selectionChange (list) {
|
||||
this.selectionList = list;
|
||||
},
|
||||
selectionClear () {
|
||||
this.selectionList = [];
|
||||
this.$refs.crud.toggleSelection();
|
||||
},
|
||||
currentChange (currentPage) {
|
||||
this.page.currentPage = currentPage;
|
||||
this.onLoad();
|
||||
},
|
||||
sizeChange (pageSize) {
|
||||
this.page.currentPage = 1;
|
||||
this.page.pageSize = pageSize;
|
||||
this.onLoad();
|
||||
},
|
||||
refreshChange () {
|
||||
this.onLoad();
|
||||
},
|
||||
onLoad () {
|
||||
this.loading = true;
|
||||
personCountList().then((res) => {
|
||||
const data = res.data.data;
|
||||
this.data = data;
|
||||
this.loading = false;
|
||||
this.selectionClear();
|
||||
});
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -1,526 +0,0 @@
|
||||
<template>
|
||||
<el-drawer
|
||||
title="确定录用信息"
|
||||
:visible.sync="checkDisplayVisible"
|
||||
size="60%"
|
||||
modal-append-to-body
|
||||
:before-close="drawerClose"
|
||||
class="createOrderTable">
|
||||
<div class="taskInformation">
|
||||
<p><label>岗位名称:{{selectTaskInfo.missionTitle | ellipsis }}</label><label>岗位编号:{{selectTaskInfo.missionNo}}</label><label>录用人员:<font style="color:#409eff">{{selectionList.length == 0 ? 1 :selectionList.length}} </font> 人</label></p>
|
||||
</div>
|
||||
<div class="create-order-box">
|
||||
<div class="create-order-bill">
|
||||
<div class="create-order-box-title">
|
||||
<span>发票信息</span>
|
||||
<!-- <el-button @click="goSetting" type="text">编辑发票信息</el-button> -->
|
||||
</div>
|
||||
<div class="create-order-box-body">
|
||||
<p>发票抬头:{{fpData.titleName}}</p>
|
||||
<p v-if="fpData.type===0">发票类型:增值税普通发票</p>
|
||||
<p v-if="fpData.type===1">发票类型:增值税专用发票</p>
|
||||
<p>纳税人识别号: {{fpData.regNumber}}</p>
|
||||
<p>注册地址&电话:{{fpData.regAddress}} {{fpData.regTelphone}}</p>
|
||||
<p>开户行及账号:{{fpData.bankName}} {{fpData.bankNumber}}</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="create-order-address">
|
||||
<div class="create-order-box-title">
|
||||
<span>收件信息</span>
|
||||
<!-- <el-button type="text">添加收件地址</el-button> -->
|
||||
</div>
|
||||
<div class="create-order-box-body">
|
||||
<el-table class="seventy_table_m_height" :data="addresses" max-height="400" @row-click="rowClick" ref="table">
|
||||
<el-table-column width="55">
|
||||
<template slot-scope="scope">
|
||||
<el-radio v-model="addressId" :label="scope.row.id"> </el-radio>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="contacts" min-width="60"></el-table-column>
|
||||
<el-table-column prop="telphone" min-width="100"></el-table-column>
|
||||
<el-table-column min-width="180" :show-overflow-tooltip="true">
|
||||
<template slot-scope="scope">
|
||||
<div>{{getCity(scope.row.cityId)}}{{scope.row.address}}</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="email" min-width="100"></el-table-column>
|
||||
</el-table>
|
||||
</div>
|
||||
</div>
|
||||
<div class="create-order-pwd">
|
||||
<div>
|
||||
<!-- <p style="text-align:center; font-size:16px">您选择<span class="employ-employNum-count">{{employNum}}</span>人准备录用,请输入密码并确定录用</p> -->
|
||||
<el-form :model="pwdForm" ref="pwdForm" :rules="pwdFormRules" v-if="companyContractOn == 1">
|
||||
<el-form-item
|
||||
label="输入密码:"
|
||||
prop="pwd"
|
||||
:label-position="labelPosition"
|
||||
label-width="100px"
|
||||
>
|
||||
<el-col :span="16">
|
||||
<el-input type="number" v-model="pwdForm.pwd" maxlength="6" onKeypress="return(/^[0-9]*$/.test(String.fromCharCode(event.keyCode)))" show-password placeholder="请输入签章密码"></el-input>
|
||||
</el-col>
|
||||
</el-form-item>
|
||||
<el-form-item class="employ-forgetPwd">
|
||||
<el-button type="text" @click="forgetPwd">忘记密码?</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<p>
|
||||
<el-checkbox v-model="read"></el-checkbox>
|
||||
<span @click="read = !read" class="insure-confirm-agreement">
|
||||
我已阅读
|
||||
<a
|
||||
@click.stop
|
||||
href="/blackboard/insure/insureagreement.html"
|
||||
target="blank"
|
||||
style="color:#409eff"
|
||||
>《投保须知》</a
|
||||
>
|
||||
</span>
|
||||
</p>
|
||||
<p style="color:#ff0000;font-size:13px">提示:系统将按照投保规则,在岗位开始前一天自动为录用人员投保,投保成功后,请前往“订单管理”模块支付,超过15天未支付则不可以再次发布岗位。</p>
|
||||
</div>
|
||||
<!-- <span slot="footer" class="dialog-footer">
|
||||
<el-button type="primary" @click="PWDOk" :loading="loadingbut">{{loadingbuttext}}</el-button>
|
||||
<el-button @click="dialogVisible1 = false">取 消</el-button>
|
||||
</span> -->
|
||||
</div>
|
||||
<el-row class="create-order-footer">
|
||||
<el-col :span="24">
|
||||
<el-button
|
||||
@click="confirm"
|
||||
type="primary"
|
||||
size="small"
|
||||
:loading="confirmBtnLoading"
|
||||
:disabled="confirmDisabled"
|
||||
>确定录用</el-button>
|
||||
<el-button
|
||||
@click="closeConfirm"
|
||||
type="info"
|
||||
size="small"
|
||||
>取消</el-button>
|
||||
|
||||
</el-col>
|
||||
</el-row>
|
||||
</div>
|
||||
<!--忘记密码dialog-->
|
||||
<el-dialog title="重置密码" :visible.sync="resetPwdDialogVisible" append-to-body width="30%">
|
||||
<el-form class="econtract-resetForm" label-position="right" :model="resetPwdForm" :rules="resetPwdRules" ref="resetPwdForm">
|
||||
<el-form-item label="手机号码:" :label-width="formLabelWidth" prop="account" >
|
||||
<span>{{phone}}</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="请输入验证码:" :label-width="formLabelWidth" prop="code">
|
||||
<el-input v-model="resetPwdForm.code" autocomplete="off" style="width: 50%;"></el-input>
|
||||
<el-button :disabled="msgKey" style="margin-left: 15px;" type="primary" @click="getCode">{{msgText}}</el-button>
|
||||
</el-form-item>
|
||||
<el-form-item label="请设置新密码:" :label-width="formLabelWidth" prop="pwd">
|
||||
<el-input type="number" v-model="resetPwdForm.pwd" maxlength="6" onKeypress="return(/^[0-9]*$/.test(String.fromCharCode(event.keyCode)))" autocomplete="off" show-password placeholder="请输入六位数字密码"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="请再次输入新密码:" :label-width="formLabelWidth" prop="pwd2">
|
||||
<el-input type="number" maxlength="6" onKeypress="return(/^[0-9]*$/.test(String.fromCharCode(event.keyCode)))" v-model="resetPwdForm.pwd2" autocomplete="off" show-password placeholder="请再次输入六位数字密码"></el-input>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="resetPwdDialogVisible = false">取 消</el-button>
|
||||
<el-button type="primary" @click="submitResetPwd">确 认</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</el-drawer>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { dateFormat } from "@/util/date";
|
||||
import {applyStatus} from '@/api/manage/econtract'
|
||||
import { employ } from "@/api/tenant/postzp";
|
||||
import {certCheckPass,getCode,resetPwd} from "@/api/manage/econtract.js";//api
|
||||
export default {
|
||||
props: { fpData: Object,fpTitleId:Number, checkDisplayVisible: Boolean ,usersInfo:Array},
|
||||
data () {
|
||||
const validatePwdLength=(rule,value,callback)=>{
|
||||
if(value.length!=6 || isNaN(Number(value))){
|
||||
this.loading = false;
|
||||
this.confirmBtnLoading = false;
|
||||
this.confirmDisabled = false;
|
||||
callback(new Error('请输入6位数的数字密码'));
|
||||
}
|
||||
else{
|
||||
callback();
|
||||
}
|
||||
}
|
||||
const validatePwd = (rule, value, callback) => {
|
||||
if (value != this.resetPwdForm.pwd) {
|
||||
callback(new Error('两次输入密码不一致'));
|
||||
}
|
||||
else {
|
||||
callback();
|
||||
}
|
||||
};
|
||||
const validPwdNums=(rule,value,callback)=>{
|
||||
if(value.length!=6 || isNaN(Number(value))){
|
||||
callback(new Error('请输入6位数的数字密码'));
|
||||
}
|
||||
else{
|
||||
callback();
|
||||
}
|
||||
}
|
||||
return {
|
||||
read: false,
|
||||
confirmDisabled:false,
|
||||
selectTaskInfo:{},
|
||||
selectionList:[],
|
||||
addresses: [],
|
||||
addressId: '',
|
||||
insureNum:0,
|
||||
pwdForm: {
|
||||
pwd: ''
|
||||
},
|
||||
confirmFormData:[],
|
||||
confirmBtnLoading:false,
|
||||
employDataIds:1,
|
||||
pwdFormRules:{
|
||||
pwd:[
|
||||
{
|
||||
required:true,message:'请输入密码',trigger:'blur'
|
||||
},
|
||||
{
|
||||
validator:validatePwdLength,trigger:'blur'
|
||||
},
|
||||
|
||||
]
|
||||
},
|
||||
loadingbuttext:'确定',
|
||||
loadingbut:false,
|
||||
companyContractOn:'',//电子合同状态
|
||||
conpanySealOn:'',//签章状态
|
||||
/*忘记密码*/
|
||||
resetPwdDialogVisible:false,
|
||||
resetPwdForm:{},
|
||||
formLabelWidth:'150px',
|
||||
msgText: '获取验证码',
|
||||
msgTime:120,
|
||||
//重置密码校验
|
||||
resetPwdRules: {
|
||||
code: [
|
||||
{
|
||||
required: true, message: '请输入验证码', trigger: 'blur'
|
||||
}
|
||||
],
|
||||
pwd: [
|
||||
{
|
||||
required: true, message: '请输入密码', trigger: 'blur'
|
||||
},
|
||||
{
|
||||
validator: validPwdNums, trigger: 'blur'
|
||||
}
|
||||
],
|
||||
pwd2: [
|
||||
{
|
||||
required: true, message: '请输入确认密码', trigger: 'blur'
|
||||
},
|
||||
{
|
||||
validator: validatePwd, trigger: 'blur'
|
||||
}
|
||||
]
|
||||
|
||||
},
|
||||
}
|
||||
},
|
||||
filters: {
|
||||
ellipsis(value) {
|
||||
if (!value) return "";
|
||||
if (value.length > 15) {
|
||||
return value.slice(0, 14) + "...";
|
||||
}
|
||||
return value;
|
||||
},
|
||||
},
|
||||
computed: {
|
||||
},
|
||||
mounted(){
|
||||
this.checkStatus();
|
||||
},
|
||||
methods: {
|
||||
//输入密码点击确定
|
||||
PWDOk(){
|
||||
this.loading = true;
|
||||
this.confirmBtnLoading = true;
|
||||
this.confirmDisabled = true;
|
||||
this.$refs.pwdForm.validate(valid=>{
|
||||
if(valid){
|
||||
// this.loadingbut = true;
|
||||
// this.loadingbuttext = '提交中...';
|
||||
certCheckPass(this.pwdForm.pwd).then((res)=>{
|
||||
if(res.data.data == true){//输入签章密码正确走录用流程
|
||||
if(this.addressId){
|
||||
this.employApi(this.employDataIds,this.fpTitleId,this.addressId);
|
||||
}else{
|
||||
this.$message.warning("请选择收件地址");
|
||||
}
|
||||
}else{
|
||||
this.$message.closeAll();
|
||||
this.loading = false;
|
||||
this.confirmBtnLoading = false;
|
||||
this.confirmDisabled = false;
|
||||
this.$message({
|
||||
type: "error",
|
||||
message: "签章密码输入错误!",
|
||||
});
|
||||
// this.loadingbut=false;
|
||||
// this.loadingbuttext='确定';
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
})
|
||||
|
||||
},
|
||||
/*获取验证码*/
|
||||
getCode() {
|
||||
this.msgKey = true;
|
||||
this.msgText = "发送中...";
|
||||
getCode(this.usersInfo.account)
|
||||
.then(() => {
|
||||
this.msgText = "剩余" + 120 + "s";
|
||||
this.msgKey = true;
|
||||
const time = setInterval(() => {
|
||||
this.msgTime--;
|
||||
this.msgText = "剩余" + this.msgTime + "s";
|
||||
if (this.msgTime <= 0) {
|
||||
this.msgTime = 120;
|
||||
this.msgText = "重新获取";
|
||||
this.msgKey = false;
|
||||
clearInterval(time);
|
||||
}
|
||||
}, 1000);
|
||||
})
|
||||
.catch(() => {
|
||||
this.msgText = "重新获取";
|
||||
this.msgKey = false;
|
||||
});
|
||||
|
||||
},
|
||||
forgetPwd(){
|
||||
this.phone=this.usersInfo.account;
|
||||
var pat=/(\d{3})\d*(\d{4})/;
|
||||
this.phone=this.phone.replace(pat,'$1****$2');
|
||||
this.resetPwdDialogVisible=true;
|
||||
this.resetPwdForm={};
|
||||
},
|
||||
//录用确定
|
||||
employApi(ids,fpTitleId,fpAddressId){
|
||||
this.loading = true;
|
||||
this.confirmBtnLoading = true;
|
||||
this.confirmDisabled = true;
|
||||
employ(this.selectTaskInfo.missionNo, ids,fpTitleId,fpAddressId).then(
|
||||
() => {
|
||||
// this.loadingbut = false;
|
||||
// this.loadingbuttext = '确定';
|
||||
this.$message({
|
||||
type: "success",
|
||||
message: "操作成功!",
|
||||
});
|
||||
this.checkDisplayVisible = false;
|
||||
this.$emit('checkDisplayVisibleClose');
|
||||
this.$emit("refresh");
|
||||
this.loading = false;
|
||||
this.confirmBtnLoading = false;
|
||||
this.confirmDisabled = false;
|
||||
},
|
||||
(error) => {
|
||||
// this.loadingbut = false;
|
||||
// this.loadingbuttext = '确定';
|
||||
window.console.log(error);
|
||||
this.dialogVisible1 = false;
|
||||
}
|
||||
);
|
||||
},
|
||||
checkStatus(){
|
||||
this.companyContractOn = 0;//电子合同是否启用,0=未启用
|
||||
this.conpanySealOn = 0;//电子签章是否设置,0=未设置,1=等待审核,2=已设置
|
||||
// applyStatus().then(res=>{
|
||||
// this.companyContractOn=res.data.data.contractOn;//电子合同是否启用,0=未启用 1=已启用
|
||||
// this.conpanySealOn=res.data.data.sealOn;//电子签章是否设置,0=未设置,1=等待审核,2=已设置
|
||||
// })
|
||||
},
|
||||
drawerClose(){
|
||||
this.$emit('refresh');
|
||||
this.$emit('checkDisplayVisibleClose');
|
||||
},
|
||||
openDialog (selectTaskInfo,employDataIds,selectionList) {
|
||||
this.read = false;
|
||||
this.selectionList = selectionList;
|
||||
this.pwdForm.pwd = "";
|
||||
this.employDataIds = employDataIds;
|
||||
this.selectTaskInfo = selectTaskInfo;
|
||||
// this.insureNum = this.usersInfo.length;
|
||||
this.confirmBtnLoading = false;
|
||||
this.confirmDisabled = false;
|
||||
},
|
||||
format (date) {
|
||||
if (date) {
|
||||
return dateFormat(new Date(date), "yyyy-MM-dd");
|
||||
}
|
||||
},
|
||||
confirm () {
|
||||
this.loading = true;
|
||||
this.confirmBtnLoading = true;
|
||||
this.confirmDisabled = true;
|
||||
if (!this.read) {
|
||||
this.$message.closeAll();
|
||||
this.$message({ type: "error", message: "请阅读并同意《投保须知》" });
|
||||
this.loading = false;
|
||||
this.confirmBtnLoading = false;
|
||||
this.confirmDisabled = false;
|
||||
return;
|
||||
}
|
||||
if(this.companyContractOn == 1 && !this.pwdForm.pwd){
|
||||
this.$message.closeAll();
|
||||
this.$message({ type: "error", message: "请输入签章密码" });
|
||||
this.loading = false;
|
||||
this.confirmBtnLoading = false;
|
||||
this.confirmDisabled = false;
|
||||
return;
|
||||
}
|
||||
if(this.companyContractOn == 1 && this.pwdForm.pwd){
|
||||
this.PWDOk()
|
||||
}else{
|
||||
if(this.addressId){
|
||||
this.employApi(this.employDataIds,this.fpTitleId,this.addressId);
|
||||
}else{
|
||||
this.$message.warning("请选择收件地址");
|
||||
this.loading = false;
|
||||
this.confirmBtnLoading = false;
|
||||
this.confirmDisabled = false;
|
||||
}
|
||||
}
|
||||
},
|
||||
rowClick (row) {
|
||||
this.addressId = row.id;
|
||||
},
|
||||
closeConfirm(){
|
||||
this.$emit('refresh');
|
||||
this.$emit('checkDisplayVisibleClose');
|
||||
},
|
||||
/*重置密码*/
|
||||
submitResetPwd() {
|
||||
this.$refs.resetPwdForm.validate(valid => {
|
||||
if (valid) {
|
||||
resetPwd(this.usersInfo.account,this.resetPwdForm.pwd,this.resetPwdForm.code).then(()=>{
|
||||
this.$message.success('密码重置成功');
|
||||
this.resetPwdDialogVisible=false;
|
||||
})
|
||||
.catch((err)=>{
|
||||
this.$message.error(err);
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
//接受收件地址列表 并设置默认勾选
|
||||
getData (addresses) {
|
||||
this.addresses = addresses;
|
||||
this.addresses.forEach(ele => {
|
||||
if (ele.isDefault === 1) {
|
||||
this.addressId = ele.id;
|
||||
}
|
||||
});
|
||||
},
|
||||
getCity (val) {
|
||||
return this.$store.getters.getAreaParents(val)[0].label + this.$store.getters.getAreaParents(val)[1].label + this.$store.getters.getAreaParents(val)[2].label
|
||||
}
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<style>
|
||||
.createOrderTable .el-drawer__header{
|
||||
margin-bottom: 0;
|
||||
}
|
||||
.createOrderTable .el-drawer__body{
|
||||
padding-top: 0;
|
||||
}
|
||||
.tipsBox {
|
||||
padding-left:20px;
|
||||
padding-bottom: 20px;
|
||||
}
|
||||
.tipsBox .insureNum{
|
||||
color: #000;
|
||||
padding: 10px 0;
|
||||
margin: 0;
|
||||
}
|
||||
.tipsBox .buttonR{
|
||||
float: right;
|
||||
margin-right: 130px;
|
||||
margin-top: -20px;
|
||||
}
|
||||
.tipsBox .insureNum font{
|
||||
color: #ff0000;
|
||||
font-weight: 700;
|
||||
}
|
||||
.tipsBox .tipsSpan{
|
||||
color: #ff0000;
|
||||
font-size: 14px;
|
||||
}
|
||||
.create-order-box {
|
||||
height: 85% !important;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.create-order-bill,
|
||||
.create-order-address {
|
||||
border: 1px solid #ebeef5;
|
||||
margin-bottom: 10px;
|
||||
position: relative;
|
||||
padding-top: 52px;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
.create-order-box-title {
|
||||
font-size: 18px;
|
||||
padding: 10px;
|
||||
border-bottom: 1px solid #ebeef5;
|
||||
position: absolute;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: space-between;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.create-order-box-body {
|
||||
margin: 10px;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.create-order-footer {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
margin: auto;
|
||||
text-align: center;
|
||||
}
|
||||
.create-order-box .el-table__header {
|
||||
display: none;
|
||||
}
|
||||
.create-order-pwd{
|
||||
background-color: #fafafa;
|
||||
padding: 30px 20px;
|
||||
}
|
||||
.taskInformation label {
|
||||
margin-right: 80px;
|
||||
}
|
||||
.create-order-pwd .employ-forgetPwd{
|
||||
margin-top: -72px;
|
||||
margin-left: 400px;
|
||||
float: left;
|
||||
}
|
||||
.create-order-pwd .el-input--suffix .el-input__inner{
|
||||
width: 280px;
|
||||
}
|
||||
.create-order-pwd .el-input{
|
||||
width: 280px;
|
||||
}
|
||||
.create-order-pwd .el-form-item__content{
|
||||
width: 300px;
|
||||
}
|
||||
</style>
|
||||
@@ -1,607 +0,0 @@
|
||||
<template>
|
||||
<basic-container>
|
||||
<el-drawer
|
||||
title="已录用人员"
|
||||
append-to-body
|
||||
:visible.sync="drawer"
|
||||
size="80%"
|
||||
class="drawer"
|
||||
:before-close="drawerClose"
|
||||
>
|
||||
<!-- <div class="tipsWrap" v-show="getUserConfig.insuranceOn == 1">录用人员说明:不在保期的人员,不可以录用,请先到 “商保管理" 模块申请投保</div> -->
|
||||
<avue-crud
|
||||
:option="option"
|
||||
:table-loading="loading"
|
||||
:data="data"
|
||||
:page.sync="page"
|
||||
ref="crud"
|
||||
v-model="obj"
|
||||
:permission="permissionList"
|
||||
@search-change="searchChange"
|
||||
@search-reset="searchReset"
|
||||
@current-change="currentChange"
|
||||
@size-change="sizeChange"
|
||||
@refresh-change="refreshChange"
|
||||
class="customPage"
|
||||
@on-load="onLoad"
|
||||
>
|
||||
<!--自定义列-->
|
||||
<template slot="period" slot-scope="{row}">
|
||||
<span v-if="row.startTime && row.endTime">
|
||||
<el-tag type="warning" v-if="row.serviceStatus==0">{{dateFormat(row.startTime)}}-{{dateFormat(row.endTime)}}</el-tag>
|
||||
<el-tag type="success" v-if="row.serviceStatus==1">{{dateFormat(row.startTime)}}-{{dateFormat(row.endTime)}}</el-tag>
|
||||
<el-tag type="danger" v-if="row.serviceStatus==2">{{dateFormat(row.startTime)}}-{{dateFormat(row.endTime)}}</el-tag>
|
||||
<el-tag type="info" v-if="row.serviceStatus==3">{{dateFormat(row.startTime)}}-{{dateFormat(row.endTime)}}</el-tag>
|
||||
</span>
|
||||
</template>
|
||||
<template slot="serviceStatus" slot-scope="{row}" >
|
||||
<span>
|
||||
<el-tag type="warning" v-if="row.serviceStatus==0">未生效</el-tag>
|
||||
<el-tag type="success" v-if="row.serviceStatus==1">生效中</el-tag>
|
||||
<el-tag type="danger" v-if="row.serviceStatus==2">即将失效</el-tag>
|
||||
<el-tag type="info" v-if="row.serviceStatus==3">已失效</el-tag>
|
||||
</span>
|
||||
|
||||
</template>
|
||||
<template slot="missionDate" slot-scope="{ row }">
|
||||
<div>{{ row.startDate }}至{{ row.endDate }}</div>
|
||||
</template>
|
||||
<template slot="resume" slot-scope="{ row }">
|
||||
<div>
|
||||
<el-button
|
||||
type="text"
|
||||
size="mini"
|
||||
@click="$refs.resume.openDialog(row)"
|
||||
v-if="row.userId && row.userId !== '0'"
|
||||
>查看简历</el-button
|
||||
>
|
||||
<div v-else>暂无简历</div>
|
||||
</div>
|
||||
</template>
|
||||
<template slot="canBao" slot-scope="{ row }">
|
||||
<div>
|
||||
<el-button type="text" size="mini">{{ row.canBao }}</el-button>
|
||||
</div>
|
||||
</template>
|
||||
<!--/自定义列-->
|
||||
<template v-slot:cardNumber="{row}">
|
||||
<span>{{idNumberDDesensitization(row.cardNumber)}}</span>
|
||||
</template>
|
||||
|
||||
</avue-crud>
|
||||
</el-drawer>
|
||||
</basic-container>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { employList, cancelEmploy, } from "@/api/tenant/postzp";
|
||||
import {getCode,resetPwd} from "@/api/manage/econtract.js";//api
|
||||
import Resume from "@/components/resume/index";
|
||||
import { idNumberDDesensitization } from "@/util/util";
|
||||
import {mapGetters} from 'vuex'
|
||||
import { dateFormat } from "@/util/date";
|
||||
import {getConfig} from '@/api/tenant/config'
|
||||
import EmployInformation from "./EmployInformation";
|
||||
export default {
|
||||
comments: {},
|
||||
components: {
|
||||
Resume,
|
||||
EmployInformation
|
||||
},
|
||||
props: {
|
||||
status: Number,
|
||||
},
|
||||
|
||||
data() {
|
||||
const validatePwdLength=(rule,value,callback)=>{
|
||||
if(value.length!=6 || isNaN(Number(value))){
|
||||
callback(new Error('请输入6位数的数字密码'));
|
||||
}
|
||||
else{
|
||||
callback();
|
||||
}
|
||||
}
|
||||
|
||||
const validatePwd = (rule, value, callback) => {
|
||||
if (value != this.resetPwdForm.pwd) {
|
||||
callback(new Error('两次输入密码不一致'));
|
||||
}
|
||||
else {
|
||||
callback();
|
||||
}
|
||||
};
|
||||
const validPwdNums=(rule,value,callback)=>{
|
||||
if(value.length!=6 || isNaN(Number(value))){
|
||||
callback(new Error('请输入6位数的数字密码'));
|
||||
}
|
||||
else{
|
||||
callback();
|
||||
}
|
||||
}
|
||||
|
||||
return {
|
||||
selectTaskInfo:{},
|
||||
getUserConfig:{},
|
||||
checkDisplayVisible: false,
|
||||
fpTitleId:'',
|
||||
fpData: {},
|
||||
pwdFormRules:{
|
||||
pwd:[
|
||||
{
|
||||
required:true,message:'请输入密码',trigger:'blur'
|
||||
},
|
||||
{
|
||||
validator:validatePwdLength,trigger:'blur'
|
||||
},
|
||||
|
||||
]
|
||||
},
|
||||
selectionFlag:true,
|
||||
/*忘记密码*/
|
||||
resetPwdDialogVisible:false,
|
||||
resetPwdForm:{},
|
||||
formLabelWidth:'150px',
|
||||
msgText: '获取验证码',
|
||||
msgTime:120,
|
||||
//重置密码校验
|
||||
resetPwdRules: {
|
||||
code: [
|
||||
{
|
||||
required: true, message: '请输入验证码', trigger: 'blur'
|
||||
}
|
||||
],
|
||||
pwd: [
|
||||
{
|
||||
required: true, message: '请输入密码', trigger: 'blur'
|
||||
},
|
||||
{
|
||||
validator: validPwdNums, trigger: 'blur'
|
||||
}
|
||||
],
|
||||
pwd2: [
|
||||
{
|
||||
required: true, message: '请输入确认密码', trigger: 'blur'
|
||||
},
|
||||
{
|
||||
validator: validatePwd, trigger: 'blur'
|
||||
}
|
||||
]
|
||||
|
||||
},
|
||||
|
||||
loadingbut:false,
|
||||
loadingbuttext:'确定',
|
||||
downLoadRow:{},
|
||||
dataCurClick:{},
|
||||
employDataIds:1,
|
||||
employNum:1,
|
||||
imgStr:'',
|
||||
isIndeterminate: false,
|
||||
checkAll: false,
|
||||
checked: false,
|
||||
missionId: "",
|
||||
loading: false,
|
||||
selectionList: [],
|
||||
dialogVisible: false,
|
||||
dialogVisible1: false,
|
||||
contractId:'',
|
||||
labelPosition: 'right',
|
||||
pwdForm: {
|
||||
pwd: ''
|
||||
},
|
||||
page: {
|
||||
pageSize: 20,
|
||||
currentPage: 1,
|
||||
total: 0,
|
||||
},
|
||||
query: {
|
||||
status: 1,
|
||||
},
|
||||
drawer: false,
|
||||
data: [],
|
||||
obj: {},
|
||||
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
...mapGetters(['userInfo']),
|
||||
ids() {
|
||||
let ids = [];
|
||||
this.selectionList.forEach((ele) => {
|
||||
ids.push(ele.id);
|
||||
});
|
||||
return ids.join(",");
|
||||
},
|
||||
employState() {
|
||||
return this.query.status;
|
||||
},
|
||||
option() {
|
||||
//const self = this;
|
||||
return {
|
||||
height: "auto",
|
||||
align: "center",
|
||||
// menuAlign: "center",
|
||||
tip: false,
|
||||
addBtn: false,
|
||||
viewBtn: false,
|
||||
delBtn: false,
|
||||
editBtn: false,
|
||||
excelBtn: false,
|
||||
columnBtn: false,
|
||||
searchBtn: true,
|
||||
searchShow: true,
|
||||
searchMenuSpan: 6,
|
||||
searchLabelWidth: 60,
|
||||
menu:false,
|
||||
// menuPosition: "center",
|
||||
labelPosition: "right",
|
||||
border: true,
|
||||
index: false,
|
||||
// index: true,
|
||||
// indexLabel: "序号",
|
||||
// selection: this.selectionFlag,
|
||||
// selectable: function (row) {
|
||||
// return !row.noSelection;
|
||||
// },
|
||||
dialogType: "drawer",
|
||||
dialogWidth: "60%",
|
||||
dialogClickModal: false,
|
||||
column: [
|
||||
{
|
||||
label: "",
|
||||
prop: "status",
|
||||
search: true,
|
||||
searchSpan: 5,
|
||||
searchLabelWidth: 1,
|
||||
hide: true,
|
||||
searchslot: true,
|
||||
},
|
||||
{
|
||||
label: "姓名",
|
||||
prop: "realName",
|
||||
search: true,
|
||||
searchSpan: 4,
|
||||
width:70,
|
||||
},
|
||||
{
|
||||
label: "性别",
|
||||
prop: "sex",
|
||||
search: false,
|
||||
width:50,
|
||||
dicData: [
|
||||
{
|
||||
label: "男",
|
||||
value: 1,
|
||||
},
|
||||
{
|
||||
label: "女",
|
||||
value: 2,
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
label: "年龄",
|
||||
prop: "age",
|
||||
search: false,
|
||||
width:50,
|
||||
},
|
||||
{
|
||||
label: "手机号",
|
||||
prop: "telphone",
|
||||
search: false,
|
||||
width:100,
|
||||
},
|
||||
{
|
||||
label: "身份证",
|
||||
prop: "cardNumber",
|
||||
search: false,
|
||||
slot: true,
|
||||
width:110
|
||||
},
|
||||
{
|
||||
label: "最新保期",
|
||||
prop: "period",
|
||||
searchSpan: 5,
|
||||
display: false,
|
||||
slot:true,
|
||||
width:190
|
||||
},
|
||||
{
|
||||
label: "商保状态",
|
||||
prop: "serviceStatus",
|
||||
searchSpan: 5,
|
||||
display: false,
|
||||
type: 'select',
|
||||
dicData: [
|
||||
{
|
||||
label: '未生效',
|
||||
value: 0
|
||||
},
|
||||
{
|
||||
label: '生效中',
|
||||
value: 1
|
||||
},
|
||||
{
|
||||
label: '即将失效',
|
||||
value: 2
|
||||
},
|
||||
{
|
||||
label: '已失效',
|
||||
value: 3
|
||||
},
|
||||
],
|
||||
slot:true,
|
||||
},
|
||||
{
|
||||
label: "工种",
|
||||
prop: "workTypes",
|
||||
},
|
||||
{
|
||||
label: "来源",
|
||||
prop: "src",
|
||||
search: false,
|
||||
width:70,
|
||||
},
|
||||
{
|
||||
label: "人才库",
|
||||
prop: "groupId",
|
||||
type: "tree",
|
||||
span: 24,
|
||||
search: true,
|
||||
display: true,
|
||||
width: '150',
|
||||
dicUrl: `/api/jobslink-api/tenant/talents/group/listAll`,
|
||||
dicFormatter: (res) => {
|
||||
return res.data.list; //返回字典的层级结构
|
||||
},
|
||||
props: {
|
||||
label: "groupName",
|
||||
value: "id",
|
||||
},
|
||||
placeholder: "请选择分组",
|
||||
},
|
||||
],
|
||||
};
|
||||
},
|
||||
},
|
||||
watch: {
|
||||
"query.status": function (val, oldVal) {
|
||||
this.query.realName = '';
|
||||
this.query.groupId = '';
|
||||
if (val !== oldVal) {
|
||||
this.query.status = val;
|
||||
this.page.currentPage = 1;
|
||||
this.onLoad(this.page, this.query);
|
||||
}
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
checkDisplayVisibleClose(){
|
||||
this.checkDisplayVisible = false;
|
||||
},
|
||||
rowEmployDisabled(){
|
||||
},
|
||||
dateFormat(date){
|
||||
return dateFormat(new Date(date),'yyyy/MM/dd')
|
||||
},
|
||||
idNumberDDesensitization,
|
||||
drawerClose(){
|
||||
this.$emit('refresh');
|
||||
this.drawer = false;
|
||||
},
|
||||
radioButtonChange(){
|
||||
this.query.realName = '';
|
||||
this.query.groupId = '';
|
||||
if(this.query.status == 2){
|
||||
this.selectionFlag = false;
|
||||
}else{
|
||||
this.selectionFlag = true;
|
||||
}
|
||||
},
|
||||
/*打开drawer*/
|
||||
openDialog(row, status) {
|
||||
this.selectTaskInfo = row;
|
||||
this.missionId = row.missionNo;
|
||||
this.query = {
|
||||
status: status,
|
||||
};
|
||||
if (this.$refs.crud) {
|
||||
this.$refs.crud.searchReset();
|
||||
} else {
|
||||
this.onLoad(this.page, this.query);
|
||||
}
|
||||
this.drawer = true;
|
||||
},
|
||||
/*单行取消*/
|
||||
rowDel(row) {
|
||||
const h = this.$createElement;
|
||||
this.$confirm(
|
||||
h("div", null, [
|
||||
h("p", { style: "font-size: 16px" }, "您确定要取消录用该人员吗? "),
|
||||
]),
|
||||
{
|
||||
type: "warning",
|
||||
showClose: false,
|
||||
showCancelButton: true,
|
||||
confirmButtonText: "确定",
|
||||
cancelButtonText: "取消",
|
||||
beforeClose: (action, instance, done) => {
|
||||
if (action === "confirm") {
|
||||
instance.confirmButtonLoading = true;
|
||||
instance.cancelButtonLoading = true;
|
||||
instance.closeOnPressEscape = false;
|
||||
instance.closeOnClickModal = false;
|
||||
setTimeout(() => {
|
||||
done();
|
||||
setTimeout(() => {
|
||||
instance.confirmButtonLoading = false;
|
||||
instance.cancelButtonLoading = false;
|
||||
}, 300);
|
||||
}, 1000);
|
||||
} else {
|
||||
done();
|
||||
}
|
||||
},
|
||||
}
|
||||
)
|
||||
.then(() => {
|
||||
cancelEmploy(this.missionId, row.id).then(
|
||||
() => {
|
||||
this.$message({
|
||||
type: "success",
|
||||
message: "操作成功!",
|
||||
});
|
||||
this.onLoad(this.page);
|
||||
this.$emit("refresh");
|
||||
},
|
||||
(error) => {
|
||||
window.console.log(error);
|
||||
}
|
||||
);
|
||||
})
|
||||
.catch(() => {
|
||||
});
|
||||
},
|
||||
searchReset() {
|
||||
this.query = {
|
||||
status: this.query.status,
|
||||
};
|
||||
this.onLoad(this.page, this.query);
|
||||
},
|
||||
searchChange(params, done) {
|
||||
this.page.currentPage = 1;
|
||||
this.query = {
|
||||
realName: params.realName,
|
||||
groupId: params.groupId,
|
||||
status: this.query.status,
|
||||
worktypes: params.worktypes,
|
||||
};
|
||||
this.onLoad(this.page, this.query);
|
||||
done();
|
||||
},
|
||||
currentChange(currentPage) {
|
||||
this.page.currentPage = currentPage;
|
||||
},
|
||||
sizeChange(pageSize) {
|
||||
this.page.pageSize = pageSize;
|
||||
},
|
||||
/*刷新本页 带搜索参数*/
|
||||
refreshChange() {
|
||||
this.onLoad(this.page);
|
||||
},
|
||||
/*加载数据*/
|
||||
onLoad(page, params) {
|
||||
getConfig().then((res)=>{
|
||||
this.getUserConfig = res.data.data;
|
||||
});
|
||||
this.loading = true;
|
||||
let paramscur = params ? Object.assign(params, this.query) : this.query;
|
||||
employList(
|
||||
page.currentPage,
|
||||
page.pageSize,
|
||||
paramscur,
|
||||
this.missionId
|
||||
).then((res) => {
|
||||
const data = res.data.data;
|
||||
this.page.total = data.total;
|
||||
this.data=data.records;
|
||||
// if(this.getUserConfig.insuranceOn == 1){
|
||||
// this.data.forEach((ele)=>{
|
||||
// if(!ele.effect){
|
||||
// ele.noSelection = 1;
|
||||
// }
|
||||
// })
|
||||
// }
|
||||
|
||||
this.loading = false;
|
||||
/*let datas = data.records;
|
||||
datas.forEach((ele,index)=>{
|
||||
isGenerateContract(ele.userId,ele.missionNo).then((res) => {
|
||||
datas[index].successFlag = res.data.data;
|
||||
})
|
||||
})
|
||||
setTimeout(()=>{
|
||||
this.data = datas;
|
||||
this.loading = false;
|
||||
},1000)
|
||||
*/
|
||||
//this.selectionClear();
|
||||
});
|
||||
|
||||
},
|
||||
/*返回首页*/
|
||||
backIndex() {
|
||||
this.$emit("refresh");
|
||||
},
|
||||
forgetPwd(){
|
||||
this.phone=this.userInfo.account;
|
||||
var pat=/(\d{3})\d*(\d{4})/;
|
||||
this.phone=this.phone.replace(pat,'$1****$2');
|
||||
this.resetPwdDialogVisible=true;
|
||||
this.resetPwdForm={};
|
||||
},
|
||||
/*获取验证码*/
|
||||
getCode() {
|
||||
this.msgKey = true;
|
||||
this.msgText = "发送中...";
|
||||
getCode(this.userInfo.account)
|
||||
.then(() => {
|
||||
this.msgText = "剩余" + 120 + "s";
|
||||
this.msgKey = true;
|
||||
const time = setInterval(() => {
|
||||
this.msgTime--;
|
||||
this.msgText = "剩余" + this.msgTime + "s";
|
||||
if (this.msgTime <= 0) {
|
||||
this.msgTime = 120;
|
||||
this.msgText = "重新获取";
|
||||
this.msgKey = false;
|
||||
clearInterval(time);
|
||||
}
|
||||
}, 1000);
|
||||
})
|
||||
.catch(() => {
|
||||
this.msgText = "重新获取";
|
||||
this.msgKey = false;
|
||||
});
|
||||
|
||||
},
|
||||
/*重置密码*/
|
||||
submitResetPwd() {
|
||||
this.$refs.resetPwdForm.validate(valid => {
|
||||
if (valid) {
|
||||
resetPwd(this.userInfo.account,this.resetPwdForm.pwd,this.resetPwdForm.code).then(()=>{
|
||||
this.$message.success('密码重置成功');
|
||||
this.resetPwdDialogVisible=false;
|
||||
})
|
||||
.catch((err)=>{
|
||||
this.$message.error(err);
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<style>
|
||||
.selectBtn{
|
||||
color: #787879 !important;
|
||||
}
|
||||
.selectBtn:hover{
|
||||
color: #787879 !important;
|
||||
}
|
||||
.tipsWrap{
|
||||
font-size: 14px;
|
||||
color: #ff0000;
|
||||
position: absolute;
|
||||
top: 26px;
|
||||
left: 120px;
|
||||
}
|
||||
.employ-employNum-count{
|
||||
color: #2098ee;
|
||||
}
|
||||
.employ-forgetPwd{
|
||||
float: right;
|
||||
margin-top: -33px;
|
||||
}
|
||||
</style>
|
||||
@@ -1,495 +0,0 @@
|
||||
<template>
|
||||
<basic-container>
|
||||
<el-drawer
|
||||
title="专属人才推荐"
|
||||
append-to-body
|
||||
:visible.sync="drawer"
|
||||
size="60%"
|
||||
class="drawer"
|
||||
>
|
||||
<avue-crud
|
||||
:option="personListOption"
|
||||
:table-loading="loading"
|
||||
:data="data"
|
||||
:page.sync="page"
|
||||
ref="crud"
|
||||
:permission="permissionList"
|
||||
@search-change="searchChange"
|
||||
@search-reset="searchReset"
|
||||
@selection-change="selectionChange"
|
||||
@current-change="currentChange"
|
||||
@size-change="sizeChange"
|
||||
@refresh-change="refreshChange"
|
||||
class="customPage"
|
||||
@on-load="onLoad"
|
||||
>
|
||||
<!--自定义列-->
|
||||
<template slot="resume" slot-scope="{ row }">
|
||||
<div>
|
||||
<el-button
|
||||
type="text"
|
||||
@click="$refs.resume.openDialog(row)"
|
||||
v-if="row.userId && row.userId !== '0'"
|
||||
>查看简历</el-button
|
||||
>
|
||||
<div v-else>暂无简历</div>
|
||||
</div>
|
||||
</template>
|
||||
<template slot="recommend" slot-scope="{ row }">
|
||||
<div>
|
||||
<el-button
|
||||
type="primary"
|
||||
size="mini"
|
||||
icon="el-icon-plus"
|
||||
@click="rowRecommend(row)"
|
||||
v-if="row.isApply === 0 && row.telphone != ''"
|
||||
>邀请</el-button
|
||||
>
|
||||
<!-- v-show="row.isApply === 1 && row.telphone == ''" -->
|
||||
<el-button
|
||||
type="info"
|
||||
disabled
|
||||
size="mini"
|
||||
icon="el-icon-plus"
|
||||
|
||||
v-else
|
||||
style="margin-left: 0px"
|
||||
>邀请</el-button
|
||||
>
|
||||
|
||||
<!-- <el-button type="primary" size="mini" disabled v-show="row.count>=2">已邀请</el-button> -->
|
||||
</div>
|
||||
</template>
|
||||
<template slot="count" slot-scope="{ row }">{{
|
||||
2 - row.count
|
||||
}}</template>
|
||||
<!--自定义按钮-->
|
||||
<template slot="menuLeft">
|
||||
<el-button
|
||||
type="primary"
|
||||
size="small"
|
||||
:disabled="!selectionList.length"
|
||||
icon="el-icon-plus"
|
||||
@click="handleRecommend"
|
||||
>批量邀请</el-button
|
||||
>
|
||||
</template>
|
||||
<template slot="menuRight">
|
||||
<el-button
|
||||
type="primary"
|
||||
size="small"
|
||||
@click="handleExport"
|
||||
>导出</el-button
|
||||
>
|
||||
</template>
|
||||
<template v-slot:idNumber="{row}">
|
||||
<span>{{idNumberDDesensitization(row.idNumber)}}</span>
|
||||
</template>
|
||||
<template slot="name" slot-scope="{row}">
|
||||
<span v-if="row.status==1">{{row.name}}</span>
|
||||
<span v-else>{{row.name}}(<span style="color: red;">未实名</span>)</span>
|
||||
|
||||
</template>
|
||||
<!--/自定义按钮-->
|
||||
</avue-crud>
|
||||
<Resume ref="resume"></Resume>
|
||||
</el-drawer>
|
||||
</basic-container>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getCommendList, inviteCount,inviteUser,recommendExportList } from "@/api/tenant/postzp";
|
||||
import Resume from "@/components/resume/index";
|
||||
import { mapGetters } from "vuex";
|
||||
import { idNumberDDesensitization } from "@/util/util";
|
||||
|
||||
export default {
|
||||
data () {
|
||||
return {
|
||||
isIndeterminate: false,
|
||||
checkAll: false,
|
||||
checked: false,
|
||||
missionId: "",
|
||||
missionTitle: "",
|
||||
stime: "",
|
||||
drawer: false,
|
||||
selectionList: [],
|
||||
loading: false,
|
||||
query: {},
|
||||
page: {
|
||||
pageSize: 100,
|
||||
currentPage: 1,
|
||||
total: 0,
|
||||
},
|
||||
personListOption: {
|
||||
height: "auto",
|
||||
dialogWidth: "30%",
|
||||
align: "center",
|
||||
menuAlign: "center",
|
||||
rowKey: "id",
|
||||
tip: false,
|
||||
menu: false,
|
||||
addBtn: false,
|
||||
columnBtn: false,
|
||||
searchBtn: true,
|
||||
searchShow: true,
|
||||
searchMenuSpan: 6,
|
||||
searchLabelWidth: 60,
|
||||
menuPosition: "center",
|
||||
labelPosition: "right",
|
||||
border: true,
|
||||
index: true,
|
||||
indexLabel: "序号",
|
||||
selection: true,
|
||||
selectable: function (row) {
|
||||
return row.isApply === 0;
|
||||
},
|
||||
viewBtn: false,
|
||||
dialogType: "dialog",
|
||||
dialogClickModal: false,
|
||||
column: [
|
||||
{
|
||||
label: "姓名",
|
||||
prop: "name",
|
||||
search: true,
|
||||
span: 24,
|
||||
width:155,
|
||||
rules: [
|
||||
{
|
||||
required: true,
|
||||
whitespace: true,
|
||||
message: "请输入姓名",
|
||||
trigger: "blur",
|
||||
},
|
||||
],
|
||||
slot:true,
|
||||
},
|
||||
{
|
||||
label: "性别",
|
||||
prop: "sex",
|
||||
search: false,
|
||||
span: 24,
|
||||
dicData: [
|
||||
{
|
||||
label: "男",
|
||||
value: 1,
|
||||
},
|
||||
{
|
||||
label: "女",
|
||||
value: 2,
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
label: "年龄",
|
||||
prop: "age",
|
||||
search: false,
|
||||
span: 24,
|
||||
},
|
||||
{
|
||||
label: "身份证",
|
||||
prop: "idNumber",
|
||||
search: false,
|
||||
span: 24,
|
||||
width:150,
|
||||
slot: true
|
||||
},
|
||||
{
|
||||
label: "工种",
|
||||
type: "tree",
|
||||
prop: "worktypes",
|
||||
multiple: true,
|
||||
dicUrl: `/api/jobslink-api/tenant/worktypes/base/list`,
|
||||
dicFormatter: (res) => {
|
||||
return res.data; //返回字典的层级结构
|
||||
},
|
||||
props: {
|
||||
label: "name",
|
||||
value: "name",
|
||||
},
|
||||
search: true,
|
||||
span: 24,
|
||||
},
|
||||
{
|
||||
label: "人才库",
|
||||
prop: "groupId",
|
||||
type: "tree",
|
||||
span: 24,
|
||||
search: true,
|
||||
display: true,
|
||||
width: '150',
|
||||
dicUrl: `/api/jobslink-api/tenant/talents/group/listAll`,
|
||||
dicFormatter: (res) => {
|
||||
return res.data.list; //返回字典的层级结构
|
||||
},
|
||||
props: {
|
||||
label: "groupName",
|
||||
value: "id",
|
||||
},
|
||||
placeholder: "请选择分组",
|
||||
},
|
||||
// {
|
||||
// label: "简历",
|
||||
// prop: "resume",
|
||||
// slot: true,
|
||||
// display: false
|
||||
// },
|
||||
{
|
||||
label: "剩余邀请次数",
|
||||
prop: "count",
|
||||
slot: true,
|
||||
width: 150,
|
||||
},
|
||||
{
|
||||
label: "操作",
|
||||
prop: "recommend",
|
||||
slot: true,
|
||||
},
|
||||
|
||||
],
|
||||
},
|
||||
excelBox: false,
|
||||
data: [],
|
||||
};
|
||||
},
|
||||
components: {
|
||||
Resume,
|
||||
},
|
||||
watch: {},
|
||||
computed: {
|
||||
...mapGetters(["userInfo", "permission"]),
|
||||
// permissionList() {
|
||||
// return {
|
||||
// addBtn: this.vaildData(this.permission.user_add, false),
|
||||
// viewBtn: this.vaildData(this.permission.user_view, false),
|
||||
// delBtn: this.vaildData(this.permission.user_delete, false),
|
||||
// editBtn: this.vaildData(this.permission.user_edit, false)
|
||||
// };
|
||||
// },
|
||||
ids () {
|
||||
let ids = [];
|
||||
this.selectionList.forEach((ele) => {
|
||||
ids.push(ele.userId);
|
||||
});
|
||||
return ids.join(",");
|
||||
},
|
||||
phones () {
|
||||
let phones = [];
|
||||
this.selectionList.forEach((ele) => {
|
||||
phones.push(ele.telphone);
|
||||
});
|
||||
return phones.join(",");
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
idNumberDDesensitization,
|
||||
//导出
|
||||
handleExport(){
|
||||
window.open(recommendExportList(this.missionId,this.query.name?this.query.name:"",this.query.worktypes?this.query.worktypes:"",this.query.groupId?this.query.groupId:""));
|
||||
},
|
||||
/*打开drawer*/
|
||||
openDialog (row) {
|
||||
this.missionId = row.missionNo;
|
||||
this.missionTitle = row.missionTitle;
|
||||
this.stime = row.stime;
|
||||
if (this.$refs.crud) {
|
||||
this.$refs.crud.searchReset();
|
||||
} else {
|
||||
this.query = {};
|
||||
this.onLoad(this.page, this.query);
|
||||
}
|
||||
this.drawer = true;
|
||||
},
|
||||
/*邀请人才 */
|
||||
rowRecommend (row) {
|
||||
const h = this.$createElement;
|
||||
let count = 2 - row.count;
|
||||
this.$confirm(
|
||||
h("div", null, [
|
||||
h(
|
||||
"p",
|
||||
{ style: "font-size: 16px" },
|
||||
"您确定要向" + row.name + "发送邀请吗? "
|
||||
),
|
||||
h(
|
||||
"p",
|
||||
{ style: "color: red" },
|
||||
"每个人最多邀请2次,还剩" + count + "次"
|
||||
),
|
||||
]),
|
||||
{
|
||||
type: "warning",
|
||||
showClose: false,
|
||||
showCancelButton: true,
|
||||
confirmButtonText: "确定",
|
||||
cancelButtonText: "取消",
|
||||
beforeClose: (action, instance, done) => {
|
||||
if (action === "confirm") {
|
||||
instance.confirmButtonLoading = true;
|
||||
instance.cancelButtonLoading = true;
|
||||
instance.closeOnPressEscape = false;
|
||||
instance.closeOnClickModal = false;
|
||||
setTimeout(() => {
|
||||
done();
|
||||
setTimeout(() => {
|
||||
instance.confirmButtonLoading = false;
|
||||
instance.cancelButtonLoading = false;
|
||||
}, 300);
|
||||
}, 1000);
|
||||
} else {
|
||||
done();
|
||||
}
|
||||
},
|
||||
}
|
||||
)
|
||||
.then(() => {
|
||||
let rows = [];
|
||||
rows.push({
|
||||
idNumber: row.idNumber,
|
||||
missionNo: this.missionId,
|
||||
missionTitle: this.missionTitle,
|
||||
telphone: row.telphone,
|
||||
});
|
||||
inviteUser(rows).then(
|
||||
() => {
|
||||
this.$message({
|
||||
type: "success",
|
||||
message: "操作成功!",
|
||||
});
|
||||
this.onLoad(this.page);
|
||||
},
|
||||
(error) => {
|
||||
window.console.log(error);
|
||||
}
|
||||
);
|
||||
})
|
||||
.catch(() => {
|
||||
// this.$message({
|
||||
// type: 'info',
|
||||
// message: '已取消'
|
||||
// });
|
||||
});
|
||||
},
|
||||
/*批量邀请人才*/
|
||||
handleRecommend () {
|
||||
if (this.selectionList.length === 0) {
|
||||
this.$message.warning("请选择至少一条数据");
|
||||
return;
|
||||
}
|
||||
const h = this.$createElement;
|
||||
this.$confirm(
|
||||
h("div", null, [
|
||||
h("p", { style: "font-size: 16px" }, "您确定要批量发送邀请吗? "),
|
||||
h("p", { style: "color: red" }, "每个人最多邀请2次"),
|
||||
]),
|
||||
{
|
||||
type: "warning",
|
||||
showClose: false,
|
||||
showCancelButton: true,
|
||||
confirmButtonText: "确定",
|
||||
cancelButtonText: "取消",
|
||||
beforeClose: (action, instance, done) => {
|
||||
if (action === "confirm") {
|
||||
instance.confirmButtonLoading = true;
|
||||
instance.cancelButtonLoading = true;
|
||||
instance.closeOnPressEscape = false;
|
||||
instance.closeOnClickModal = false;
|
||||
setTimeout(() => {
|
||||
done();
|
||||
setTimeout(() => {
|
||||
instance.confirmButtonLoading = false;
|
||||
instance.cancelButtonLoading = false;
|
||||
}, 300);
|
||||
}, 1000);
|
||||
} else {
|
||||
done();
|
||||
}
|
||||
},
|
||||
}
|
||||
)
|
||||
.then(() => {
|
||||
let rows = [];
|
||||
this.selectionList.forEach((ele) => {
|
||||
rows.push({
|
||||
idNumber: ele.idNumber,
|
||||
missionNo: this.missionId,
|
||||
missionTitle: this.missionTitle,
|
||||
telphone: ele.telphone,
|
||||
});
|
||||
});
|
||||
inviteUser(rows).then(
|
||||
() => {
|
||||
this.$message({
|
||||
type: "success",
|
||||
message: "操作成功!",
|
||||
});
|
||||
this.onLoad(this.page);
|
||||
},
|
||||
(error) => {
|
||||
window.console.log(error);
|
||||
}
|
||||
);
|
||||
})
|
||||
.catch(() => {
|
||||
// this.$message({
|
||||
// type: 'info',
|
||||
// message: '已取消'
|
||||
// });
|
||||
});
|
||||
},
|
||||
searchReset () {
|
||||
this.query = {};
|
||||
this.onLoad(this.page);
|
||||
},
|
||||
searchChange (params, done) {
|
||||
this.query = params;
|
||||
this.page.currentPage = 1;
|
||||
this.onLoad(this.page, this.query);
|
||||
done();
|
||||
},
|
||||
selectionChange (list) {
|
||||
this.selectionList = list;
|
||||
},
|
||||
selectionClear () {
|
||||
this.selectionList = [];
|
||||
this.$refs.crud.toggleSelection();
|
||||
},
|
||||
currentChange (currentPage) {
|
||||
this.page.currentPage = currentPage;
|
||||
this.onLoad(this.page);
|
||||
},
|
||||
sizeChange (pageSize) {
|
||||
this.page.currentPage = 1;
|
||||
this.page.pageSize = pageSize;
|
||||
this.onLoad(this.page);
|
||||
},
|
||||
refreshChange () {
|
||||
this.onLoad(this.page, this.query);
|
||||
},
|
||||
onLoad (page, params = {}) {
|
||||
this.loading = true;
|
||||
getCommendList(
|
||||
page.currentPage,
|
||||
page.pageSize,
|
||||
Object.assign(params, this.query),
|
||||
this.missionId
|
||||
).then((res) => {
|
||||
const data = res.data.data;
|
||||
this.page.total = data.total;
|
||||
this.data = data.records;
|
||||
if (this.data.length > 0) {
|
||||
for (let i = 0; i < this.data.length; i++) {
|
||||
inviteCount(this.data[i].idNumber, this.missionId).then((res) => {
|
||||
this.$set(this.data[i], "count", res.data.data.count); //count为已邀请次数 2-count为剩余邀请次数
|
||||
this.$set(this.data[i], "isApply", res.data.data.isApply); //isApply===0 可邀请,===1不可邀请
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
this.loading = false;
|
||||
this.selectionClear();
|
||||
});
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
@@ -1,293 +0,0 @@
|
||||
<template>
|
||||
<div>
|
||||
<el-tag
|
||||
class="skill-select-tag"
|
||||
:key="tag.id"
|
||||
v-for="tag in selectedSkills"
|
||||
:disable-transitions="true"
|
||||
size="medium"
|
||||
>{{ tag.name }}</el-tag
|
||||
>
|
||||
<el-button
|
||||
v-if="canSelect"
|
||||
class="button-new-tag"
|
||||
size="small"
|
||||
@click="showSelect"
|
||||
:disabled="!this.id"
|
||||
>+ 选择技能</el-button
|
||||
>
|
||||
<el-dialog
|
||||
title="技能标签"
|
||||
:visible.sync="dialogVisible"
|
||||
width="30%"
|
||||
:close-on-click-modal="false"
|
||||
:close-on-press-escape="false"
|
||||
:append-to-body="true"
|
||||
v-loading="loading"
|
||||
>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<div>
|
||||
<el-tag
|
||||
class="skill-select-tag"
|
||||
:key="tag.id"
|
||||
v-for="(tag, index) in tobeSelectedSkills"
|
||||
closable
|
||||
type="primary"
|
||||
:disable-transitions="true"
|
||||
@close="removeSkill(index)"
|
||||
size="medium"
|
||||
>{{ tag.name }}</el-tag
|
||||
>
|
||||
</div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
||||
<div>请选择或者添加您所需的技能标签(最多5个)</div>
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<div class="autocompleteBox">
|
||||
<el-autocomplete
|
||||
popper-class="my-autocomplete"
|
||||
v-model.trim="search"
|
||||
:fetch-suggestions="querySearch"
|
||||
placeholder="请选择行业类型"
|
||||
@select="handleSelect"
|
||||
maxlength="15"
|
||||
show-word-limit
|
||||
>
|
||||
<el-button
|
||||
type="primary"
|
||||
:disabled = "addBtnState"
|
||||
slot="suffix"
|
||||
@click="handleIconClick"
|
||||
size="mini"
|
||||
>+添加</el-button>
|
||||
<!-- <i class="el-icon-arrow-down" slot="suffix" @click="handleIconClickArrowDown"></i> -->
|
||||
<template slot-scope="{ item }">
|
||||
<div class="name">{{item.value}}</div>
|
||||
</template>
|
||||
</el-autocomplete>
|
||||
|
||||
</div>
|
||||
|
||||
<!-- <el-autocomplete
|
||||
v-model="search"
|
||||
:fetch-suggestions="querySearch"
|
||||
:trigger-on-focus="false"
|
||||
placeholder="搜索您想要的标签"
|
||||
@select="editSkill"
|
||||
style="width: 100%"
|
||||
:validate-event="false"
|
||||
>
|
||||
<template slot-scope="{ item }">
|
||||
<div>{{ item.name }}</div>
|
||||
</template>
|
||||
</el-autocomplete> -->
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
||||
<el-row>
|
||||
<el-col :span="24">
|
||||
<div>
|
||||
<a
|
||||
class="skill-select-tag"
|
||||
href="javascript:void(0)"
|
||||
v-for="tag in allSkill"
|
||||
:key="tag.id"
|
||||
@click="editSkill(tag)"
|
||||
>
|
||||
<el-tag
|
||||
type="info"
|
||||
:disable-transitions="true"
|
||||
size="medium"
|
||||
effect="plain"
|
||||
>{{ tag.name }}</el-tag
|
||||
>
|
||||
</a>
|
||||
</div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button
|
||||
icon="el-icon-circle-plus-outline"
|
||||
type="primary"
|
||||
@click="submit"
|
||||
>保 存</el-button
|
||||
>
|
||||
<el-button icon="el-icon-circle-close" @click="dialogVisible = false"
|
||||
>取 消</el-button
|
||||
>
|
||||
</span>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getSkillList } from "@/api/tenant/common";
|
||||
import {skillListAdd} from "@/api/tenant/postzp";
|
||||
import _ from "lodash";
|
||||
|
||||
export default {
|
||||
name: "skillSelect",
|
||||
props: {
|
||||
selectedSkills: Array,
|
||||
canSelect: Boolean,
|
||||
id: String,
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
search: "",
|
||||
loading: false,
|
||||
dialogVisible: false,
|
||||
tobeSelectedSkills: [],
|
||||
allSkill: [],
|
||||
flags:true,
|
||||
addBtnState:true,
|
||||
nameAttr:[]
|
||||
};
|
||||
},
|
||||
created() {
|
||||
},
|
||||
computed: {},
|
||||
watch: {
|
||||
id: function (val, oldVal) {
|
||||
if (val !== oldVal && oldVal) {
|
||||
this.$emit("add-skill", []);
|
||||
}
|
||||
},
|
||||
search:function(n,o){
|
||||
if((n || o!='') && this.tobeSelectedSkills.length != 0){
|
||||
this.$emit('clear-validator');
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
//获取技能列表
|
||||
getData() {
|
||||
if (this.id) {
|
||||
this.loading = true;
|
||||
getSkillList(this.id).then((res) => {
|
||||
this.allSkill = res.data.data.records;
|
||||
this.nameAttr = this.allSkill.map((ele)=>{
|
||||
return ele.name
|
||||
})
|
||||
this.loading = false;
|
||||
});
|
||||
}
|
||||
},
|
||||
handleSelect(item) {
|
||||
this.addBtnState = true;
|
||||
// console(item);
|
||||
this.editSkill(item);
|
||||
},
|
||||
querySearch(queryString, cb) {
|
||||
let results = [];
|
||||
let nameState = this.nameAttr.indexOf(queryString);
|
||||
if(nameState == -1){
|
||||
this.addBtnState = false;
|
||||
}else{
|
||||
this.addBtnState = true;
|
||||
}
|
||||
for(let i of this.allSkill){
|
||||
i.value = i.name;
|
||||
}
|
||||
results = queryString ? this.allSkill.filter(this.createStateFilter(queryString)) : this.allSkill;
|
||||
cb(results);
|
||||
},
|
||||
createStateFilter(queryString) {
|
||||
return (state) => {
|
||||
return (state.value.toLowerCase().indexOf(queryString.toLowerCase()) === 0);
|
||||
};
|
||||
},
|
||||
handleIconClick() {
|
||||
let nameState = this.nameAttr.indexOf(this.search)
|
||||
if(this.search == ""){
|
||||
this.$message.closeAll()
|
||||
this.$message({
|
||||
type: "error",
|
||||
message: "请输入要添加的技能!",
|
||||
})
|
||||
}else if(nameState != -1){
|
||||
this.$message({
|
||||
type: "error",
|
||||
message: "此技能已存在,请在列表中选择!",
|
||||
})
|
||||
}else{
|
||||
skillListAdd(this.id,this.search).then((res) =>{
|
||||
if(res.data.code == 200){
|
||||
//this.search = res.data.data;
|
||||
this.$message({
|
||||
type: "success",
|
||||
message: res.data.msg,
|
||||
})
|
||||
this.addBtnState = true;
|
||||
this.getData();
|
||||
}else{
|
||||
this.$message({
|
||||
type: "error",
|
||||
message: res.data.msg,
|
||||
})
|
||||
}
|
||||
});
|
||||
}
|
||||
},
|
||||
/*技能*/
|
||||
editSkill(tag) {
|
||||
if (this.tobeSelectedSkills.length < 5) {
|
||||
if (
|
||||
this.tobeSelectedSkills.find((item) => {
|
||||
return item.id === tag.id;
|
||||
})
|
||||
) {
|
||||
if(!this.flags){
|
||||
this.$message({
|
||||
message: "您已添加该技能标签",
|
||||
type: "warning",
|
||||
});
|
||||
this.flags=true;
|
||||
}
|
||||
|
||||
} else {
|
||||
this.tobeSelectedSkills.push(tag);
|
||||
this.$emit('clear-validator');
|
||||
this.flags=false;
|
||||
}
|
||||
} else {
|
||||
this.$message({
|
||||
message: "最多添加5个技能标签",
|
||||
type: "warning",
|
||||
});
|
||||
}
|
||||
},
|
||||
removeSkill(index) {
|
||||
this.tobeSelectedSkills.splice(index, 1);
|
||||
},
|
||||
submit() {
|
||||
if (this.tobeSelectedSkills.length) {
|
||||
this.dialogVisible = false;
|
||||
this.$emit("add-skill", this.tobeSelectedSkills);
|
||||
} else {
|
||||
this.$message.closeAll();
|
||||
this.$message({
|
||||
message: "请至少选择一个技能标签",
|
||||
type: "warning",
|
||||
});
|
||||
}
|
||||
},
|
||||
showSelect() {
|
||||
this.tobeSelectedSkills = _.cloneDeep(this.selectedSkills || []);
|
||||
this.getData();
|
||||
this.dialogVisible = true;
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
<style scoped>
|
||||
.skill-select-tag {
|
||||
margin: 0px 5px;
|
||||
}
|
||||
.autocompleteBox .el-autocomplete{
|
||||
width:100%;
|
||||
}
|
||||
</style>
|
||||
@@ -1,212 +0,0 @@
|
||||
<template>
|
||||
<basic-container>
|
||||
<el-drawer
|
||||
title="比对结果"
|
||||
append-to-body
|
||||
:visible.sync="drawer"
|
||||
size="65%"
|
||||
class="drawer"
|
||||
>
|
||||
<avue-crud
|
||||
:option="personListOption"
|
||||
:table-loading="loading"
|
||||
:data="data"
|
||||
:page.sync="page"
|
||||
ref="crud"
|
||||
:permission="permissionList"
|
||||
@search-change="searchChange"
|
||||
@search-reset="searchReset"
|
||||
@selection-change="selectionChange"
|
||||
@current-change="currentChange"
|
||||
@size-change="sizeChange"
|
||||
@refresh-change="refreshChange"
|
||||
class="customPage"
|
||||
>
|
||||
<!--/自定义按钮-->
|
||||
<template slot="menuRight">
|
||||
<el-button
|
||||
type="primary"
|
||||
size="small"
|
||||
@click="handleExport"
|
||||
>导出</el-button
|
||||
>
|
||||
</template>
|
||||
<template v-slot:idNumber="{row}">
|
||||
<span>{{idNumberDDesensitization(row.idNumber)}}</span>
|
||||
</template>
|
||||
</avue-crud>
|
||||
</el-drawer>
|
||||
</basic-container>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import {userLists,userListsExport} from "@/api/tenant/postzp";
|
||||
// import Resume from "@/components/resume/index";
|
||||
import { mapGetters } from "vuex";
|
||||
import { idNumberDDesensitization } from "@/util/util";
|
||||
|
||||
export default {
|
||||
data () {
|
||||
return {
|
||||
isIndeterminate: false,
|
||||
checkAll: false,
|
||||
checked: false,
|
||||
missionId: "",
|
||||
missionTitle: "",
|
||||
stime: "",
|
||||
drawer: false,
|
||||
selectionList: [],
|
||||
loading: false,
|
||||
query: {},
|
||||
id:null,
|
||||
page: {
|
||||
pageSize: 10,
|
||||
currentPage: 1,
|
||||
total: 0,
|
||||
},
|
||||
personListOption: {
|
||||
dialogWidth: "30%",
|
||||
align: "center",
|
||||
menuAlign: "center",
|
||||
rowKey: "id",
|
||||
tip: false,
|
||||
menu: false,
|
||||
addBtn: false,
|
||||
columnBtn: false,
|
||||
searchBtn: true,
|
||||
searchShow: true,
|
||||
searchMenuSpan: 6,
|
||||
searchLabelWidth: 45,
|
||||
menuPosition: "center",
|
||||
labelPosition: "right",
|
||||
border: true,
|
||||
index: true,
|
||||
indexLabel: "序号",
|
||||
viewBtn: false,
|
||||
dialogType: "dialog",
|
||||
dialogClickModal: false,
|
||||
column: [
|
||||
{
|
||||
label: "姓名",
|
||||
prop: "name",
|
||||
search: false,
|
||||
},
|
||||
{
|
||||
label: "性别",
|
||||
prop: "sex",
|
||||
search: false,
|
||||
width: 50,
|
||||
},
|
||||
{
|
||||
label: "年龄",
|
||||
prop: "age",
|
||||
search: false,
|
||||
width: 50,
|
||||
},
|
||||
{
|
||||
label: "身份证",
|
||||
prop: "idNumber",
|
||||
search: false,
|
||||
width: 150,
|
||||
slot: true
|
||||
},
|
||||
{
|
||||
label: "联系方式",
|
||||
prop: "telphone",
|
||||
search: false,
|
||||
width: 120,
|
||||
},
|
||||
{
|
||||
label: "工种",
|
||||
prop: "worktypeName",
|
||||
search: false,
|
||||
},
|
||||
{
|
||||
label: "人才库",
|
||||
prop: "groupName",
|
||||
search: false,
|
||||
},
|
||||
// {
|
||||
// label: "操作",
|
||||
// prop: "recommend",
|
||||
// slot: true,
|
||||
// },
|
||||
],
|
||||
},
|
||||
excelBox: false,
|
||||
data: [],
|
||||
};
|
||||
},
|
||||
components: {
|
||||
// Resume,
|
||||
},
|
||||
watch: {},
|
||||
computed: {
|
||||
...mapGetters(["userInfo", "permission"]),
|
||||
ids () {
|
||||
let ids = [];
|
||||
this.selectionList.forEach((ele) => {
|
||||
ids.push(ele.userId);
|
||||
});
|
||||
return ids.join(",");
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
idNumberDDesensitization,
|
||||
//导出
|
||||
handleExport(){
|
||||
window.open(userListsExport(this.missionId, this.id));
|
||||
},
|
||||
/*打开drawer*/
|
||||
openDialog (missionId,ids) {
|
||||
this.missionId = missionId;
|
||||
this.id = ids;
|
||||
this.ids = ids;
|
||||
this.onLoad(this.page, this.query);
|
||||
this.drawer = true;
|
||||
},
|
||||
/*批量选择*/
|
||||
// handleChoice () {
|
||||
|
||||
// },
|
||||
searchReset () {
|
||||
this.query = {};
|
||||
this.onLoad(this.page);
|
||||
},
|
||||
searchChange (params, done) {
|
||||
this.query = params;
|
||||
this.page.currentPage = 1;
|
||||
this.onLoad(this.page, this.query);
|
||||
done();
|
||||
},
|
||||
selectionChange (list) {
|
||||
this.selectionList = list;
|
||||
},
|
||||
selectionClear () {
|
||||
this.selectionList = [];
|
||||
this.$refs.crud.toggleSelection();
|
||||
},
|
||||
currentChange (currentPage) {
|
||||
this.page.currentPage = currentPage;
|
||||
this.onLoad(this.page);
|
||||
},
|
||||
sizeChange (pageSize) {
|
||||
this.page.currentPage = 1;
|
||||
this.page.pageSize = pageSize;
|
||||
this.onLoad(this.page);
|
||||
},
|
||||
refreshChange () {
|
||||
this.onLoad(this.page, this.query);
|
||||
},
|
||||
onLoad () {
|
||||
this.loading = true;
|
||||
userLists(this.missionId, this.id).then((res) => {
|
||||
const data = res.data.data;
|
||||
this.data = data;
|
||||
this.loading = false;
|
||||
this.selectionClear();
|
||||
});
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
@@ -1,360 +0,0 @@
|
||||
<template>
|
||||
<div>
|
||||
<avue-crud
|
||||
:option="option"
|
||||
:table-loading="loading"
|
||||
:data="data"
|
||||
ref="crud"
|
||||
v-model="obj"
|
||||
@row-del="rowDel"
|
||||
@row-update="rowUpdate"
|
||||
@row-save="rowSave"
|
||||
:before-open="beforeOpen"
|
||||
:page.sync="page"
|
||||
@current-change="currentChange"
|
||||
@size-change="sizeChange"
|
||||
@refresh-change="refreshChange"
|
||||
@on-load="onLoad"
|
||||
>
|
||||
<!--自定义列-->
|
||||
<template slot="missionTitle" slot-scope="{ row }">
|
||||
<el-tooltip effect="dark" :content="row.missionTitle" placement="top">
|
||||
<div style="color: black">
|
||||
<b>{{ row.missionTitle | ellipsis }}</b>
|
||||
</div>
|
||||
</el-tooltip>
|
||||
</template>
|
||||
<!-- 开始日期 -->
|
||||
<template slot="stime" slot-scope="{row}">
|
||||
<span>{{format(row.stime)}}</span>
|
||||
</template>
|
||||
<!-- 完成日期 -->
|
||||
<template slot="etime" slot-scope="{row}">
|
||||
<span>{{format(row.etime)}}</span>
|
||||
</template>
|
||||
<template slot="signUpCount" slot-scope="{ row }">
|
||||
<div style="color: #409eff">
|
||||
<b>{{ row.signUpCount }}人</b>
|
||||
</div>
|
||||
</template>
|
||||
<template slot="takeOnCount" slot-scope="{ row }">
|
||||
<div style="color: #409eff">
|
||||
<b>{{ row.takeOnCount }}人</b>
|
||||
</div>
|
||||
</template>
|
||||
<template slot="missionDate" slot-scope="{ row }">
|
||||
<div>{{ format(row.stime) }}至{{ format(row.etime) }}</div>
|
||||
</template>
|
||||
|
||||
<!--/自定义列-->
|
||||
<!--自定义操作栏-->
|
||||
<div slot="menu" slot-scope="{size,type,row}">
|
||||
<!-- <el-button
|
||||
icon="el-icon-view"
|
||||
:size="size"
|
||||
:type="type"
|
||||
@click="rowView(row);"
|
||||
v-show="vaildData(permission.tenant_mission_view,false)"
|
||||
>查看</el-button>-->
|
||||
<el-button
|
||||
icon="el-icon-check"
|
||||
:size="size"
|
||||
:type="type"
|
||||
@click="rowCopy(row, 'copy')"
|
||||
v-show="vaildData(permission.tenant_mission_add, false)"
|
||||
>复制</el-button>
|
||||
<el-button
|
||||
icon="el-icon-delete"
|
||||
:size="size"
|
||||
:type="type"
|
||||
@click="$refs.crud.rowDel(row)"
|
||||
v-show="vaildData(permission.tenant_mission_delete, false)"
|
||||
>删除</el-button>
|
||||
</div>
|
||||
<!--/自定义操作栏-->
|
||||
<!--自定义按钮-->
|
||||
<template slot="menuLeft">
|
||||
<el-button
|
||||
type="warning"
|
||||
plain
|
||||
icon="el-icon-plus"
|
||||
size="small"
|
||||
@click="rowCopy('', 'add')"
|
||||
v-show="vaildData(permission.tenant_mission_add, false)"
|
||||
>发布岗位</el-button>
|
||||
</template>
|
||||
<!--/自定义按钮-->
|
||||
</avue-crud>
|
||||
<copy-mission ref="copy" @back="backIndex" v-show="false"></copy-mission>
|
||||
<!--查看dialog-->
|
||||
<mission-view :visible.sync="viewDrawer" :model="view"></mission-view>
|
||||
<!--/查看dialog-->
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getExpiredList, remove, detail } from "@/api/tenant/postzp";
|
||||
import CopyMission from "../Dialog/CopyMission";
|
||||
import SkillSelect from "../Dialog/Skill";
|
||||
import missionView from "./missionView.vue";
|
||||
import SelectMap from "@/components/map/selectLocation";
|
||||
import { mapGetters } from "vuex";
|
||||
import { dateFormat } from "@/util/date";
|
||||
import saveButton from "./saveButton";
|
||||
|
||||
export default {
|
||||
comments: {},
|
||||
filters: {
|
||||
ellipsis (value) {
|
||||
if (!value) return "";
|
||||
if (value.length > 15) {
|
||||
return value.slice(0, 14) + "...";
|
||||
}
|
||||
return value;
|
||||
},
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
viewDrawer: false,
|
||||
view: {},
|
||||
loading: false,
|
||||
isCanEdit: false,
|
||||
selectedSkills: [],
|
||||
tradeData: [],
|
||||
page: {
|
||||
pageSize: 20,
|
||||
currentPage: 1,
|
||||
total: 0,
|
||||
},
|
||||
query: {},
|
||||
data: [],
|
||||
obj: {},
|
||||
wageUnitCategory: [
|
||||
{
|
||||
value: 0,
|
||||
label: "元/人·次",
|
||||
},
|
||||
{
|
||||
value: 1,
|
||||
label: "元/人·时",
|
||||
},
|
||||
{
|
||||
value: 2,
|
||||
label: "元/人·天",
|
||||
},
|
||||
{
|
||||
value: 3,
|
||||
label: "元/人·周",
|
||||
},
|
||||
{
|
||||
value: 4,
|
||||
label: "元/人·月",
|
||||
},
|
||||
{
|
||||
value: 5,
|
||||
label: "元/人·个",
|
||||
},
|
||||
{
|
||||
value: 6,
|
||||
label: "元/人·件",
|
||||
},
|
||||
],
|
||||
};
|
||||
},
|
||||
components: {
|
||||
CopyMission,
|
||||
SkillSelect,
|
||||
SelectMap,
|
||||
missionView,
|
||||
saveButton,
|
||||
},
|
||||
created () { },
|
||||
computed: {
|
||||
...mapGetters(["permission"]),
|
||||
option () {
|
||||
return {
|
||||
height: "auto",
|
||||
calcHeight: 40,
|
||||
align: "center",
|
||||
menuAlign: "center",
|
||||
tip: false,
|
||||
addBtn: false,
|
||||
viewBtn: false,
|
||||
editBtn: false,
|
||||
delBtn: false,
|
||||
excelBtn: false,
|
||||
columnBtn: false,
|
||||
searchBtn: false,
|
||||
searchShow: false,
|
||||
labelWidth: 100,
|
||||
border: true,
|
||||
index: false,
|
||||
selection: false,
|
||||
dialogType: "drawer",
|
||||
dialogWidth: "60%",
|
||||
dialogClickModal: false,
|
||||
column: [
|
||||
{
|
||||
label: "岗位名称",
|
||||
prop: "missionTitle",
|
||||
slot: true,
|
||||
display: false,
|
||||
},
|
||||
{
|
||||
label: "岗位编码",
|
||||
prop: "missionNo",
|
||||
display: false,
|
||||
},
|
||||
{
|
||||
label: "开始时间",
|
||||
prop: "stime",
|
||||
display: false,
|
||||
width: 130,
|
||||
slot:true
|
||||
},
|
||||
{
|
||||
label: "完成时间",
|
||||
prop: "etime",
|
||||
display: false,
|
||||
width: 130,
|
||||
slot:true
|
||||
},
|
||||
// {
|
||||
// label: "岗位时间",
|
||||
// prop: "missionDate",
|
||||
// slot: true,
|
||||
// display: false,
|
||||
// width: 200,
|
||||
// },
|
||||
{
|
||||
label: "申请人数",
|
||||
prop: "signUpCount",
|
||||
slot: true,
|
||||
display: false,
|
||||
},
|
||||
{
|
||||
label: "录用人数",
|
||||
prop: "takeOnCount",
|
||||
slot: true,
|
||||
display: false,
|
||||
},
|
||||
{
|
||||
label: "备注",
|
||||
prop: "remarks",
|
||||
display: false,
|
||||
},
|
||||
],
|
||||
};
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
format (date) {
|
||||
if (date) {
|
||||
return dateFormat(new Date(date), "yyyy/MM/dd");
|
||||
}
|
||||
},
|
||||
/*查看*/
|
||||
rowView (row) {
|
||||
detail(row.missionNo).then((res) => {
|
||||
this.viewDrawer = true;
|
||||
this.view = res;
|
||||
});
|
||||
},
|
||||
/*打开新建 复制*/
|
||||
rowCopy (row, type) {
|
||||
this.$refs.copy.onLoad(row, type);
|
||||
this.$nextTick(()=>{
|
||||
this.$refs.copy.resetFields();//等弹窗里的form表单的dom渲染完在执行this.$refs.staffForm.resetFields(),去除验证
|
||||
})
|
||||
},
|
||||
/*删除岗位*/
|
||||
rowDel (row) {
|
||||
const h = this.$createElement;
|
||||
this.$confirm(
|
||||
h("div", null, [
|
||||
h("p", { style: "font-size: 16px" }, "您确定要删除此岗位吗? "),
|
||||
h("p", { style: "color: red" }, "一旦删除则无法找回"),
|
||||
]),
|
||||
{
|
||||
type: "warning",
|
||||
showClose: false,
|
||||
showCancelButton: true,
|
||||
confirmButtonText: "确定",
|
||||
cancelButtonText: "取消",
|
||||
beforeClose: (action, instance, done) => {
|
||||
if (action === "confirm") {
|
||||
instance.confirmButtonLoading = true;
|
||||
instance.cancelButtonLoading = true;
|
||||
instance.closeOnPressEscape = false;
|
||||
instance.closeOnClickModal = false;
|
||||
setTimeout(() => {
|
||||
done();
|
||||
setTimeout(() => {
|
||||
instance.confirmButtonLoading = false;
|
||||
instance.cancelButtonLoading = false;
|
||||
}, 300);
|
||||
}, 1000);
|
||||
} else {
|
||||
done();
|
||||
}
|
||||
},
|
||||
}
|
||||
)
|
||||
.then(() => {
|
||||
remove(row.id).then(
|
||||
() => {
|
||||
this.$message({
|
||||
type: "success",
|
||||
message: "操作成功!",
|
||||
});
|
||||
this.onLoad(this.page, this.query);
|
||||
},
|
||||
(error) => {
|
||||
window.console.log(error);
|
||||
}
|
||||
);
|
||||
})
|
||||
.catch(() => {
|
||||
// this.$message({
|
||||
// type: 'info',
|
||||
// message: '已取消'
|
||||
// });
|
||||
});
|
||||
},
|
||||
currentChange (currentPage) {
|
||||
this.page.currentPage = currentPage;
|
||||
},
|
||||
sizeChange (pageSize) {
|
||||
this.page.pageSize = pageSize;
|
||||
},
|
||||
/*刷新本页 带搜索参数*/
|
||||
refreshChange () {
|
||||
this.onLoad(this.page, this.query);
|
||||
},
|
||||
/*加载数据*/
|
||||
onLoad (page, params = {}) {
|
||||
this.loading = true;
|
||||
getExpiredList(
|
||||
page.currentPage,
|
||||
page.pageSize,
|
||||
Object.assign(this.query, params)
|
||||
).then((res) => {
|
||||
const data = res.data.data;
|
||||
this.page.total = data.total;
|
||||
this.data = data.records;
|
||||
this.loading = false;
|
||||
});
|
||||
},
|
||||
/*返回首页*/
|
||||
backIndex () {
|
||||
this.$emit("refresh");
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
<style scoped>
|
||||
.el-col,
|
||||
.el-form-item {
|
||||
margin-bottom: 0px;
|
||||
}
|
||||
</style>
|
||||
@@ -1,334 +0,0 @@
|
||||
<template>
|
||||
<div>
|
||||
<avue-crud
|
||||
:option="option"
|
||||
:table-loading="loading"
|
||||
:data="data"
|
||||
ref="crud"
|
||||
v-model="obj"
|
||||
@row-del="rowDel"
|
||||
@row-update="rowUpdate"
|
||||
@row-save="rowSave"
|
||||
:before-open="beforeOpen"
|
||||
:page.sync="page"
|
||||
@current-change="currentChange"
|
||||
@size-change="sizeChange"
|
||||
@refresh-change="refreshChange"
|
||||
@on-load="onLoad"
|
||||
>
|
||||
<!--自定义列-->
|
||||
<template slot="missionTitle" slot-scope="{ row }">
|
||||
<el-tooltip effect="dark" :content="row.missionTitle" placement="top">
|
||||
<div style="color: black">
|
||||
<b>{{ row.missionTitle | ellipsis }}</b>
|
||||
</div>
|
||||
</el-tooltip>
|
||||
</template>
|
||||
<template slot="takeOnCount" slot-scope="{ row }">
|
||||
<div style="color: #409eff;cursor: pointer;" @click="employmentNum(row)">
|
||||
<b>{{ row.takeOnCount }}人</b>
|
||||
</div>
|
||||
</template>
|
||||
<!-- 开始日期 -->
|
||||
<template slot="stime" slot-scope="{row}">
|
||||
<span>{{format(row.stime)}}</span>
|
||||
</template>
|
||||
<!-- 完成日期 -->
|
||||
<template slot="etime" slot-scope="{row}">
|
||||
<span>{{format(row.etime)}}</span>
|
||||
</template>
|
||||
<template slot="toPayEnd" slot-scope="{ row }">
|
||||
<div v-if="row.toPayEnd < 0" style="color: #f56c6c">
|
||||
<i class="el-icon-warning-outline"></i>
|
||||
<span>已逾期,不再提供支付服务</span>
|
||||
</div>
|
||||
<div v-if="row.toPayEnd >= 0">
|
||||
<i class="el-icon-warning-outline"></i> 距工资结算剩余
|
||||
<span style="color: #f56c6c">
|
||||
<b>{{ row.toPayEnd }}天</b>
|
||||
</span>
|
||||
</div>
|
||||
</template>
|
||||
<template slot="payCount" slot-scope="{ row }">
|
||||
<div style="">
|
||||
<span>{{ row.payCount }}人</span>
|
||||
</div>
|
||||
</template>
|
||||
<template slot="missionDate" slot-scope="{ row }">
|
||||
<div>{{ format(row.stime) }}至{{ format(row.etime) }}</div>
|
||||
</template>
|
||||
<template slot="expiryTime" slot-scope="{ row }">
|
||||
<div>{{ format(row.expiryTime) }}</div>
|
||||
</template>
|
||||
<!--/自定义列-->
|
||||
<!--自定义按钮-->
|
||||
<template slot="menuLeft">
|
||||
<save-button
|
||||
type="warning"
|
||||
plain
|
||||
icon="el-icon-plus"
|
||||
size="small"
|
||||
@click="rowCopy('', 'add')"
|
||||
v-show="vaildData(permission.tenant_mission_add, false)"
|
||||
>发布岗位</save-button>
|
||||
</template>
|
||||
<!--/自定义按钮-->
|
||||
<!--自定义操作栏-->
|
||||
<div slot="menu" slot-scope="{ size, type, row }">
|
||||
<el-button
|
||||
:size="size"
|
||||
:type="type"
|
||||
@click="appraise(row)"
|
||||
v-show="vaildData(permission.tenant_mission_appraise,false)"
|
||||
>评价</el-button>
|
||||
<!-- <el-button
|
||||
icon="el-icon-view"
|
||||
:size="size"
|
||||
:type="type"
|
||||
@click="rowView(row);"
|
||||
v-show="vaildData(permission.tenant_mission_view,false)"
|
||||
>查看</el-button>-->
|
||||
<el-button
|
||||
icon="el-icon-check"
|
||||
:size="size"
|
||||
:type="type"
|
||||
@click="rowCopy(row, 'copy')"
|
||||
v-show="vaildData(permission.tenant_mission_add, false)"
|
||||
>复制</el-button>
|
||||
</div>
|
||||
<!--/自定义操作栏-->
|
||||
</avue-crud>
|
||||
<!--复制dialog-->
|
||||
<copy-mission ref="copy" @back="backIndex" v-show="false"></copy-mission>
|
||||
<!--/复制dialog-->
|
||||
<!--评价dialog-->
|
||||
<Appraise ref="appraise" v-show="false"></Appraise>
|
||||
<!--评价dialog-->
|
||||
<!--录用人员dialog-->
|
||||
<Employ ref="employ" :status="status" v-show="false"></Employ>
|
||||
<employment-num ref="employmentNumber" :status="1" v-show="false"></employment-num>
|
||||
<!--查看dialog-->
|
||||
<mission-view :visible.sync="viewDrawer" :model="view"></mission-view>
|
||||
<!--/查看dialog-->
|
||||
<!--录用人员dialog-->
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getList, detail, getWagePerson } from "@/api/tenant/postzp";
|
||||
import CopyMission from "../Dialog/CopyMission";
|
||||
import Appraise from "../Dialog/Appraise";
|
||||
import Employ from "../Dialog/Employ";
|
||||
import SkillSelect from "../Dialog/Skill";
|
||||
import missionView from "./missionView.vue";
|
||||
import employmentNum from "../Dialog/EmployNumber";
|
||||
import SelectMap from "@/components/map/selectLocation";
|
||||
import { mapGetters } from "vuex";
|
||||
import { dateFormat } from "@/util/date";
|
||||
import saveButton from "./saveButton";
|
||||
|
||||
export default {
|
||||
filters: {
|
||||
ellipsis (value) {
|
||||
if (!value) return "";
|
||||
if (value.length > 15) {
|
||||
return value.slice(0, 14) + "...";
|
||||
}
|
||||
return value;
|
||||
},
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
viewDrawer: false,
|
||||
view: {},
|
||||
status: 3,
|
||||
loading: false,
|
||||
page: {
|
||||
pageSize: 20,
|
||||
currentPage: 1,
|
||||
total: 0,
|
||||
},
|
||||
query: {
|
||||
status: 3,
|
||||
},
|
||||
data: [],
|
||||
obj: {},
|
||||
};
|
||||
},
|
||||
components: {
|
||||
CopyMission,
|
||||
Appraise,
|
||||
Employ,
|
||||
SkillSelect,
|
||||
SelectMap,
|
||||
missionView,
|
||||
saveButton,
|
||||
employmentNum
|
||||
},
|
||||
created () { },
|
||||
computed: {
|
||||
...mapGetters(["permission"]),
|
||||
option () {
|
||||
return {
|
||||
height: "auto",
|
||||
calcHeight: 40,
|
||||
align: "center",
|
||||
menuAlign: "center",
|
||||
tip: false,
|
||||
addBtn: false,
|
||||
viewBtn: false,
|
||||
editBtn: false,
|
||||
delBtn: false,
|
||||
excelBtn: false,
|
||||
columnBtn: false,
|
||||
searchBtn: false,
|
||||
searchShow: false,
|
||||
labelWidth: 100,
|
||||
border: true,
|
||||
index: false,
|
||||
selection: false,
|
||||
dialogType: "drawer",
|
||||
dialogWidth: "60%",
|
||||
delBtnText: "取消",
|
||||
dialogClickModal: false,
|
||||
column: [
|
||||
{
|
||||
label: "岗位名称",
|
||||
prop: "missionTitle",
|
||||
display: false,
|
||||
slot: true,
|
||||
},
|
||||
{
|
||||
label: "岗位编码",
|
||||
prop: "missionNo",
|
||||
display: false,
|
||||
},
|
||||
// {
|
||||
// label: "岗位时间",
|
||||
// prop: "missionDate",
|
||||
// slot: true,
|
||||
// display: false,
|
||||
// width: 200,
|
||||
// },
|
||||
{
|
||||
label: "开始日期",
|
||||
prop: "stime",
|
||||
display: false,
|
||||
width: 130,
|
||||
slot:true
|
||||
},
|
||||
{
|
||||
label: "完成日期",
|
||||
prop: "etime",
|
||||
display: false,
|
||||
width: 130,
|
||||
slot:true
|
||||
},
|
||||
{
|
||||
label: "录用人数",
|
||||
prop: "takeOnCount",
|
||||
slot: true,
|
||||
display: false,
|
||||
width: 130,
|
||||
},
|
||||
{
|
||||
label: "已发工资人数",
|
||||
prop: "payCount",
|
||||
slot: true,
|
||||
display: false,
|
||||
width: 130,
|
||||
},
|
||||
{
|
||||
label: "发工资截止日期",
|
||||
prop: "expiryTime",
|
||||
slot: true,
|
||||
display: false,
|
||||
width: 160,
|
||||
format: "yyyy-MM-dd",
|
||||
},
|
||||
{
|
||||
label: "提示",
|
||||
prop: "toPayEnd",
|
||||
slot: true,
|
||||
display: false,
|
||||
width: 200,
|
||||
},
|
||||
],
|
||||
};
|
||||
},
|
||||
},
|
||||
watch: {},
|
||||
methods: {
|
||||
format (date) {
|
||||
if (date) {
|
||||
return dateFormat(new Date(date), "yyyy/MM/dd");
|
||||
}
|
||||
},
|
||||
// 录用人数
|
||||
employmentNum(row){
|
||||
this.$refs.employmentNumber.openDialog(row, 2);//查看已录用人员
|
||||
},
|
||||
/*查看*/
|
||||
rowView (row) {
|
||||
detail(row.id).then((res) => {
|
||||
this.viewDrawer = true;
|
||||
this.view = res;
|
||||
});
|
||||
},
|
||||
/*打开录用人员*/
|
||||
employ (row, state) {
|
||||
this.$refs.employ.openDialog(row, state);
|
||||
},
|
||||
/*打开复制*/
|
||||
rowCopy (row, type) {
|
||||
this.$refs.copy.onLoad(row, type);
|
||||
},
|
||||
/*打开评价*/
|
||||
appraise (row) {
|
||||
this.$refs.appraise.openDialog(row);
|
||||
},
|
||||
currentChange (currentPage) {
|
||||
this.page.currentPage = currentPage;
|
||||
},
|
||||
sizeChange (pageSize) {
|
||||
this.page.pageSize = pageSize;
|
||||
},
|
||||
/*刷新本页 带搜索参数*/
|
||||
refreshChange () {
|
||||
this.onLoad(this.page, this.query);
|
||||
},
|
||||
/*加载数据*/
|
||||
onLoad (page, params = {}) {
|
||||
this.loading = true;
|
||||
getList(
|
||||
page.currentPage,
|
||||
page.pageSize,
|
||||
Object.assign(this.query, params)
|
||||
).then((res) => {
|
||||
const data = res.data.data;
|
||||
this.page.total = data.total;
|
||||
let data1 = data.records;
|
||||
if (data1.length > 0) {
|
||||
for (let i = 0; i < data1.length; i++) {
|
||||
getWagePerson(data1[i].missionNo).then((res) => {
|
||||
data1[i]["payCount"] = res.data.data;
|
||||
});
|
||||
}
|
||||
}
|
||||
this.data = data1;
|
||||
this.loading = false;
|
||||
});
|
||||
},
|
||||
/*返回首页*/
|
||||
backIndex () {
|
||||
this.$emit("refresh");
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
<style scoped>
|
||||
.el-col,
|
||||
.el-form-item {
|
||||
margin-bottom: 0px;
|
||||
}
|
||||
</style>
|
||||
@@ -1,354 +0,0 @@
|
||||
<template>
|
||||
<div>
|
||||
<avue-crud
|
||||
:option="option"
|
||||
:table-loading="loading"
|
||||
:data="data"
|
||||
v-model="obj"
|
||||
ref="crud"
|
||||
@row-del="rowDel"
|
||||
@row-update="rowUpdate"
|
||||
@row-save="rowSave"
|
||||
:before-open="beforeOpen"
|
||||
:page.sync="page"
|
||||
@current-change="currentChange"
|
||||
@size-change="sizeChange"
|
||||
@refresh-change="refreshChange"
|
||||
@on-load="onLoad"
|
||||
>
|
||||
<!--自定义列-->
|
||||
<template slot="missionTitle" slot-scope="{ row }">
|
||||
<el-tooltip effect="dark" :content="row.missionTitle" placement="top">
|
||||
<div style="color: black">
|
||||
<b>{{ row.missionTitle | ellipsis }}</b>
|
||||
</div>
|
||||
</el-tooltip>
|
||||
</template>
|
||||
<!-- 开始日期 -->
|
||||
<template slot="stime" slot-scope="{row}">
|
||||
<span>{{format(row.stime)}}</span>
|
||||
</template>
|
||||
<!-- 完成日期 -->
|
||||
<template slot="etime" slot-scope="{row}">
|
||||
<span>{{format(row.etime)}}</span>
|
||||
</template>
|
||||
<template slot="takeOnCount" slot-scope="{ row }">
|
||||
<div style="color: #409eff; cursor: pointer;" @click="employmentNum(row)">
|
||||
<b>{{ row.takeOnCount }}人</b>
|
||||
</div>
|
||||
</template>
|
||||
<template slot="toEnd" slot-scope="{ row }">
|
||||
<div>
|
||||
<i class="el-icon-warning-outline"></i> 距岗位结束剩余
|
||||
<span style="color: #f56c6c">
|
||||
<b>{{ row.toEnd }}天</b>
|
||||
</span>
|
||||
</div>
|
||||
</template>
|
||||
<template slot="missionDate" slot-scope="{ row }">
|
||||
<div>{{ format(row.stime) }}至{{ format(row.etime) }}</div>
|
||||
</template>
|
||||
|
||||
<!--/自定义列-->
|
||||
<!--自定义按钮-->
|
||||
<template slot="menuLeft">
|
||||
<save-button
|
||||
type="warning"
|
||||
plain
|
||||
icon="el-icon-plus"
|
||||
size="small"
|
||||
@click="rowCopy('', 'add')"
|
||||
v-show="vaildData(permission.tenant_mission_add, false)"
|
||||
>发布岗位</save-button
|
||||
>
|
||||
</template>
|
||||
<!--/自定义按钮-->
|
||||
<!--自定义操作栏-->
|
||||
<div slot="menu" slot-scope="{ size, type, row }">
|
||||
<save-button
|
||||
:size="size"
|
||||
:type="type"
|
||||
@click="rowComplete(row)"
|
||||
v-show="vaildData(permission.tenant_mission_finish, false)"
|
||||
>完成岗位</save-button
|
||||
>
|
||||
<el-button
|
||||
icon="el-icon-view"
|
||||
:size="size"
|
||||
:type="type"
|
||||
@click="rowView(row)"
|
||||
v-show="vaildData(permission.tenant_mission_view, false)"
|
||||
>查看</el-button
|
||||
>
|
||||
<save-button
|
||||
icon="el-icon-check"
|
||||
:size="size"
|
||||
:type="type"
|
||||
@click="rowCopy(row, 'copy')"
|
||||
v-show="vaildData(permission.tenant_mission_add, false)"
|
||||
>复制</save-button
|
||||
>
|
||||
</div>
|
||||
<!--/自定义操作栏-->
|
||||
</avue-crud>
|
||||
<!--复制dialog-->
|
||||
<copy-mission ref="copy" @back="backIndex" v-show="false"></copy-mission>
|
||||
<!--复制dialog-->
|
||||
<!--录用人员dialog-->
|
||||
<Employ ref="employ" :status="status" v-show="false"></Employ>
|
||||
<!-- 录用人数 -->
|
||||
<employment-num
|
||||
ref="employmentNum"
|
||||
:status="1"
|
||||
v-show="false"
|
||||
></employment-num>
|
||||
<!--录用人员dialog-->
|
||||
<!--查看dialog-->
|
||||
<mission-view :visible.sync="viewDrawer" :model="view"></mission-view>
|
||||
<!--/查看dialog-->
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getList, complete, detail } from "@/api/tenant/postzp";
|
||||
import CopyMission from "../Dialog/CopyMission";
|
||||
import SkillSelect from "../Dialog/Skill";
|
||||
import Employ from "../Dialog/Employ";
|
||||
import missionView from "./missionView.vue";
|
||||
import SelectMap from "@/components/map/selectLocation";
|
||||
import employmentNum from "../Dialog/EmployNumber";
|
||||
import { mapGetters } from "vuex";
|
||||
import { dateFormat } from "@/util/date";
|
||||
import saveButton from "./saveButton";
|
||||
|
||||
export default {
|
||||
comments: {
|
||||
|
||||
},
|
||||
filters: {
|
||||
ellipsis(value) {
|
||||
if (!value) return "";
|
||||
if (value.length > 15) {
|
||||
return value.slice(0, 14) + "...";
|
||||
}
|
||||
return value;
|
||||
},
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
viewDrawer: false,
|
||||
view: {},
|
||||
status: 2,
|
||||
loading: false,
|
||||
page: {
|
||||
pageSize: 20,
|
||||
currentPage: 1,
|
||||
total: 0,
|
||||
},
|
||||
query: {
|
||||
status: 2,
|
||||
},
|
||||
data: [],
|
||||
obj: {},
|
||||
};
|
||||
},
|
||||
components: {
|
||||
CopyMission,
|
||||
SkillSelect,
|
||||
Employ,
|
||||
SelectMap,
|
||||
missionView,
|
||||
saveButton,
|
||||
employmentNum
|
||||
},
|
||||
created() {},
|
||||
computed: {
|
||||
...mapGetters(["permission"]),
|
||||
option() {
|
||||
return {
|
||||
height: "auto",
|
||||
calcHeight: 40,
|
||||
align: "center",
|
||||
menuAlign: "center",
|
||||
tip: false,
|
||||
addBtn: false,
|
||||
viewBtn: false,
|
||||
editBtn: false,
|
||||
delBtn: false,
|
||||
excelBtn: false,
|
||||
columnBtn: false,
|
||||
searchBtn: false,
|
||||
searchShow: false,
|
||||
labelWidth: 100,
|
||||
border: true,
|
||||
index: false,
|
||||
selection: false,
|
||||
dialogType: "drawer",
|
||||
dialogWidth: "60%",
|
||||
delBtnText: "取消",
|
||||
dialogClickModal: false,
|
||||
column: [
|
||||
{
|
||||
label: "岗位名称",
|
||||
prop: "missionTitle",
|
||||
display: false,
|
||||
slot: true,
|
||||
},
|
||||
{
|
||||
label: "岗位编码",
|
||||
prop: "missionNo",
|
||||
display: false,
|
||||
},
|
||||
// {
|
||||
// label: "岗位时间",
|
||||
// prop: "missionDate",
|
||||
// slot: true,
|
||||
// display: false,
|
||||
// width: 200,
|
||||
// },
|
||||
{
|
||||
label: "开始时间",
|
||||
prop: "stime",
|
||||
display: false,
|
||||
width: 130,
|
||||
slot: true,
|
||||
},
|
||||
{
|
||||
label: "完成时间",
|
||||
prop: "etime",
|
||||
display: false,
|
||||
width: 130,
|
||||
slot: true,
|
||||
},
|
||||
{
|
||||
label: "录用人数",
|
||||
prop: "takeOnCount",
|
||||
slot: true,
|
||||
display: false,
|
||||
},
|
||||
{
|
||||
label: "提示",
|
||||
prop: "toEnd",
|
||||
slot: true,
|
||||
display: false,
|
||||
},
|
||||
],
|
||||
};
|
||||
},
|
||||
},
|
||||
watch: {},
|
||||
methods: {
|
||||
format(date) {
|
||||
if (date) {
|
||||
return dateFormat(new Date(date), "yyyy/MM/dd");
|
||||
}
|
||||
},
|
||||
// 录用人数
|
||||
employmentNum(row){
|
||||
this.$refs.employmentNum.openDialog(row, 2);//查看已录用人员
|
||||
},
|
||||
/*查看*/
|
||||
rowView(row) {
|
||||
detail(row.id).then((res) => {
|
||||
this.viewDrawer = true;
|
||||
this.view = res;
|
||||
});
|
||||
},
|
||||
/*打开复制*/
|
||||
rowCopy(row, type) {
|
||||
this.$refs.copy.onLoad(row, type);
|
||||
},
|
||||
/*打开录用人员*/
|
||||
employ(row, state) {
|
||||
this.$refs.employ.openDialog(row, state);
|
||||
},
|
||||
/*完成岗位*/
|
||||
rowComplete(row) {
|
||||
const h = this.$createElement;
|
||||
this.$confirm(
|
||||
h("div", null, [
|
||||
h("p", { style: "font-size: 16px" }, "您确定此岗位已经完成吗? "),
|
||||
]),
|
||||
{
|
||||
type: "warning",
|
||||
showClose: false,
|
||||
showCancelButton: true,
|
||||
confirmButtonText: "确定",
|
||||
cancelButtonText: "取消",
|
||||
beforeClose: (action, instance, done) => {
|
||||
if (action === "confirm") {
|
||||
instance.confirmButtonLoading = true;
|
||||
instance.cancelButtonLoading = true;
|
||||
instance.closeOnPressEscape = false;
|
||||
instance.closeOnClickModal = false;
|
||||
setTimeout(() => {
|
||||
done();
|
||||
setTimeout(() => {
|
||||
instance.confirmButtonLoading = false;
|
||||
instance.cancelButtonLoading = false;
|
||||
}, 300);
|
||||
}, 1000);
|
||||
} else {
|
||||
done();
|
||||
}
|
||||
},
|
||||
}
|
||||
)
|
||||
.then(() => {
|
||||
complete(row.id).then(
|
||||
() => {
|
||||
this.$message({
|
||||
type: "success",
|
||||
message: "操作成功!",
|
||||
});
|
||||
this.onLoad(this.page, this.query);
|
||||
},
|
||||
(error) => {
|
||||
window.console.log(error);
|
||||
}
|
||||
);
|
||||
})
|
||||
.catch(() => {
|
||||
// this.$message({
|
||||
// type: 'info',
|
||||
// message: '已取消'
|
||||
// });
|
||||
});
|
||||
},
|
||||
currentChange(currentPage) {
|
||||
this.page.currentPage = currentPage;
|
||||
},
|
||||
sizeChange(pageSize) {
|
||||
this.page.pageSize = pageSize;
|
||||
},
|
||||
/*刷新本页 带搜索参数*/
|
||||
refreshChange() {
|
||||
this.onLoad(this.page, this.query);
|
||||
},
|
||||
/*加载数据*/
|
||||
onLoad(page, params = {}) {
|
||||
this.loading = true;
|
||||
getList(
|
||||
page.currentPage,
|
||||
page.pageSize,
|
||||
Object.assign(this.query, params)
|
||||
).then((res) => {
|
||||
const data = res.data.data;
|
||||
this.page.total = data.total;
|
||||
this.data = data.records;
|
||||
this.loading = false;
|
||||
});
|
||||
},
|
||||
/*返回首页*/
|
||||
backIndex() {
|
||||
this.$emit("refresh");
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
<style scoped>
|
||||
.el-col,
|
||||
.el-form-item {
|
||||
margin-bottom: 0px;
|
||||
}
|
||||
</style>
|
||||
@@ -1,498 +0,0 @@
|
||||
<template>
|
||||
<div>
|
||||
<avue-crud :option="option" :table-loading="loading" :data="data" ref="crud" v-model="obj" @row-del="rowDel"
|
||||
@row-update="rowUpdate" @row-save="rowSave" :before-open="beforeOpen" :page.sync="page"
|
||||
@current-change="currentChange" @size-change="sizeChange" @refresh-change="refreshChange" @on-load="onLoad">
|
||||
<!--自定义按钮-->
|
||||
<template slot="menuLeft">
|
||||
<save-button type="warning" plain icon="el-icon-plus" size="small" @click="rowCopy('', 'add')"
|
||||
v-show="vaildData(permission.tenant_mission_add, false)">发布岗位</save-button>
|
||||
<el-button type="success" size="small" plain icon="el-icon-plus" @click="handleImport"
|
||||
v-show="vaildData(permission.tenant_talents_groupadd, false)">导入</el-button>
|
||||
</template>
|
||||
<!--/自定义按钮-->
|
||||
<!--自定义列-->
|
||||
<template slot="missionTitle" slot-scope="{ row }">
|
||||
<el-tooltip effect="dark" :content="row.missionTitle" placement="top">
|
||||
<div style="color: black">
|
||||
<b>{{ row.missionTitle | ellipsis }}</b>
|
||||
</div>
|
||||
</el-tooltip>
|
||||
</template>
|
||||
<template slot="signUpCount" slot-scope="{ row }">
|
||||
<div>
|
||||
<span>{{ row.signUpCount }}人</span>
|
||||
</div>
|
||||
</template>
|
||||
<!-- 报名截止日期 -->
|
||||
<template slot="etimePub" slot-scope="{row}">
|
||||
<span>{{ format(row.etimePub) }}</span>
|
||||
</template>
|
||||
<!-- 开始日期 -->
|
||||
<template slot="stime" slot-scope="{row}">
|
||||
<span>{{ format(row.stime) }}</span>
|
||||
</template>
|
||||
<!-- 完成日期 -->
|
||||
<template slot="etime" slot-scope="{row}">
|
||||
<span>{{ format(row.etime) }}</span>
|
||||
</template>
|
||||
<template slot="takeOnCount" slot-scope="{ row }">
|
||||
<div style="color: #409eff;cursor: pointer;" @click="employmentNum(row)">
|
||||
<b>{{ row.takeOnCount }}人</b>
|
||||
</div>
|
||||
</template>
|
||||
<template slot="toStart" slot-scope="{ row }">
|
||||
<div>
|
||||
<i class="el-icon-warning-outline"></i> 距岗位开始剩余
|
||||
<span style="color: #f56c6c">
|
||||
<b>{{ row.toStart }}天</b>
|
||||
</span>
|
||||
</div>
|
||||
</template>
|
||||
<!--/自定义列-->
|
||||
<!--自定义操作栏-->
|
||||
<div slot="menu" slot-scope="{ size, type, row }">
|
||||
<el-button type="text" size="mini" @click="recommend(row)">人才推荐</el-button>
|
||||
<el-button type="text" size="mini" @click="employ(row, 1)">录用人员</el-button>
|
||||
<el-button icon="el-icon-view" :size="size" :type="type" @click.stop="rowView(row)"
|
||||
v-show="vaildData(permission.tenant_mission_view, false)">查看</el-button>
|
||||
<save-button icon="el-icon-check" :size="size" :type="type" @click="rowCopy(row, 'copy')">复制</save-button>
|
||||
<el-button icon="el-icon-edit" :size="size" :type="type" @click="rowCopy(row, 'edit')" :disabled="false"
|
||||
v-show="vaildData(permission.tenant_mission_edit, false)">编辑</el-button>
|
||||
<el-button icon="el-icon-delete" :size="size" :type="type" @click="$refs.crud.rowDel(row)" :disabled="false"
|
||||
v-show="vaildData(permission.tenant_mission_cancel, false)">取消</el-button>
|
||||
<!-- <el-button type="text" size="mini" @click="contrast(row)"
|
||||
>比对人才库</el-button> -->
|
||||
</div>
|
||||
</avue-crud>
|
||||
<!--发布 复制 编辑dialog-->
|
||||
<copy-mission ref="copy" @back="backIndex" v-show="false"></copy-mission>
|
||||
<!--/发布 复制 编辑dialog-->
|
||||
<!--录用人员dialog-->
|
||||
<Employ ref="employ" @refresh="refreshChange" :status="status" v-show="false"></Employ>
|
||||
<employment-num ref="employmentNum" :status="1" v-show="false"></employment-num>
|
||||
<!--/录用人员dialog-->
|
||||
<!--人才推荐dialog-->
|
||||
<Recommend ref="recommend" v-show="false"></Recommend>
|
||||
<!--/人才推荐dialog-->
|
||||
<!--对比人才库dialog-->
|
||||
<Contrast ref="contrast" v-show="false"></Contrast>
|
||||
<!--对比人才库dialog-->
|
||||
<!--查看dialog-->
|
||||
<mission-view :visible.sync="viewDrawer" :model="view"></mission-view>
|
||||
<!--/查看dialog-->
|
||||
|
||||
<!--批量导入-->
|
||||
<el-dialog title="导入" append-to-body :visible.sync="excelBox" :close-on-click-modal="false" width="555px">
|
||||
<avue-form :option="excelOption" v-model="excelForm" :upload-after="uploadAfter" :upload-before="beforeAvatarUpload"
|
||||
:upload-error="uploadError">
|
||||
<template slot="excelTemplate">
|
||||
<el-button type="primary" @click="handleTemplate()" :loading="templateLoading">
|
||||
点击下载
|
||||
<i class="el-icon-download el-icon--right"></i>
|
||||
</el-button>
|
||||
</template>
|
||||
</avue-form>
|
||||
</el-dialog>
|
||||
<!--/批量导入-->
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getList, cancel, detail ,upload} from "@/api/tenant/postzp";
|
||||
import CopyMission from "../Dialog/CopyMission";
|
||||
import Employ from "../Dialog/Employ";
|
||||
import employmentNum from "../Dialog/EmployNumber";
|
||||
import Recommend from "../Dialog/Recommend";
|
||||
import Contrast from "../Dialog/Contrast"
|
||||
import SkillSelect from "../Dialog/Skill";
|
||||
import missionView from "./missionView.vue";
|
||||
import SelectMap from "@/components/map/selectLocation";
|
||||
import { isExcel } from "@/util/validate";
|
||||
import { excelAccept } from "@/common/accept";
|
||||
import { mapGetters } from "vuex";
|
||||
import { dateFormat } from "@/util/date";
|
||||
import { getTemplate } from "@/api/resource/template";
|
||||
import saveButton from "./saveButton";
|
||||
|
||||
export default {
|
||||
components: {
|
||||
CopyMission,
|
||||
Employ,
|
||||
Recommend,
|
||||
SkillSelect,
|
||||
SelectMap,
|
||||
missionView,
|
||||
saveButton,
|
||||
Contrast,
|
||||
employmentNum
|
||||
},
|
||||
filters: {
|
||||
ellipsis(value) {
|
||||
if (!value) return "";
|
||||
if (value.length > 15) {
|
||||
return value.slice(0, 14) + "...";
|
||||
}
|
||||
return value;
|
||||
},
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
excelBox: false,
|
||||
excelForm: { isCovered: 1 },
|
||||
excelOption: {
|
||||
submitBtn: false,
|
||||
emptyBtn: false,
|
||||
column: [
|
||||
{
|
||||
label: "文件上传",
|
||||
prop: "excelFile",
|
||||
type: "upload",
|
||||
drag: true,
|
||||
loadText: "文件上传中,请稍等",
|
||||
span: 24,
|
||||
propsHttp: {
|
||||
res: "data",
|
||||
},
|
||||
tip: "请上传 .xls,.xlsx 标准格式文件",
|
||||
accept: excelAccept,
|
||||
showFileList: false,
|
||||
action: upload(),
|
||||
},
|
||||
{
|
||||
label: "模板下载",
|
||||
prop: "excelTemplate",
|
||||
formslot: true,
|
||||
span: 24,
|
||||
},
|
||||
],
|
||||
},
|
||||
status: 1,
|
||||
viewDrawer: false,
|
||||
view: {},
|
||||
loading: false,
|
||||
tradeData: [],
|
||||
tradeId: "",
|
||||
page: {
|
||||
pageSize: 20,
|
||||
currentPage: 1,
|
||||
total: 0,
|
||||
},
|
||||
query: {
|
||||
status: 1,
|
||||
},
|
||||
data: [],
|
||||
obj: {},
|
||||
missionNo: '',
|
||||
};
|
||||
},
|
||||
created() { },
|
||||
watch: {},
|
||||
computed: {
|
||||
...mapGetters(["permission"]),
|
||||
/*计算时间*/
|
||||
option() {
|
||||
return {
|
||||
height: "auto",
|
||||
calcHeight: 40,
|
||||
menuWidth: 420,
|
||||
align: "center",
|
||||
menuAlign: "center",
|
||||
tip: false,
|
||||
addBtn: false,
|
||||
viewBtn: false,
|
||||
delBtn: false,
|
||||
editBtn: false,
|
||||
excelBtn: false,
|
||||
columnBtn: false,
|
||||
searchBtn: false,
|
||||
searchShow: false,
|
||||
border: true,
|
||||
index: false,
|
||||
selection: false,
|
||||
dialogType: "drawer",
|
||||
dialogWidth: "60%",
|
||||
delBtnText: "取消",
|
||||
dialogClickModal: false,
|
||||
column: [
|
||||
{
|
||||
label: "岗位名称",
|
||||
prop: "jobName",
|
||||
display: false,
|
||||
slot: true,
|
||||
width: 130,
|
||||
},
|
||||
{
|
||||
label: "岗位编码",
|
||||
prop: "id",
|
||||
width: 180,
|
||||
display: false,
|
||||
},
|
||||
{
|
||||
label: "报名截止日期",
|
||||
prop: "etimePub",
|
||||
display: false,
|
||||
format: "yyyy-MM-dd",
|
||||
width: 130,
|
||||
slot: true,
|
||||
},
|
||||
{
|
||||
label: "开始日期",
|
||||
prop: "stime",
|
||||
display: false,
|
||||
width: 130,
|
||||
slot: true,
|
||||
},
|
||||
{
|
||||
label: "完成日期",
|
||||
prop: "etime",
|
||||
display: false,
|
||||
width: 130,
|
||||
slot: true,
|
||||
},
|
||||
{
|
||||
label: "申请人数",
|
||||
prop: "peopleNum",
|
||||
slot: true,
|
||||
display: false,
|
||||
},
|
||||
{
|
||||
label: "录用人数",
|
||||
prop: "applyNum",
|
||||
slot: true,
|
||||
display: false,
|
||||
},
|
||||
{
|
||||
label: "省市",
|
||||
prop: "province",
|
||||
slot: true,
|
||||
display: false,
|
||||
width: 110,
|
||||
},
|
||||
{
|
||||
label: "岗位状态",
|
||||
prop: "jobStatus",
|
||||
slot: true,
|
||||
display: false,
|
||||
width: 110,
|
||||
dicData: [
|
||||
{
|
||||
label: "在招",
|
||||
value: 1,
|
||||
},
|
||||
{
|
||||
label: "已招",
|
||||
value: 2,
|
||||
},
|
||||
{
|
||||
label: "过期",
|
||||
value: 3,
|
||||
},
|
||||
{
|
||||
label: "未正式发布",
|
||||
value: 4,
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
label: "岗位类型",
|
||||
prop: "worktypeNames",
|
||||
slot: true,
|
||||
display: false,
|
||||
width: 110,
|
||||
},
|
||||
|
||||
// {
|
||||
// label: "提示",
|
||||
// prop: "toStart",
|
||||
// slot: true,
|
||||
// display: false,
|
||||
// width: 200,
|
||||
// },
|
||||
],
|
||||
};
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
format(date) {
|
||||
if (date) {
|
||||
return dateFormat(new Date(date), "yyyy/MM/dd");
|
||||
}
|
||||
},
|
||||
// 录用人数
|
||||
employmentNum(row) {
|
||||
this.$refs.employmentNum.openDialog(row, 2);//查看已录用人员
|
||||
},
|
||||
/*打开新增 复制 编辑*/
|
||||
rowCopy(row, type) {
|
||||
this.$refs.copy.onLoad(row, type);
|
||||
},
|
||||
/*查看*/
|
||||
rowView(row) {
|
||||
detail(row.id).then((res) => {
|
||||
this.viewDrawer = true;
|
||||
this.view = res;
|
||||
});
|
||||
},
|
||||
/*打开录用人员*/
|
||||
employ(row, status) {
|
||||
this.$refs.employ.openDialog(row, status);
|
||||
},
|
||||
/*打开人才推荐*/
|
||||
recommend(row) {
|
||||
this.$refs.recommend.openDialog(row);
|
||||
},
|
||||
/*打开对比人才库*/
|
||||
contrast(row) {
|
||||
this.$refs.contrast.openDialog(row);
|
||||
},
|
||||
/*取消岗位*/
|
||||
rowDel(row) {
|
||||
const h = this.$createElement;
|
||||
this.$confirm(
|
||||
h("div", null, [
|
||||
h("p", { style: "font-size: 16px" }, "您确定要取消此岗位吗? "),
|
||||
h("p", { style: "color: red" }, "一旦取消则岗位失效"),
|
||||
]),
|
||||
{
|
||||
type: "warning",
|
||||
showClose: false,
|
||||
showCancelButton: true,
|
||||
confirmButtonText: "确定",
|
||||
cancelButtonText: "取消",
|
||||
beforeClose: (action, instance, done) => {
|
||||
if (action === "confirm") {
|
||||
instance.confirmButtonLoading = true;
|
||||
instance.cancelButtonLoading = true;
|
||||
instance.closeOnPressEscape = false;
|
||||
instance.closeOnClickModal = false;
|
||||
setTimeout(() => {
|
||||
done();
|
||||
setTimeout(() => {
|
||||
instance.confirmButtonLoading = false;
|
||||
instance.cancelButtonLoading = false;
|
||||
}, 300);
|
||||
}, 1000);
|
||||
} else {
|
||||
done();
|
||||
}
|
||||
},
|
||||
}
|
||||
)
|
||||
.then(() => {
|
||||
cancel(row.id).then(
|
||||
() => {
|
||||
this.$message({
|
||||
type: "success",
|
||||
message: "操作成功!",
|
||||
});
|
||||
this.onLoad(this.page, this.query);
|
||||
},
|
||||
(error) => {
|
||||
window.console.log(error);
|
||||
}
|
||||
);
|
||||
})
|
||||
.catch(() => {
|
||||
// this.$message({
|
||||
// type: 'info',
|
||||
// message: '已取消'
|
||||
// });
|
||||
});
|
||||
},
|
||||
currentChange(currentPage) {
|
||||
this.page.currentPage = currentPage;
|
||||
},
|
||||
sizeChange(pageSize) {
|
||||
this.page.pageSize = pageSize;
|
||||
},
|
||||
/*刷新本页 带搜索参数*/
|
||||
refreshChange() {
|
||||
this.onLoad(this.page, this.query);
|
||||
},
|
||||
/*加载数据*/
|
||||
onLoad(page, params = {}) {
|
||||
this.loading = true;
|
||||
getList(
|
||||
page.currentPage,
|
||||
page.pageSize,
|
||||
Object.assign(this.query, params)
|
||||
).then((res) => {
|
||||
const data = res.data.data;
|
||||
this.page.total = data.total;
|
||||
this.data = data.records;
|
||||
this.loading = false;
|
||||
});
|
||||
},
|
||||
/*返回首页*/
|
||||
backIndex() {
|
||||
this.$emit("refresh");
|
||||
},
|
||||
/*导入任务*/
|
||||
beforeAvatarUpload(file, done, loading) {
|
||||
if (!isExcel(file)) {
|
||||
loading();
|
||||
this.$message.error("上传任务信息只能是 .xls,.xlsx 标准格式文件!");
|
||||
} else {
|
||||
done();
|
||||
}
|
||||
},
|
||||
uploadAfter(res, done) {
|
||||
if (!(res instanceof Error) && !res.data) {
|
||||
this.excelBox = false;
|
||||
} else if (res.data && res.data.code === 900) {
|
||||
const arr = [];
|
||||
const data = res.data.data;
|
||||
data.error &&
|
||||
data.error.errorList.forEach((item) => {
|
||||
arr.push(`${item.name} ${item.remarks}`);
|
||||
});
|
||||
data.auth &&
|
||||
data.auth.authList.forEach((item) => {
|
||||
arr.push(`${item.name} ${item.remarks}`);
|
||||
});
|
||||
this.$refs.ied.show(arr);
|
||||
}
|
||||
this.refreshChange();
|
||||
// this.initDept(this.tenantId);
|
||||
done();
|
||||
},
|
||||
uploadError(error) {
|
||||
if (error) {
|
||||
this.$message.error(error);
|
||||
}
|
||||
},
|
||||
handleImport() {
|
||||
this.excelBox = true;
|
||||
},
|
||||
/*下载任务模板 */
|
||||
handleTemplate() {
|
||||
this.templateLoading = true;
|
||||
getTemplate("trc")
|
||||
.then((rep) => {
|
||||
this.templateLoading = false;
|
||||
window.open(rep.data.data);
|
||||
})
|
||||
.catch(() => {
|
||||
this.templateLoading = false;
|
||||
});
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
<style scoped>
|
||||
.el-col,
|
||||
.el-form-item {
|
||||
margin-bottom: 0px;
|
||||
}
|
||||
|
||||
.map {
|
||||
width: 100%;
|
||||
height: 300px;
|
||||
}
|
||||
</style>
|
||||
<style>
|
||||
.slotForm {
|
||||
font-size: 12px;
|
||||
}
|
||||
</style>
|
||||
@@ -1,35 +0,0 @@
|
||||
<template>
|
||||
<el-drawer title="查看岗位" :visible.sync="viewDrawer" size="60%">
|
||||
<mission-view :model="model"></mission-view>
|
||||
</el-drawer>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import missionView from "@/views/util/mission-view";
|
||||
|
||||
export default {
|
||||
components: { missionView },
|
||||
props: {
|
||||
visible: Boolean,
|
||||
model: {
|
||||
type: Object,
|
||||
default() {
|
||||
return {};
|
||||
},
|
||||
},
|
||||
},
|
||||
computed: {
|
||||
viewDrawer: {
|
||||
get() {
|
||||
return this.visible;
|
||||
},
|
||||
set(val) {
|
||||
this.$emit("update:visible", val);
|
||||
},
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<style>
|
||||
</style>
|
||||
@@ -1,38 +0,0 @@
|
||||
<template>
|
||||
<el-button
|
||||
:plain="plain"
|
||||
:icon="icon"
|
||||
:size="size"
|
||||
:type="type"
|
||||
@click="click"
|
||||
:disabled="disabled"
|
||||
><slot></slot
|
||||
></el-button>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
props: {
|
||||
plain: Boolean,
|
||||
icon: String,
|
||||
size: String,
|
||||
type: String,
|
||||
disabled: Boolean,
|
||||
action: String,
|
||||
data: {
|
||||
type: Object,
|
||||
default() {
|
||||
return {};
|
||||
},
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
click() {
|
||||
this.$emit("click", { row: this.row, action: this.action });
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<style>
|
||||
</style>
|
||||
@@ -1,238 +0,0 @@
|
||||
<template>
|
||||
<basic-container>
|
||||
<!--搜索栏-->
|
||||
<!-- <el-form size="small" label-position="right" :inline="true" style="padding-left: 10px;padding-right: 10px;">
|
||||
<el-row :span="24">
|
||||
<el-form-item label-width="0">
|
||||
<el-select v-model="search.status" placeholder="岗位状态" style="width:100%">
|
||||
<el-option v-for="(item, key, index) in missionTypes" :key="index" :label="item.label"
|
||||
:value="item.value"></el-option>
|
||||
</el-select>
|
||||
<el-radio-group v-model="search.status" size="small">
|
||||
<el-radio-button v-for="(item, key, index) in missionTypes" :key="index" :label="item.value">{{ item.label }}
|
||||
</el-radio-button>
|
||||
</el-radio-group>
|
||||
|
||||
</el-form-item>
|
||||
<el-form-item label="岗位编号:">
|
||||
<el-input v-model="search.missionNo" placeholder="岗位编号" clearable></el-input>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="岗位名称:">
|
||||
<el-input v-model="search.missionTitle" placeholder="岗位名称" clearable></el-input>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="">
|
||||
<el-select v-model="search.state" placeholder="请选择搜索时间类型" style="width: 100%" @change="date">
|
||||
<el-option v-for="(item, key, index) in timeScreenTerm" :key="index" :label="item.label"
|
||||
:value="item.value"></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="">
|
||||
<el-date-picker :disabled="!search.state" v-model="timeValue" type="daterange" range-separator="至"
|
||||
start-placeholder="开始日期" end-placeholder="结束日期" format="yyyy 年 MM 月 dd 日" value-format="yyyy-MM-dd"
|
||||
@change="dateChange">
|
||||
</el-date-picker>
|
||||
</el-form-item>
|
||||
<tool-tip></tool-tip>
|
||||
|
||||
|
||||
<el-form-item label="报名截止时间:">
|
||||
<el-date-picker v-model="endDateRange" type="daterange" range-separator="至" start-placeholder="开始日期"
|
||||
end-placeholder="结束日期" format="yyyy 年 MM 月 dd 日" value-format="yyyy-MM-dd" @change="endDateChange">
|
||||
</el-date-picker>
|
||||
</el-form-item>
|
||||
<el-form-item label="开始时间:">
|
||||
<el-date-picker v-model="beginTimeValue" type="daterange" range-separator="至" start-placeholder="开始日期"
|
||||
end-placeholder="结束日期" format="yyyy 年 MM 月 dd 日" value-format="yyyy-MM-dd" @change="beginDateChange">
|
||||
</el-date-picker>
|
||||
</el-form-item>
|
||||
<el-form-item label="完成时间:">
|
||||
<el-date-picker v-model="successTimeValue" type="daterange" range-separator="至" start-placeholder="开始日期"
|
||||
end-placeholder="结束日期" format="yyyy 年 MM 月 dd 日" value-format="yyyy-MM-dd" @change="successDateChange">
|
||||
</el-date-picker>
|
||||
</el-form-item>
|
||||
|
||||
<div class="searchBtn">
|
||||
<el-button type="primary" size="small" icon="el-icon-search" @click="handleSearch">搜 索</el-button>
|
||||
<el-button size="small" icon="el-icon-delete" @click="handleClear">清 空</el-button>
|
||||
</div>
|
||||
</el-row>
|
||||
</el-form> -->
|
||||
<!--/搜索栏-->
|
||||
<waiting-mission ref="waiting" v-if="search.status === 1" @refresh="handleClear"></waiting-mission>
|
||||
<ongoing-mission ref="onging" v-if="search.status === 2" @refresh="handleClear"></ongoing-mission>
|
||||
<finished-mission ref="finished" v-if="search.status === 3" @refresh="handleClear"></finished-mission>
|
||||
<expired-mission ref="expired" v-if="search.status === 4" @refresh="handleClear"></expired-mission>
|
||||
</basic-container>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import WaitingMission from './Table/WaitingMission'
|
||||
import OngoingMission from './Table/OngoingMission'
|
||||
import FinishedMission from './Table/FinishedMission'
|
||||
import ExpiredMission from './Table/ExpiredMission'
|
||||
import { companyMissionState } from '@/common/dic'
|
||||
|
||||
// import {mapGetters} from "vuex";
|
||||
|
||||
export default {
|
||||
comments: {
|
||||
|
||||
},
|
||||
name: "tenant_mission",
|
||||
data() {
|
||||
return {
|
||||
missionTypes: companyMissionState,
|
||||
timeValue: "",
|
||||
endDateRange: "",//报名截止日期筛选
|
||||
beginTimeValue: "",//开始时间筛选
|
||||
successTimeValue: "",//完成时间筛选
|
||||
page: {
|
||||
pageSize: 20,
|
||||
currentPage: 1,
|
||||
total: 0
|
||||
},
|
||||
search: {
|
||||
status: 1
|
||||
},
|
||||
timeScreenTerm: [{
|
||||
value: 1,
|
||||
label: '报名截止日期',
|
||||
},
|
||||
{
|
||||
value: 2,
|
||||
label: '开始日期',
|
||||
},
|
||||
{
|
||||
value: 3,
|
||||
label: '完成日期',
|
||||
}],
|
||||
}
|
||||
},
|
||||
components: {
|
||||
WaitingMission,
|
||||
OngoingMission,
|
||||
FinishedMission,
|
||||
ExpiredMission
|
||||
},
|
||||
computed: {
|
||||
},
|
||||
watch: {
|
||||
},
|
||||
methods: {
|
||||
handleSearch() {
|
||||
if (this.search.status === 1) {
|
||||
console.log("1111111");
|
||||
this.$refs.waiting.onLoad(this.page, this.search);
|
||||
} else if (this.search.status === 2) {
|
||||
console.log("222222");
|
||||
this.$refs.onging.onLoad(this.page, this.search);
|
||||
} else if (this.search.status === 3) {
|
||||
console.log("3333333");
|
||||
this.$refs.finished.onLoad(this.page, this.search);
|
||||
} else if (this.search.status === 4) {
|
||||
console.log("444444444");
|
||||
this.$refs.expired.onLoad(this.page, this.search);
|
||||
}
|
||||
},
|
||||
date() {
|
||||
this.dateChange(this.timeValue)
|
||||
},
|
||||
dateChange(val) {
|
||||
// if (val) {
|
||||
// this.search.stime = val[0] + " 00:00:00";
|
||||
// this.search.etime = val[1] + " 23:59:59";
|
||||
// } else {
|
||||
// this.search.stime = '';
|
||||
// this.search.etime = '';
|
||||
// }
|
||||
switch (this.search.state) {
|
||||
case 1:
|
||||
return this.endDateChange(val)
|
||||
case 2:
|
||||
return this.beginDateChange(val);
|
||||
case 3:
|
||||
return this.successDateChange(val);
|
||||
}
|
||||
|
||||
},
|
||||
handleClear() {
|
||||
let curStatus = this.search.status;
|
||||
this.search = {
|
||||
status: curStatus,
|
||||
missionNo: '',
|
||||
missionTitle: '',
|
||||
stime: '',
|
||||
etime: '',
|
||||
etimePubBeginTime: '',
|
||||
etimePubEndTime: '',
|
||||
stimeBeginTime: '',
|
||||
stimeEndTime: '',
|
||||
etimeBeninTime: '',
|
||||
etimeEndTime: '',
|
||||
|
||||
}
|
||||
this.timeValue = '';
|
||||
this.endDateRange = '';
|
||||
this.beginTimeValue = "";
|
||||
this.successTimeValue = "";
|
||||
this.handleSearch()
|
||||
},
|
||||
// 开始时间
|
||||
beginDateChange(val) {
|
||||
if (val) {
|
||||
this.clearDateTime()
|
||||
this.search.stimeBeginTime = val[0] + " 00:00:00";
|
||||
this.search.stimeEndTime = val[1] + " 23:59:59";
|
||||
} else {
|
||||
this.search.stimeBeginTime = '';
|
||||
this.search.stimeEndTime = '';
|
||||
}
|
||||
},
|
||||
// 完成时间
|
||||
successDateChange(val) {
|
||||
if (val) {
|
||||
this.clearDateTime()
|
||||
this.search.etimeBeninTime = val[0] + " 00:00:00";
|
||||
this.search.etimeEndTime = val[1] + " 23:59:59";
|
||||
} else {
|
||||
this.search.etimeBeninTime = '';
|
||||
this.search.etimeEndTime = '';
|
||||
}
|
||||
},
|
||||
// 报名截止时间
|
||||
endDateChange(val) {
|
||||
if (val) {
|
||||
this.clearDateTime()
|
||||
this.search.etimePubBeginTime = val[0] + " 00:00:00";
|
||||
this.search.etimePubEndTime = val[1] + " 23:59:59";
|
||||
} else {
|
||||
this.search.etimePubBeginTime = '';
|
||||
this.search.etimePubEndTime = '';
|
||||
}
|
||||
},
|
||||
// 清楚多余时间参数
|
||||
clearDateTime() {
|
||||
this.search.etimePubBeginTime = '';
|
||||
this.search.etimePubEndTime = '';
|
||||
this.search.etimeBeninTime = '';
|
||||
this.search.etimeEndTime = '';
|
||||
this.search.stimeBeginTime = '';
|
||||
this.search.stimeEndTime = '';
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
<style scoped>
|
||||
.el-form-item {
|
||||
margin-bottom: 18px !important;
|
||||
margin-right: 10px !important;
|
||||
padding: 0 10px;
|
||||
}
|
||||
|
||||
.searchBtn {
|
||||
display: inline-block;
|
||||
margin-bottom: 18px;
|
||||
}
|
||||
</style>
|
||||
@@ -494,40 +494,6 @@ export default {
|
||||
slot: true,
|
||||
width:110
|
||||
},
|
||||
{
|
||||
label: "最新保期",
|
||||
prop: "period",
|
||||
searchSpan: 5,
|
||||
display: false,
|
||||
slot:true,
|
||||
width:190
|
||||
},
|
||||
{
|
||||
label: "商保状态",
|
||||
prop: "serviceStatus",
|
||||
searchSpan: 5,
|
||||
display: false,
|
||||
type: 'select',
|
||||
dicData: [
|
||||
{
|
||||
label: '未生效',
|
||||
value: 0
|
||||
},
|
||||
{
|
||||
label: '生效中',
|
||||
value: 1
|
||||
},
|
||||
{
|
||||
label: '即将失效',
|
||||
value: 2
|
||||
},
|
||||
{
|
||||
label: '已失效',
|
||||
value: 3
|
||||
},
|
||||
],
|
||||
slot:true,
|
||||
},
|
||||
{
|
||||
label: "工种",
|
||||
prop: "workTypes",
|
||||
|
||||
@@ -297,40 +297,6 @@ export default {
|
||||
slot: true,
|
||||
width:110
|
||||
},
|
||||
{
|
||||
label: "最新保期",
|
||||
prop: "period",
|
||||
searchSpan: 5,
|
||||
display: false,
|
||||
slot:true,
|
||||
width:190
|
||||
},
|
||||
{
|
||||
label: "商保状态",
|
||||
prop: "serviceStatus",
|
||||
searchSpan: 5,
|
||||
display: false,
|
||||
type: 'select',
|
||||
dicData: [
|
||||
{
|
||||
label: '未生效',
|
||||
value: 0
|
||||
},
|
||||
{
|
||||
label: '生效中',
|
||||
value: 1
|
||||
},
|
||||
{
|
||||
label: '即将失效',
|
||||
value: 2
|
||||
},
|
||||
{
|
||||
label: '已失效',
|
||||
value: 3
|
||||
},
|
||||
],
|
||||
slot:true,
|
||||
},
|
||||
{
|
||||
label: "工种",
|
||||
prop: "workTypes",
|
||||
|
||||
Reference in New Issue
Block a user