|
@@ -1,91 +1,109 @@
|
|
<template>
|
|
<template>
|
|
- <div class="card-search">
|
|
|
|
- <a-form
|
|
|
|
- ref="formRef"
|
|
|
|
- name="advanced_search"
|
|
|
|
- class="ant-advanced-search-form"
|
|
|
|
- :model="searchParams"
|
|
|
|
- >
|
|
|
|
- <a-row :gutter="24">
|
|
|
|
- <a-col :span="6">
|
|
|
|
- <a-form-item label="求职者" :label-col="{ span: 8 }" name="name">
|
|
|
|
- <a-input v-model:value="searchParams.jobUserName" style="color: black;" disabled="true" placeholder="" />
|
|
|
|
- </a-form-item>
|
|
|
|
- </a-col>
|
|
|
|
- <a-col :span="6">
|
|
|
|
- <a-form-item label="求职岗位" :label-col="{ span: 8 }" name="professionName">
|
|
|
|
- <a-input v-model:value="searchParams.professionName" style="color: black;" disabled="true" placeholder="" />
|
|
|
|
- </a-form-item>
|
|
|
|
- </a-col>
|
|
|
|
- <a-col :span="6">
|
|
|
|
- <a-form-item label="企业名称" :label-col="{ span: 8 }" name="companyName">
|
|
|
|
- <a-input v-model:value="searchParams.companyName" placeholder="" />
|
|
|
|
- </a-form-item>
|
|
|
|
- </a-col>
|
|
|
|
- <a-col :span="4" style="text-align: left">
|
|
|
|
- <a-button type="primary" html-type="submit" @click="onSearch">查询</a-button>
|
|
|
|
- <a-button
|
|
|
|
- style="margin: 0 8px"
|
|
|
|
- @click="
|
|
|
|
|
|
+ <a-modal
|
|
|
|
+ :width="1100"
|
|
|
|
+ v-model:visible="visible"
|
|
|
|
+ title="推荐岗位"
|
|
|
|
+ :confirm-loading="confirmLoading"
|
|
|
|
+ @ok="handleOk"
|
|
|
|
+ ok-text="确认"
|
|
|
|
+ cancel-text="取消"
|
|
|
|
+ :keyboard="false"
|
|
|
|
+ :mask-closable="false"
|
|
|
|
+ >
|
|
|
|
+ <div class="card-search">
|
|
|
|
+ <a-form
|
|
|
|
+ ref="formRef"
|
|
|
|
+ name="advanced_search"
|
|
|
|
+ class="ant-advanced-search-form"
|
|
|
|
+ :model="searchParams"
|
|
|
|
+ >
|
|
|
|
+ <a-row :gutter="24">
|
|
|
|
+ <a-col :span="6">
|
|
|
|
+ <a-form-item label="求职者" :label-col="{ span: 8 }" name="name">
|
|
|
|
+ <a-input v-model:value="searchParams.jobUserName" style="color: black;" disabled="true" placeholder=""/>
|
|
|
|
+ </a-form-item>
|
|
|
|
+ </a-col>
|
|
|
|
+ <a-col :span="6">
|
|
|
|
+ <a-form-item label="求职岗位" :label-col="{ span: 8 }" name="professionName">
|
|
|
|
+ <a-input v-model:value="searchParams.professionName" style="color: black;" disabled="true"
|
|
|
|
+ placeholder=""/>
|
|
|
|
+ </a-form-item>
|
|
|
|
+ </a-col>
|
|
|
|
+ <a-col :span="6">
|
|
|
|
+ <a-form-item label="企业名称" :label-col="{ span: 8 }" name="companyName">
|
|
|
|
+ <a-input v-model:value="searchParams.companyName" placeholder=""/>
|
|
|
|
+ </a-form-item>
|
|
|
|
+ </a-col>
|
|
|
|
+ <a-col :span="4" style="text-align: left">
|
|
|
|
+ <a-button type="primary" html-type="submit" @click="onSearch">查询</a-button>
|
|
|
|
+ <a-button
|
|
|
|
+ style="margin: 0 8px"
|
|
|
|
+ @click="
|
|
() => {
|
|
() => {
|
|
searchParams.pageIndex = 1;
|
|
searchParams.pageIndex = 1;
|
|
- searchParams.pageSize = 20;
|
|
|
|
|
|
+ searchParams.pageSize = 10;
|
|
searchParams.companyName = null;
|
|
searchParams.companyName = null;
|
|
loadData();
|
|
loadData();
|
|
}
|
|
}
|
|
- ">重置</a-button>
|
|
|
|
-<!-- <a style="font-size: 12px" @click="expand = !expand">-->
|
|
|
|
-<!-- <template v-if="expand">-->
|
|
|
|
-<!-- <UpOutlined />-->
|
|
|
|
-<!-- </template>-->
|
|
|
|
-<!-- <template v-else>-->
|
|
|
|
-<!-- <DownOutlined />-->
|
|
|
|
-<!-- </template>-->
|
|
|
|
-<!-- {{ expand ? '收缩' : '展开' }}-->
|
|
|
|
-<!-- </a>-->
|
|
|
|
- </a-col>
|
|
|
|
- </a-row>
|
|
|
|
- <a-row class="edit-operation">
|
|
|
|
- <a-col :span="24" style="text-align: right">
|
|
|
|
- <a-button type="primary" html-type="submit" functioncode="T01030202" @click='onBatchRecommend()' >批量推荐</a-button>
|
|
|
|
- </a-col>
|
|
|
|
- </a-row>
|
|
|
|
- </a-form>
|
|
|
|
- <div class="search-result-list">
|
|
|
|
- <a-table :columns="columns" :data-source="dataList" :scroll="{ x: '100%', y: 500 }" :pagination="pagination"
|
|
|
|
- :loading="formState.loading" :row-selection="{ selectedRowKeys: formState.selectedRowKeys, onChange: onSelectChange }"
|
|
|
|
- :row-key="(record) => record.postID" bordered @change="handleTableChange" >
|
|
|
|
- <template #bodyCell="{ column, text, record }">
|
|
|
|
- <template v-if="column.key === 'operation'">
|
|
|
|
- <div class="table-operation">
|
|
|
|
- <a-button type="link" size="small" @click='onRecommend(record)' >推荐</a-button>
|
|
|
|
- </div>
|
|
|
|
|
|
+ ">重置
|
|
|
|
+ </a-button>
|
|
|
|
+ <!-- <a style="font-size: 12px" @click="expand = !expand">-->
|
|
|
|
+ <!-- <template v-if="expand">-->
|
|
|
|
+ <!-- <UpOutlined />-->
|
|
|
|
+ <!-- </template>-->
|
|
|
|
+ <!-- <template v-else>-->
|
|
|
|
+ <!-- <DownOutlined />-->
|
|
|
|
+ <!-- </template>-->
|
|
|
|
+ <!-- {{ expand ? '收缩' : '展开' }}-->
|
|
|
|
+ <!-- </a>-->
|
|
|
|
+ </a-col>
|
|
|
|
+ </a-row>
|
|
|
|
+ <a-row class="edit-operation">
|
|
|
|
+ <a-col :span="24" style="text-align: right">
|
|
|
|
+ <a-button type="primary" html-type="submit" functioncode="T01030202" @click='onBatchRecommend()'>批量推荐
|
|
|
|
+ </a-button>
|
|
|
|
+ </a-col>
|
|
|
|
+ </a-row>
|
|
|
|
+ </a-form>
|
|
|
|
+ <div class="search-result-list">
|
|
|
|
+ <a-table :columns="columns" :data-source="dataList" :scroll="{ x: '100%', y: 500 }" :pagination="pagination"
|
|
|
|
+ :loading="formState.loading"
|
|
|
|
+ :row-selection="{ selectedRowKeys: formState.selectedRowKeys, onChange: onSelectChange }"
|
|
|
|
+ :row-key="(record) => record.recommendMgtID" bordered @change="handleTableChange">
|
|
|
|
+ <template #bodyCell="{ column, text, record }">
|
|
|
|
+ <template v-if="column.key === 'operation'">
|
|
|
|
+ <div class="table-operation">
|
|
|
|
+ <a-button type="link" size="small" @click='onRecommend(record)'>推荐</a-button>
|
|
|
|
+ </div>
|
|
|
|
+ </template>
|
|
</template>
|
|
</template>
|
|
- </template>
|
|
|
|
- </a-table>
|
|
|
|
|
|
+ </a-table>
|
|
|
|
+ </div>
|
|
</div>
|
|
</div>
|
|
- </div>
|
|
|
|
|
|
+ </a-modal>
|
|
</template>
|
|
</template>
|
|
|
|
|
|
<script lang="ts">
|
|
<script lang="ts">
|
|
import {reactive, ref, computed, defineComponent} from 'vue';
|
|
import {reactive, ref, computed, defineComponent} from 'vue';
|
|
-import type { FormInstance, TableColumnsType, TableProps } from 'ant-design-vue';
|
|
|
|
|
|
+import type {FormInstance, TableColumnsType, TableProps} from 'ant-design-vue';
|
|
import {getRecommendCompanyPostList, addRecommend} from '@/api/jobUserManager/recommendMgt';
|
|
import {getRecommendCompanyPostList, addRecommend} from '@/api/jobUserManager/recommendMgt';
|
|
-import { getPaginationTotalTitle } from '@/utils/common';
|
|
|
|
|
|
+import {getPaginationTotalTitle} from '@/utils/common';
|
|
import dayjs from 'dayjs';
|
|
import dayjs from 'dayjs';
|
|
import {message} from "ant-design-vue";
|
|
import {message} from "ant-design-vue";
|
|
|
|
|
|
export default defineComponent({
|
|
export default defineComponent({
|
|
name: 'RecommendCompanyPostList',
|
|
name: 'RecommendCompanyPostList',
|
|
setup() {
|
|
setup() {
|
|
|
|
+ const visible = ref<boolean>(false);
|
|
|
|
+ const confirmLoading = ref<boolean>(false);
|
|
const formRef = ref<FormInstance>();
|
|
const formRef = ref<FormInstance>();
|
|
const expand = ref(false);
|
|
const expand = ref(false);
|
|
const searchParams = reactive({
|
|
const searchParams = reactive({
|
|
pageIndex: 1,
|
|
pageIndex: 1,
|
|
- pageSize: 20,
|
|
|
|
|
|
+ pageSize: 10,
|
|
jobUserName: null,
|
|
jobUserName: null,
|
|
jobHuntID: '',
|
|
jobHuntID: '',
|
|
- professionID:'',
|
|
|
|
|
|
+ professionID: '',
|
|
companyName: null,
|
|
companyName: null,
|
|
professionName: null,
|
|
professionName: null,
|
|
type: 0
|
|
type: 0
|
|
@@ -100,18 +118,22 @@ export default defineComponent({
|
|
title: '序号',
|
|
title: '序号',
|
|
align: 'center',
|
|
align: 'center',
|
|
width: 80,
|
|
width: 80,
|
|
- key: 'postID',
|
|
|
|
|
|
+ key: 'recommendMgtID',
|
|
customRender: (item) =>
|
|
customRender: (item) =>
|
|
`${searchParams.pageSize * (searchParams.pageIndex - 1) + item.index + 1}`,
|
|
`${searchParams.pageSize * (searchParams.pageIndex - 1) + item.index + 1}`,
|
|
},
|
|
},
|
|
- { title: '企业名称', dataIndex: 'companyName', key: 'companyName', width: 100,align: "center", },
|
|
|
|
- { title: '岗位名称', dataIndex: 'professionName', key: 'professionName', width: 150, align: "center", },
|
|
|
|
- { title: '招聘人数', dataIndex: 'recruitCount', key: 'recruitCount', width: 150, align: "center", },
|
|
|
|
- { title: '工作开始时间', dataIndex: 'startTime', key: 'startTime', width: 100, align: "center",
|
|
|
|
- customRender: ({ record }) => record.startTime == null?"":dayjs(record.startTime).format('YYYY-MM-DD'), },
|
|
|
|
- { title: '工作结束时间', dataIndex: 'endTime', key: 'endTime', width: 100, align: "center",
|
|
|
|
- customRender: ({ record }) => record.endTime == null?"":dayjs(record.endTime).format('YYYY-MM-DD'), },
|
|
|
|
- { title: '操作', key: 'operation', width: 100, align: 'center' },
|
|
|
|
|
|
+ {title: '企业名称', dataIndex: 'companyName', key: 'companyName', width: 100, align: "center",},
|
|
|
|
+ {title: '岗位名称', dataIndex: 'professionName', key: 'professionName', width: 150, align: "center",},
|
|
|
|
+ {title: '招聘人数', dataIndex: 'recruitCount', key: 'recruitCount', width: 150, align: "center",},
|
|
|
|
+ {
|
|
|
|
+ title: '工作开始时间', dataIndex: 'startTime', key: 'startTime', width: 100, align: "center",
|
|
|
|
+ customRender: ({record}) => record.startTime == null ? "" : dayjs(record.startTime).format('YYYY-MM-DD'),
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ title: '工作结束时间', dataIndex: 'endTime', key: 'endTime', width: 100, align: "center",
|
|
|
|
+ customRender: ({record}) => record.endTime == null ? "" : dayjs(record.endTime).format('YYYY-MM-DD'),
|
|
|
|
+ },
|
|
|
|
+ {title: '操作', key: 'operation', width: 60, align: 'center'},
|
|
];
|
|
];
|
|
const pagination = computed(() => ({
|
|
const pagination = computed(() => ({
|
|
total: formState.total,
|
|
total: formState.total,
|
|
@@ -146,35 +168,64 @@ export default defineComponent({
|
|
dataList.value = result.list;
|
|
dataList.value = result.list;
|
|
formState.total = result.total;
|
|
formState.total = result.total;
|
|
formState.loading = false;
|
|
formState.loading = false;
|
|
- console.log("huntParams",searchParams);
|
|
|
|
|
|
+ console.log("huntParams", searchParams);
|
|
};
|
|
};
|
|
|
|
|
|
- const onRecommend =(item: any)=>{
|
|
|
|
- addRecommendList.value.push({recommendMgtID: item.recommendMgtID,postID: item.postID, jobHuntID : searchParams.jobHuntID, recommendType: searchParams.type});
|
|
|
|
- addRecommend(addRecommendList.value).then(()=>{
|
|
|
|
|
|
+ const show = (professionID: any, professionName: any, jobHuntID: any, jobUserName: any) => {
|
|
|
|
+ visible.value = true;
|
|
|
|
+ searchParams.jobHuntID = jobHuntID;
|
|
|
|
+ searchParams.jobUserName = jobUserName;
|
|
|
|
+ searchParams.professionID = professionID;
|
|
|
|
+ searchParams.professionName = professionName;
|
|
|
|
+ loadData();
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ const onRecommend = (item: any) => {
|
|
|
|
+ addRecommendList.value.push({
|
|
|
|
+ recommendMgtID: item.recommendMgtID,
|
|
|
|
+ postID: item.postID,
|
|
|
|
+ jobHuntID: searchParams.jobHuntID,
|
|
|
|
+ recommendType: searchParams.type
|
|
|
|
+ });
|
|
|
|
+ addRecommend(addRecommendList.value).then(() => {
|
|
loadData();
|
|
loadData();
|
|
- addRecommendList.length = 0;
|
|
|
|
|
|
+ addRecommendList.value = [];
|
|
});
|
|
});
|
|
};
|
|
};
|
|
|
|
|
|
const onBatchRecommend = () => {
|
|
const onBatchRecommend = () => {
|
|
- if(formState.selectedRowKeys.length == 0){
|
|
|
|
|
|
+ if (formState.selectedRowKeys.length == 0) {
|
|
message.warn("请选择需要推荐的企业!")
|
|
message.warn("请选择需要推荐的企业!")
|
|
return;
|
|
return;
|
|
}
|
|
}
|
|
- formState.selectedRowKeys.forEach(id=>{
|
|
|
|
- const item: any = dataList.value.find((x: any)=>x.recommendMgtID==id)
|
|
|
|
- if(item){
|
|
|
|
- addRecommendList.value.push({recommendMgtID: item.recommendMgtID,postID: item.postID, jobHuntID : searchParams.jobHuntID, recommendType: searchParams.type});
|
|
|
|
|
|
+ formState.selectedRowKeys.forEach(id => {
|
|
|
|
+ const item: any = dataList.value.find((x: any) => x.recommendMgtID == id)
|
|
|
|
+ if (item) {
|
|
|
|
+ addRecommendList.value.push({
|
|
|
|
+ recommendMgtID: item.recommendMgtID,
|
|
|
|
+ postID: item.postID,
|
|
|
|
+ jobHuntID: searchParams.jobHuntID,
|
|
|
|
+ recommendType: searchParams.type
|
|
|
|
+ });
|
|
}
|
|
}
|
|
})
|
|
})
|
|
- addRecommend(addRecommendList.value).then(()=>{
|
|
|
|
|
|
+ addRecommend(addRecommendList.value).then(() => {
|
|
loadData();
|
|
loadData();
|
|
- addRecommendList.length = 0;
|
|
|
|
|
|
+ addRecommendList.value = [];
|
|
});
|
|
});
|
|
};
|
|
};
|
|
|
|
|
|
|
|
+ const handleOk = () => {
|
|
|
|
+ visible.value = false;
|
|
|
|
+ };
|
|
|
|
+
|
|
|
|
+ const handleCancel = () => {
|
|
|
|
+ visible.value = false;
|
|
|
|
+ };
|
|
|
|
+
|
|
return {
|
|
return {
|
|
|
|
+ visible,
|
|
|
|
+ confirmLoading,
|
|
formRef,
|
|
formRef,
|
|
expand,
|
|
expand,
|
|
searchParams,
|
|
searchParams,
|
|
@@ -182,20 +233,18 @@ export default defineComponent({
|
|
columns,
|
|
columns,
|
|
pagination,
|
|
pagination,
|
|
dataList,
|
|
dataList,
|
|
|
|
+ show,
|
|
onSearch,
|
|
onSearch,
|
|
onRecommend,
|
|
onRecommend,
|
|
onBatchRecommend,
|
|
onBatchRecommend,
|
|
onSelectChange,
|
|
onSelectChange,
|
|
handleTableChange,
|
|
handleTableChange,
|
|
- loadData
|
|
|
|
|
|
+ loadData,
|
|
|
|
+ handleOk,
|
|
|
|
+ handleCancel
|
|
};
|
|
};
|
|
},
|
|
},
|
|
created() {
|
|
created() {
|
|
- this.searchParams.jobHuntID = history.state.params?.jobHuntID;
|
|
|
|
- this.searchParams.jobUserName = history.state.params?.jobUserName;
|
|
|
|
- this.searchParams.professionID = history.state.params?.professionID;
|
|
|
|
- this.searchParams.professionName = history.state.params?.professionName;
|
|
|
|
- this.loadData();
|
|
|
|
}
|
|
}
|
|
});
|
|
});
|
|
</script>
|
|
</script>
|