flat: 暂存
This commit is contained in:
@@ -1,17 +1,20 @@
|
||||
<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">
|
||||
@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>
|
||||
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_mission_add, false)">批量导入</el-button>
|
||||
v-show="vaildData(permission.tenant_mission_add, false)">批量导入
|
||||
</el-button>
|
||||
</template>
|
||||
<template slot="wage"slot-scope="{ row }">
|
||||
<div>{{row.wage}}{{wageUnitCategoryStateEnum[row.wageUnitCategory]}}</div>
|
||||
<template slot="wage" slot-scope="{ row }">
|
||||
<div>{{ row.wage }}{{ wageUnitCategoryStateEnum[row.wageUnitCategory] }}</div>
|
||||
</template>
|
||||
<!--/自定义按钮-->
|
||||
<!--自定义列-->
|
||||
@@ -55,12 +58,16 @@
|
||||
<!-- <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>
|
||||
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="row.signUpCount !== 0" v-show="vaildData(permission.tenant_mission_edit, false)">编辑</el-button>
|
||||
<el-button v-if="row.reviewState !== 8" icon="el-icon-delete" :size="size" :type="type" @click="$refs.crud.rowDel(row)"
|
||||
:disabled="row.signUpCount !== 0" v-show="vaildData(permission.tenant_mission_cancel, false)">取消</el-button>
|
||||
:disabled="row.signUpCount !== 0" v-show="vaildData(permission.tenant_mission_edit, false)">编辑
|
||||
</el-button>
|
||||
<el-button v-if="row.reviewState !== 8" icon="el-icon-delete" :size="size" :type="type"
|
||||
@click="$refs.crud.rowDel(row)"
|
||||
:disabled="row.signUpCount !== 0" v-show="vaildData(permission.tenant_mission_cancel, false)">取消
|
||||
</el-button>
|
||||
</div>
|
||||
</avue-crud>
|
||||
<!--发布 复制 编辑dialog-->
|
||||
@@ -81,8 +88,9 @@
|
||||
<!--/查看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">
|
||||
<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">
|
||||
点击下载
|
||||
@@ -96,8 +104,8 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { upload } from "@/api/tenant/mission";
|
||||
import { getList, cancel, detail } from "@/api/tenant/mission";
|
||||
import {upload} from "@/api/tenant/mission";
|
||||
import {getList, cancel, detail} from "@/api/tenant/mission";
|
||||
import CopyMission from "../Dialog/CopyMission";
|
||||
import Employ from "../Dialog/Employ";
|
||||
import employmentNum from "../Dialog/EmployNumber";
|
||||
@@ -106,13 +114,14 @@ 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 {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";
|
||||
import {dataSourcesEnum, educationState, missionState, recruitStatus, wageUnitCategoryState} from "@/common/dic";
|
||||
|
||||
const wageUnitCategoryStateEnum = {}
|
||||
wageUnitCategoryState.map((item) => {
|
||||
wageUnitCategoryStateEnum[item.value] = item.label
|
||||
@@ -143,7 +152,7 @@ export default {
|
||||
return {
|
||||
wageUnitCategoryStateEnum,
|
||||
excelBox: false,
|
||||
excelForm: { isCovered: 1 },
|
||||
excelForm: {isCovered: 1},
|
||||
excelOption: {
|
||||
submitBtn: false,
|
||||
emptyBtn: false,
|
||||
@@ -190,7 +199,8 @@ export default {
|
||||
missionNo: '',
|
||||
};
|
||||
},
|
||||
created() { },
|
||||
created() {
|
||||
},
|
||||
watch: {},
|
||||
computed: {
|
||||
...mapGetters(["permission"]),
|
||||
@@ -228,7 +238,7 @@ export default {
|
||||
width: 120,
|
||||
},
|
||||
{
|
||||
label: "任务名称",
|
||||
label: "岗位名称",
|
||||
prop: "missionTitle",
|
||||
display: false,
|
||||
fixed: true,
|
||||
@@ -260,14 +270,14 @@ export default {
|
||||
prop: "ageDesc",
|
||||
search: false,
|
||||
display: false,
|
||||
},{
|
||||
}, {
|
||||
label: "学历要求",
|
||||
prop: "education",
|
||||
type: "select",
|
||||
dicData: educationState,
|
||||
search: false,
|
||||
display: false,
|
||||
},{
|
||||
}, {
|
||||
label: "经验要求",
|
||||
prop: "experienceDesc",
|
||||
search: false,
|
||||
@@ -406,8 +416,8 @@ export default {
|
||||
const h = this.$createElement;
|
||||
this.$confirm(
|
||||
h("div", null, [
|
||||
h("p", { style: "font-size: 16px" }, "您确定要取消此任务吗? "),
|
||||
h("p", { style: "color: red" }, "一旦取消则任务失效"),
|
||||
h("p", {style: "font-size: 16px"}, "您确定要取消此任务吗? "),
|
||||
h("p", {style: "color: red"}, "一旦取消则任务失效"),
|
||||
]),
|
||||
{
|
||||
type: "warning",
|
||||
@@ -499,13 +509,13 @@ export default {
|
||||
const arr = [];
|
||||
const data = res.data.data;
|
||||
data.error &&
|
||||
data.error.errorList.forEach((item) => {
|
||||
arr.push(`${item.name} ${item.remarks}`);
|
||||
});
|
||||
data.error.errorList.forEach((item) => {
|
||||
arr.push(`${item.name} ${item.remarks}`);
|
||||
});
|
||||
data.auth &&
|
||||
data.auth.authList.forEach((item) => {
|
||||
arr.push(`${item.name} ${item.remarks}`);
|
||||
});
|
||||
data.auth.authList.forEach((item) => {
|
||||
arr.push(`${item.name} ${item.remarks}`);
|
||||
});
|
||||
this.$refs.ied.show(arr);
|
||||
}
|
||||
this.refreshChange();
|
||||
|
||||
@@ -3,10 +3,64 @@
|
||||
<!--搜索栏-->
|
||||
<el-form size="small" label-position="right" :inline="true" style="padding-left: 10px;padding-right: 10px;">
|
||||
<el-row :span="24">
|
||||
<el-form-item label="任务名称:">
|
||||
<el-input v-model="search.missionTitle" placeholder="任务名称" clearable></el-input>
|
||||
<!-- <el-form-item label="任务名称:">-->
|
||||
<!-- <el-input v-model="search.missionTitle" placeholder="任务名称" clearable></el-input>-->
|
||||
<!-- </el-form-item>-->
|
||||
<el-form-item label="机构名称:">
|
||||
<el-input
|
||||
v-model="search.companyName"
|
||||
placeholder="机构名称"
|
||||
clearable
|
||||
></el-input>
|
||||
</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.address"
|
||||
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-input
|
||||
v-model="search.worktypeNames"
|
||||
placeholder="零工工种"
|
||||
clearable
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="审核状态:">
|
||||
<el-select v-model="search.reviewState">
|
||||
<el-option
|
||||
v-for="(item, index) in recruitStatus"
|
||||
:key="index"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="学历:">
|
||||
<el-select v-model="search.education">
|
||||
<el-option
|
||||
v-for="(item, index) in educationState"
|
||||
:key="index"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
|
||||
<!-- <el-form-item label="任务状态:">
|
||||
<el-select v-model="search.status" placeholder="任务状态" style="width:100%">
|
||||
<el-option
|
||||
@@ -57,164 +111,162 @@
|
||||
</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 WaitingMission from './Table/WaitingMission'
|
||||
import OngoingMission from './Table/OngoingMission'
|
||||
import FinishedMission from './Table/FinishedMission'
|
||||
import ExpiredMission from './Table/ExpiredMission'
|
||||
import {companyMissionState, educationState, recruitStatus} from '@/common/dic'
|
||||
|
||||
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: 2,
|
||||
label: '任务开始日期',
|
||||
},
|
||||
{
|
||||
value: 3,
|
||||
label: '任务结束日期',
|
||||
}, {
|
||||
value: 1,
|
||||
label: '报名截止日期',
|
||||
}],
|
||||
export default {
|
||||
comments: {},
|
||||
name: "tenant_mission",
|
||||
data() {
|
||||
return {
|
||||
recruitStatus,
|
||||
educationState,
|
||||
missionTypes: companyMissionState,
|
||||
timeValue: "",
|
||||
endDateRange: "",//报名截止日期筛选
|
||||
beginTimeValue: "",//开始时间筛选
|
||||
successTimeValue: "",//完成时间筛选
|
||||
page: {
|
||||
pageSize: 20,
|
||||
currentPage: 1,
|
||||
total: 0,
|
||||
},
|
||||
search: {
|
||||
status: 1
|
||||
},
|
||||
timeScreenTerm: [{
|
||||
value: 2,
|
||||
label: '任务开始日期',
|
||||
},
|
||||
{
|
||||
value: 3,
|
||||
label: '任务结束日期',
|
||||
}, {
|
||||
value: 1,
|
||||
label: '报名截止日期',
|
||||
}],
|
||||
}
|
||||
},
|
||||
components: {
|
||||
WaitingMission,
|
||||
OngoingMission,
|
||||
FinishedMission,
|
||||
ExpiredMission
|
||||
},
|
||||
computed: {},
|
||||
watch: {},
|
||||
methods: {
|
||||
handleSearch() {
|
||||
if (this.search.status === 1) {
|
||||
this.$refs.waiting.onLoad(this.page, this.search);
|
||||
} else if (this.search.status === 2) {
|
||||
this.$refs.onging.onLoad(this.page, this.search);
|
||||
} else if (this.search.status === 3) {
|
||||
this.$refs.finished.onLoad(this.page, this.search);
|
||||
} else if (this.search.status === 4) {
|
||||
this.$refs.expired.onLoad(this.page, this.search);
|
||||
}
|
||||
},
|
||||
components: {
|
||||
WaitingMission,
|
||||
OngoingMission,
|
||||
FinishedMission,
|
||||
ExpiredMission
|
||||
date() {
|
||||
this.dateChange(this.timeValue)
|
||||
},
|
||||
computed: {
|
||||
},
|
||||
watch: {
|
||||
},
|
||||
methods: {
|
||||
handleSearch() {
|
||||
if (this.search.status === 1) {
|
||||
this.$refs.waiting.onLoad(this.page, this.search);
|
||||
} else if (this.search.status === 2) {
|
||||
this.$refs.onging.onLoad(this.page, this.search);
|
||||
} else if (this.search.status === 3) {
|
||||
this.$refs.finished.onLoad(this.page, this.search);
|
||||
} else if (this.search.status === 4) {
|
||||
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);
|
||||
}
|
||||
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:'',
|
||||
},
|
||||
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.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;
|
||||
}
|
||||
.el-form-item {
|
||||
margin-bottom: 18px !important;
|
||||
margin-right: 10px !important;
|
||||
padding: 0 10px;
|
||||
}
|
||||
|
||||
.searchBtn {
|
||||
display: inline-block;
|
||||
margin-bottom: 18px;
|
||||
}
|
||||
.searchBtn {
|
||||
display: inline-block;
|
||||
margin-bottom: 18px;
|
||||
}
|
||||
</style>
|
||||
|
||||
Reference in New Issue
Block a user