| @@ -1,14 +1,14 @@ | |||
| <!doctype html> | |||
| <html lang="en"> | |||
| <head> | |||
| <meta charset="UTF-8" /> | |||
| <link rel="icon" type="image/svg+xml" href="/vite.svg" /> | |||
| <meta name="viewport" content="width=device-width, initial-scale=1.0" /> | |||
| <title>Vite + Vue + TS</title> | |||
| <script type="module" crossorigin src="/assets/index-vl2I_K9U.js"></script> | |||
| <link rel="stylesheet" crossorigin href="/assets/index-q4XN7VCE.css"> | |||
| </head> | |||
| <body> | |||
| <div id="app"></div> | |||
| </body> | |||
| </html> | |||
| <!doctype html> | |||
| <html lang="en"> | |||
| <head> | |||
| <meta charset="UTF-8" /> | |||
| <link rel="icon" type="image/svg+xml" href="/vite.svg" /> | |||
| <meta name="viewport" content="width=device-width, initial-scale=1.0" /> | |||
| <title>Vite + Vue + TS</title> | |||
| <script type="module" crossorigin src="/assets/index-04ZkBbBm.js"></script> | |||
| <link rel="stylesheet" crossorigin href="/assets/index-_REgwLfQ.css"> | |||
| </head> | |||
| <body> | |||
| <div id="app"></div> | |||
| </body> | |||
| </html> | |||
| @@ -0,0 +1,14 @@ | |||
| npx vite build | |||
| msg=$1 | |||
| ciskip="[CI SKIP]" | |||
| if [[ $msg =~ deploy ]]; then | |||
| echo "此次提交将会部署,请查看drone日志。" | |||
| else | |||
| echo "此次提交不部署" | |||
| $msg="$msg$ciskip" | |||
| fi | |||
| git add . | |||
| git commit -a -m "$msg" | |||
| git push | |||
| @@ -1,10 +1,28 @@ | |||
| import axios from 'axios'; | |||
| import * as typeHelper from '@/utils/typeHelper'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| import { router } from '@/router'; | |||
| import { createVNode } from 'vue'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| let { commomParams, ExclamationCircleOutlined, Modal } = useCommon(); | |||
| const msgModel = (val) => { | |||
| Modal.confirm({ | |||
| title: val, | |||
| centered: true, | |||
| icon: createVNode(ExclamationCircleOutlined), | |||
| okText: '确认', | |||
| onOk() { | |||
| }, | |||
| onCancel() { | |||
| }, | |||
| }); | |||
| } | |||
| const instance = axios.create({ | |||
| // baseURL: 'http://114.132.85.7:8889', | |||
| // baseURL: 'https://admin1.jcjob.cn/api', | |||
| baseURL: 'https://rcsc-test.jcjob.cn/api', | |||
| timeout: 30000, | |||
| headers: { | |||
| @@ -26,9 +44,9 @@ instance.interceptors.request.use(function (config) { | |||
| // 添加响应拦截器 | |||
| instance.interceptors.response.use(function (response) { | |||
| switch(response.data.code) { | |||
| switch (response.data.code) { | |||
| case -1: | |||
| warnToast(response.data.msg); | |||
| // msgModel(response.data.msg) | |||
| break; | |||
| case 0: | |||
| break; | |||
| @@ -36,15 +54,20 @@ instance.interceptors.response.use(function (response) { | |||
| return response; | |||
| break; | |||
| case 401: | |||
| warnToast(response.data.msg); | |||
| msgModel(response.data.msg) | |||
| case 403: | |||
| warnToast(response.data.msg); | |||
| msgModel(response.data.msg) | |||
| break; | |||
| case 600: | |||
| warnToast(response.data.msg); | |||
| if (response.data.errors) { | |||
| msgModel(response.data.errors) | |||
| } else { | |||
| msgModel(response.data.msg) | |||
| } | |||
| break; | |||
| default: | |||
| warnToast(response.data.msg); | |||
| msgModel(response.data.msg) | |||
| // warnToast(response.data.msg); | |||
| } | |||
| // 2xx 范围内的状态码都会触发该函数。 | |||
| // 对响应数据做点什么 | |||
| @@ -8,6 +8,9 @@ export const PostImageUpload = postModel(url.ImageUpload); | |||
| export const PostJobseekerRegister = postModel(url.JobseekerRegister); | |||
| export const PostCompanyRegister = postModel(url.CompanyRegister); | |||
| export const GetCaptcha = getModel(url.Captcha); | |||
| export const PostSmsSend = postModel(url.SmsSend); | |||
| export const PostJobseekerSmsLogin = postModel(url.JobseekerSmsLogin); | |||
| // 招聘会 | |||
| export const PostRecruitmentBookcompany = getModel(url.RecruitmentBookcompany);// 获取招聘会参与的企业 | |||
| @@ -39,7 +42,12 @@ export const PostCompanyJobEdit = postModel(url.CompanyJobEdit); // 编辑职位 | |||
| export const PostCompanyJobList = getModel(url.CompanyJobList); // 企业职位列表 | |||
| export const GetCompanyJobInfo = getModel(url.CompanyJobInfo); // 职位信息 | |||
| export const PostCompanyJobDel = postModel(url.CompanyJobDel); // 职位删除 | |||
| export const PostCompanyJobRecycle= postModel(url.CompanyJobRecycle); // 职位放到回收站 | |||
| export const PostCompanyJobRecycle = postModel(url.CompanyJobRecycle); // 职位放到回收站 | |||
| export const GetCompanyJobRecycleList = getModel(url.CompanyJobRecycleList); // 职位放到回收站 | |||
| export const PostCompanyJobRecoverRecycle = postModel(url.CompanyJobRecoverRecycle); // 职位放到回收站 | |||
| export const PostCompanyJobStatusChange = postModel(url.CompanyJobStatusChange); // 职位放到回收站 | |||
| // 部门管理 | |||
| @@ -49,6 +57,32 @@ export const GetCompanyDepartmentList = getModel(url.CompanyDepartmentList); // | |||
| export const PostCompanyDepartmentDel = postModel(url.CompanyDepartmentDel); // 部门删除 | |||
| export const PostCompanyRecrBookList = getModel(url.CompanyRecrBookList); // 已预定招聘会列表 | |||
| // 反馈 | |||
| export const PostFeedbackAdd = postModel(url.FeedbackAdd); // 新增部门 | |||
| export const PostFeedbackDel = postModel(url.FeedbackDel); // 编辑部门 | |||
| export const GetFeedbackUpdate = getModel(url.FeedbackUpdate); // 部门列表 | |||
| export const GetFeedbackList = getModel(url.FeedbackList); // 部门删除 | |||
| export const GetFeedbackDetail = getModel(url.FeedbackDetail); // 已预定招聘会列表 | |||
| // 简历管理 | |||
| export const GetCompanyResumeList = getModel(url.CompanyResumeList); // 收到的简历列表 | |||
| export const PostCompanyResumeRecycle = postModel(url.CompanyResumeRecycle); // 简历放进回收站 | |||
| export const PostCompanyResumeRecover = postModel(url.CompanyResumeRecover); // 简历从回收站中恢复 | |||
| export const GetCompanyResumeRecyclelist = getModel(url.CompanyResumeRecyclelist); // 回收站简历列表 | |||
| export const GetCompanyResumeInterviewList = getModel(url.CompanyResumeInterviewList); // 面试邀请记录 | |||
| export const PostCompanyResumeInterviewAdd = postModel(url.CompanyResumeInterviewAdd); // 发起面试邀请 | |||
| export const PostCompanyResumeInterviewDel = postModel(url.CompanyResumeInterviewDel); // 删除面试邀请 | |||
| export const PostCompanyResumeInterviewAdmission = postModel(url.CompanyResumeInterviewAdmission); // 是否录取 | |||
| export const PostCompanyResumeInterviewViewStatus = postModel(url.CompanyResumeInterviewViewStatus); // 是否参加面试 | |||
| export const GetCompanyResumeViewedContactList = getModel(url.CompanyResumeViewedContactList); // 已查看联系方式 | |||
| // 人才库 | |||
| export const PostCompanyTalentPoolAdd = postModel(url.CompanyTalentPoolAdd); // 添加人才库 | |||
| export const PostCompanyTalentPoolDel = postModel(url.CompanyTalentPoolDel); // 删除人才库记录 | |||
| export const GetCompanyTalentPoolList = getModel(url.CompanyTalentPoolList); // 人才库列表 | |||
| // 企业开通微信小程序账号公司权限 | |||
| export const PostCompanycustomercodeAdd = getModel(url.CompanycustomercodeAdd); // 添加 | |||
| export const PostCompanycustomercodeDel = postModel(url.CompanycustomercodeDel); // 删除 | |||
| @@ -56,16 +90,28 @@ export const PostCompanycustomercodeUpdate = postModel(url.CompanycustomercodeUp | |||
| export const PostCompanycustomercodeList = getModel(url.CompanycustomercodeList); // 列表 | |||
| export const PostCompanycustomercodeDetail = getModel(url.CompanycustomercodeDetail); // 添加 | |||
| // 展示广告位 | |||
| export const PostAdvertscheduleList = postModel(url.AdvertscheduleList); // 添加 | |||
| // 职位 | |||
| export const PostJobDetail = postModel(url.JobDetail); // 获取职位详情 | |||
| export const GetAdvertscheduleList = getModel(url.AdvertscheduleList); // 添加 | |||
| export const GetSectionList = getModel(url.SectionList); // 添加 | |||
| export const GetSectionDetail = getModel(url.SectionDetail); // 添加 | |||
| export const GetArticleList = getModel(url.ArticleList); // 添加 | |||
| export const GetArticlenDetail = getModel(url.ArticlenDetail); // 添加 | |||
| // 职位 | |||
| export const GetJobDetail = getModel(url.JobDetail); // 获取职位详情 | |||
| export const PostJobSearch = postModel(url.JobSearch); // 职位搜索 | |||
| export const PostJobNewest = postModel(url.JobNewest); // 最新职位 | |||
| export const PostJobCompanyjobs = postModel(url.JobCompanyjobs); // 企业当前招聘职位 | |||
| export const PostJobUrgentjobs = postModel(url.JobUrgentjobs); // 急招职位 | |||
| export const PostJobHighpayjobs = postModel(url.JobHighpayjobs); // 高薪职位 | |||
| export const PostJobCampusjobs = postModel(url.JobCampusjobs); // 校园招聘 | |||
| export const GetJobNewest = getModel(url.JobNewest); // 最新职位 | |||
| export const GetJobCompanyjobs = getModel(url.JobCompanyjobs); // 企业当前招聘职位 | |||
| export const GetJobUrgentjobs = getModel(url.JobUrgentjobs); // 急招职位 | |||
| export const GetJobHighpayjobs = getModel(url.JobHighpayjobs); // 高薪职位 | |||
| export const GetJobCampusjobs = getModel(url.JobCampusjobs); // 校园招聘 | |||
| // 见习基地 | |||
| export const GetCompanyProbationList = getModel(url.CompanyProbationList); // 校园招聘 | |||
| // 知名/推荐企业 | |||
| export const GetCompanyFamousList = getModel(url.CompanyFamousList); // 校园招聘 | |||
| // 招聘会企业预定 | |||
| export const PostRecruitmentbookAdd = postModel(url.RecruitmentbookAdd); // 添加 | |||
| @@ -78,6 +124,13 @@ export const GetRecruitmentbookDetail = getModel(url.RecruitmentbookDetail); // | |||
| // 列表 | |||
| export const PostJobseekerList = postModel(url.JobseekerList); | |||
| export const GetJobseekerDetail = getModel(url.JobseekerDetail); | |||
| export const GetViewhistoryList = getModel(url.ViewhistoryList); | |||
| export const PostPersonInterviewViewStatus = postModel(url.PersonInterviewViewStatus); | |||
| export const GetPersonInterviewList = getModel(url.PersonInterviewList); | |||
| export const GetPersonInterviewDel = getModel(url.PersonInterviewDel); | |||
| // 基本资料 | |||
| export const PostJobapplicantAdd = postModel(url.JobapplicantAdd); | |||
| export const PostJobapplicantDel = postModel(url.JobapplicantDel); | |||
| @@ -89,14 +142,14 @@ export const PostJobapplicantAddcontact = postModel(url.JobapplicantAddcontact); | |||
| export const PostJobapplicantDelcontact = postModel(url.JobapplicantDelcontact); | |||
| export const PostJobapplicantUpdatecontact = postModel(url.JobapplicantUpdatecontact); | |||
| export const PostJobapplicantListcontact = getModel(url.JobapplicantListcontact); | |||
| export const PostJobapplicantContactdetail = getModel(url.JobapplicantContactdetail); | |||
| export const GetJobapplicantContactdetail = getModel(url.JobapplicantContactdetail); | |||
| // 证书技能 | |||
| export const PostJobapplicantAddskill = postModel(url.JobapplicantAddskill); | |||
| export const PostJobapplicantDelskill = postModel(url.JobapplicantDelskill); | |||
| export const PostJobapplicantUpdateskill = postModel(url.JobapplicantUpdateskill); | |||
| export const PostJobapplicantListskill = getModel(url.JobapplicantListskill); | |||
| export const PostJobapplicantSkilldetail = getModel(url.JobapplicantSkilldetail); | |||
| // 培训经历 | |||
| // 培训经历 | |||
| export const PostJobapplicantAddtraining = postModel(url.JobapplicantAddtraining); | |||
| export const PostJobapplicantDeltraining = postModel(url.JobapplicantDeltraining); | |||
| export const PostJobapplicantUpdatetraining = postModel(url.JobapplicantUpdatetraining); | |||
| @@ -128,6 +181,7 @@ export const PostJobapplicantListexperience = getModel(url.JobapplicantListexper | |||
| export const PostJobapplicantExperiencedetail = getModel(url.JobapplicantExperiencedetail); | |||
| // 证书 | |||
| export const PostJobapplicantAddcertificate = postModel(url.JobapplicantAddcertificate); | |||
| export const PostJobapplicantDelcertificate = postModel(url.JobapplicantDelcertificate); | |||
| export const PostJobapplicantUpdatecertificate = postModel(url.JobapplicantUpdatecertificate); | |||
| export const PostJobapplicantListcertificate = getModel(url.JobapplicantListcertificate); | |||
| export const PostJobapplicantCertificatedetail = getModel(url.JobapplicantCertificatedetail); | |||
| @@ -1,11 +1,13 @@ | |||
| declare namespace urlType { | |||
| type url = { | |||
| // 字典 | |||
| dictTree: String, | |||
| ImageUpload: String, | |||
| dictTree : String, | |||
| ImageUpload : String, | |||
| JobseekerRegister : String, | |||
| CompanyRegister : String, | |||
| Captcha : String, | |||
| SmsSend : String, | |||
| JobseekerSmsLogin : String, | |||
| // 招聘会 | |||
| RecruitmentBookcompany : String, | |||
| @@ -18,10 +20,10 @@ declare namespace urlType { | |||
| // 企业管理中心 | |||
| CompanyRecommentResume : String, | |||
| CompanyProfile : String, | |||
| CompanyEdit: String, | |||
| CompanyDetailInfo: String, | |||
| CompanyPhotoUpload: String, | |||
| CompanyLicenseUpload: String, | |||
| CompanyEdit : String, | |||
| CompanyDetailInfo : String, | |||
| CompanyPhotoUpload : String, | |||
| CompanyLicenseUpload : String, | |||
| CompanyLogin : String, | |||
| CompanyInfo : String, | |||
| CompanyProbationList : String, | |||
| @@ -35,14 +37,40 @@ declare namespace urlType { | |||
| CompanyJobEdit : String, | |||
| CompanyJobList : String, | |||
| CompanyJobInfo : String, | |||
| CompanyJobDel: String, | |||
| CompanyJobRecycle: String, | |||
| CompanyJobDel : String, | |||
| CompanyJobRecycle : String, | |||
| CompanyJobRecycleList : String, | |||
| CompanyJobRecoverRecycle : String, | |||
| CompanyJobStatusChange : String, | |||
| // 部门管理 | |||
| CompanyDepartmentAdd : String, | |||
| CompanyDepartmentEdit : String, | |||
| CompanyDepartmentList : String, | |||
| CompanyDepartmentDel: String, | |||
| CompanyDepartmentDel : String, | |||
| CompanyRecrBookList : String, | |||
| // 反馈 | |||
| FeedbackAdd: String, | |||
| FeedbackDel: String, | |||
| FeedbackUpdate: String, | |||
| FeedbackList: String, | |||
| FeedbackDetail: String, | |||
| // 简历管理 | |||
| CompanyResumeList : String, | |||
| CompanyResumeRecycle : String, | |||
| CompanyResumeRecover : String, | |||
| CompanyResumeRecyclelist : String, | |||
| CompanyResumeInterviewList : String, | |||
| CompanyResumeInterviewAdd : String, | |||
| CompanyResumeInterviewDel : String, | |||
| CompanyResumeInterviewAdmission : String, | |||
| CompanyResumeInterviewViewStatus : String, | |||
| CompanyResumeViewedContactList : String, | |||
| CompanyTalentPoolAdd : String, | |||
| CompanyTalentPoolDel : String, | |||
| CompanyTalentPoolList : String, | |||
| // 企业开通微信小程序账号公司权限 | |||
| CompanycustomercodeAdd : String, | |||
| @@ -52,8 +80,12 @@ declare namespace urlType { | |||
| CompanycustomercodeDetail : String, | |||
| // 展示广告位 | |||
| AdvertscheduleList : String, | |||
| AdvertscheduleList | |||
| // 资讯 | |||
| SectionList : String, | |||
| SectionDetail : String, | |||
| ArticleList : String, | |||
| ArticlenDetail : String, | |||
| // 职位 | |||
| JobDetail : String, | |||
| JobSearch : String, | |||
| @@ -70,10 +102,18 @@ declare namespace urlType { | |||
| RecruitmentbookList : String, | |||
| RecruitmentbookDetail : String, | |||
| CompanyProbationList: String, | |||
| // 知名/推荐企业 | |||
| CompanyFamousList: String, | |||
| // 简历 | |||
| // 列表 | |||
| 'JobseekerList': String, // 查看 | |||
| 'JobseekerDetail': String, // 详情 | |||
| 'JobseekerList' : String, // 查看 | |||
| 'JobseekerDetail' : String, // 详情 | |||
| ViewhistoryList: String, // 详情 | |||
| PersonInterviewList: String, // 面试邀请记录 | |||
| PersonInterviewViewStatus: String, // 是否参加面试 | |||
| PersonInterviewDel: String, // 删除面试邀请 | |||
| // 基本资料 | |||
| 'JobapplicantAdd' : String, // 添加 | |||
| 'JobapplicantDel' : String, // 删除 | |||
| @@ -9,6 +9,9 @@ export const url : urlType.url = { | |||
| JobseekerRegister: web + '/jobseeker/register', // 个人注册 | |||
| CompanyRegister: web + '/company/register', // 企业注册 | |||
| Captcha: common + '/captcha', // 获取验证码 | |||
| SmsSend: common + '/sms/send', // 短信验证码 | |||
| JobseekerSmsLogin: web + '/jobseeker/smslogin', // 个人登录 | |||
| // 招聘会 | |||
| RecruitmentBookcompany: web + '/recruitment/bookcompany', // 获取招聘会参与的企业 | |||
| @@ -40,6 +43,10 @@ export const url : urlType.url = { | |||
| CompanyJobInfo: web + '/company/job_info', // 职位信息 | |||
| CompanyJobDel: web + '/company/job_del', // 职位删除 | |||
| CompanyJobRecycle: web + '/company/job_recycle', // 职位放到回收站 | |||
| CompanyJobRecycleList: web + '/company/job_recycle_list', // 回收站列表 | |||
| CompanyJobRecoverRecycle: web + '/company/job_recover_recycle', // 回收站列表 | |||
| CompanyJobStatusChange: web + '/company/job_status_change', // 回收站列表 | |||
| // 部门管理 | |||
| CompanyDepartmentAdd: web + '/company/department_add', // 新增部门 | |||
| CompanyDepartmentEdit: web + '/company/department_edit', // 编辑部门 | |||
| @@ -47,6 +54,24 @@ export const url : urlType.url = { | |||
| CompanyDepartmentDel: web + '/company/department_del', // 部门删除 | |||
| CompanyRecrBookList: web + '/company/recr_book_list', // 已预定招聘会列表 | |||
| // 简历管理 | |||
| CompanyResumeList: web + '/company/resume_list', // 收到的简历列表 | |||
| CompanyResumeRecycle: web + '/company/resume_recycle', // 简历放进回收站 | |||
| CompanyResumeRecover: web + '/company/resume_recover', // 简历从回收站中恢复 | |||
| CompanyResumeRecyclelist: web + '/company/resume_recycle_list', // 回收站简历列表 | |||
| CompanyResumeInterviewList: web + '/company/interview_list', // 面试邀请记录 | |||
| CompanyResumeInterviewAdd: web + '/company/interview_add', // 发起面试邀请 | |||
| CompanyResumeInterviewDel: web + '/company/interview_del', // 删除面试邀请 | |||
| CompanyResumeInterviewAdmission: web + '/company/interview_admission', // 是否录取 | |||
| CompanyResumeInterviewViewStatus: web + '/company/interview_view_status', // 是否参加面试 | |||
| CompanyResumeViewedContactList: web + '/company/viewed_contact_list', // 已查看联系方式 | |||
| // 人才库 | |||
| CompanyTalentPoolAdd: web + '/company/talent_pool_add', // 添加人才库 | |||
| CompanyTalentPoolDel: web + '/company/talent_pool_del', // 删除人才库记录 | |||
| CompanyTalentPoolList: web + '/company/talent_pool_list', // 人才库列表 | |||
| // 企业开通微信小程序账号公司权限 | |||
| CompanycustomercodeAdd: web + '/companycustomercode/add', // 添加 | |||
| CompanycustomercodeDel: web + '/companycustomercode/del', // 删除 | |||
| @@ -57,6 +82,12 @@ export const url : urlType.url = { | |||
| // 展示广告位 | |||
| AdvertscheduleList: web + '/advertschedule/list', // 详情 | |||
| // 资讯 | |||
| SectionList: web + '/section/list', // 列表 | |||
| SectionDetail: web + '/section/detail', // 详情 | |||
| ArticleList: web + '/article/list', | |||
| ArticlenDetail: web + '/article/detail', | |||
| // 职位 | |||
| JobDetail: web + '/job/detail', // 获取职位详情 | |||
| JobSearch: web + '/job/search', // 职位搜索 | |||
| @@ -73,9 +104,27 @@ export const url : urlType.url = { | |||
| RecruitmentbookList: web + '/recruitmentbook/list', // 列表 | |||
| RecruitmentbookDetail: web + '/recruitmentbook/detail', // 详情 | |||
| // 见习基地 | |||
| CompanyProbationList: web + '/company/probation_list', // 列表 | |||
| // 知名/推荐企业 | |||
| CompanyFamousList: web + '/company/famous_list', // 详情 | |||
| // 反馈 | |||
| FeedbackAdd: common + '/feedback/add', // 添加 | |||
| FeedbackDel: common + '/feedback/del', // 删除 | |||
| FeedbackUpdate: common + '/feedback/update', // 编辑 | |||
| FeedbackList: common + '/feedback/list', // 列表 | |||
| FeedbackDetail: common + '/feedback/detail', // 详情 | |||
| // 简历 | |||
| JobseekerList: web + '/jobseeker/list', // 获取简历完整资料列表 | |||
| JobseekerDetail: web + '/jobseeker/detail', // 获取简历完整资料 | |||
| ViewhistoryList: web + '/viewhistory/list', // 简历被查看次数 | |||
| PersonInterviewList: web + '/person/interview_list', // 面试邀请记录 | |||
| PersonInterviewViewStatus: web + '/person/interview_view_status', // 是否参加面试 | |||
| PersonInterviewDel: web + '/person/interview_del', // 删除面试邀请 | |||
| // 基本资料 | |||
| 'JobapplicantAdd': web + '/jobapplicant/add', // 添加 | |||
| 'JobapplicantDel': web + '/jobapplicant/del', // 删除 | |||
| @@ -1,5 +1,5 @@ | |||
| <template> | |||
| <a-table :data-source="data" :columns="columns" :pagination="pagination" @change="pageChange" :loading="loading"> | |||
| <a-table :data-source="data" :columns="columns" bordered :pagination="pagination" @change="pageChange" :loading="loading"> | |||
| <template #image="{ record }"> | |||
| <slot name="image" :record='record'></slot> | |||
| </template> | |||
| @@ -39,22 +39,22 @@ | |||
| </script> | |||
| <style scoped lang="less"> | |||
| :deep(.ant-table-thead >tr>th) { | |||
| background-color: #fff !important; | |||
| border: none !important; | |||
| color: #bbb !important; | |||
| } | |||
| // :deep(.ant-table-thead >tr>th) { | |||
| // background-color: #fff !important; | |||
| // border: none !important; | |||
| // color: #bbb !important; | |||
| // } | |||
| :deep(.ant-table-thead >tr>th::before) { | |||
| display: none !important; | |||
| } | |||
| :deep(.ant-table-tbody >tr >td) { | |||
| border: none !important; | |||
| } | |||
| // :deep(.ant-table-thead >tr>th::before) { | |||
| // display: none !important; | |||
| // } | |||
| // :deep(.ant-table-tbody >tr >td) { | |||
| // border: none !important; | |||
| // } | |||
| :deep(.ant-table-pagination) { | |||
| justify-content: center !important; | |||
| padding: 20px 0 !important; | |||
| } | |||
| // :deep(.ant-table-pagination) { | |||
| // justify-content: center !important; | |||
| // padding: 20px 0 !important; | |||
| // } | |||
| </style> | |||
| @@ -0,0 +1,37 @@ | |||
| <template> | |||
| <a-button @click="toEdit">编辑</a-button> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, computed, defineProps, watch, defineEmits, createVNode } from 'vue'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| let { store, showEdit, hideEdit ,ExclamationCircleOutlined, Modal } = useCommon(); | |||
| const toEdit = () => { | |||
| if (store.state.show_edit) { | |||
| Modal.confirm({ | |||
| title: '有内容在进行编辑,是否要退出当前编辑', | |||
| icon: createVNode(ExclamationCircleOutlined), | |||
| content: '当前编辑内容不会保存', | |||
| okText: '退出', | |||
| cancelText: '取消', | |||
| onOk() { | |||
| hideEdit() | |||
| }, | |||
| onCancel() { | |||
| console.log('Cancel'); | |||
| }, | |||
| }); | |||
| } else { | |||
| showEdit() | |||
| } | |||
| } | |||
| // editModel = computed(() => { | |||
| // return store.state.show_edit; | |||
| // }) | |||
| </script> | |||
| <style> | |||
| </style> | |||
| @@ -0,0 +1,35 @@ | |||
| <template> | |||
| <img :src="imgObj.src" alt="" :style="{width: imgObj.width,height: imgObj.height,'object-fit': imgObj.mode, 'border-radius': 0} "> | |||
| </template> | |||
| <script lang="ts" setup> | |||
| import { ref, onMounted, defineProps, watch, computed } from 'vue'; | |||
| const props = defineProps({ | |||
| imgObj: { | |||
| type: Object, | |||
| default: {} | |||
| } | |||
| }); | |||
| interface imgType { | |||
| src ?: String, | |||
| width ?: Number, | |||
| height ?: Number, | |||
| mode ?: String, | |||
| } | |||
| const imgObj = ref<imgType>({ | |||
| src : '', | |||
| width: 0, | |||
| height : 0, | |||
| mode : '', | |||
| }) | |||
| watch(() => [props.imgObj], (newVal: any) => { | |||
| if(newVal[0]) { | |||
| imgObj.value = newVal[0] | |||
| } | |||
| }, { immediate: true }) | |||
| </script> | |||
| <style> | |||
| </style> | |||
| @@ -1,21 +1,24 @@ | |||
| <template> | |||
| <a-menu v-model:selectedKeys="selectedKeys" @click="menuClick" | |||
| style="width: 100%;" mode="inline"> | |||
| <a-menu-item v-for="(item, index) in menuList" :key="item.key">{{item.name}}</a-menu-item> | |||
| </a-menu> | |||
| <a-affix :offset-top="90"> | |||
| <a-menu v-model:selectedKeys="selectedKeys" @click="menuClick" style="width: 100%;" mode="inline"> | |||
| <a-menu-item v-for="(item, index) in menuList" :key="item.key">{{item.title}}</a-menu-item> | |||
| </a-menu> | |||
| </a-affix> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, computed, onMounted, watch,defineProps,defineEmits } from 'vue'; | |||
| import { ref, computed, onMounted, watch, defineProps, defineEmits } from 'vue'; | |||
| let props = defineProps(['menu_list', 'selected_key']); | |||
| let emit = defineEmits(); | |||
| let menuList = ref<Object[]>(props.menu_list) | |||
| const selectedKeys = ref<string[]>(['1']); | |||
| const selectedKeys = ref<Number[]>([1]); | |||
| watch(() => [props.menu_list, props.selected_key], (newVal) => { | |||
| menuList.value = newVal[0], | |||
| menuList.value = newVal[0]; | |||
| selectedKeys.value = newVal[1] | |||
| }) | |||
| },{ immediate: true }) | |||
| const menuClick = (val) => { | |||
| emit('changeKey', { key: val.key }) | |||
| @@ -1,42 +0,0 @@ | |||
| declare namespace companyListType { | |||
| type addrFormType = { | |||
| full_name ?: String, | |||
| registration_number ?: String, | |||
| establishment_date ?: String, | |||
| contact ?: String, | |||
| phone ?: String, | |||
| mobile ?: String, | |||
| email ?: String, | |||
| fax ?: String, | |||
| website ?: String, | |||
| province ?: Number, | |||
| city ?: Number, | |||
| district ?: Number, | |||
| street ?: Number, | |||
| address ?: String, | |||
| industry ?: Number, | |||
| nature ?: Number, | |||
| scale ?: Number, | |||
| introduction ?: String, | |||
| photo ?: String, | |||
| photo_status ?: Number, | |||
| license_path ?: String, | |||
| license_status : '', | |||
| login_name ?: String, | |||
| login_pwd ?: String, | |||
| company_photos ?: Object[] | |||
| } | |||
| type addOtherFormType = { | |||
| chengli_date?: String, | |||
| content?: String, | |||
| photo_img?: String, | |||
| license_img?: String, | |||
| company_photo_img?: String, | |||
| company_address_cascader?: String, | |||
| company_industry_cascader?: String, | |||
| company_nature_cascader?: String, | |||
| company_scale_cascader?: String, | |||
| } | |||
| } | |||
| @@ -1,268 +0,0 @@ | |||
| <template> | |||
| <a-form :model="createForm" :label-col="{span: 4}" labelAlign="right"> | |||
| <a-row gutter="20"> | |||
| <a-col span="12"> | |||
| <a-row> | |||
| <a-col span="24"> | |||
| <a-form-item label="企业名称" name="full_name"> | |||
| <a-input v-model:value="createForm.full_name" placeholder="请输入企业名称" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="注册号" name="registration_number"> | |||
| <a-input v-model:value="createForm.registration_number" placeholder="请输入注册号" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="成立日期" name="establishment_date"> | |||
| <a-date-picker v-model:value="addOtherForm.chengli_date" @Change="establishmentDateChange" | |||
| style="width: 100%;" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="联系人" name="contact"> | |||
| <a-input v-model:value="createForm.contact" placeholder="请输入联系人" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="联系固话" name="phone"> | |||
| <a-input v-model:value="createForm.phone" placeholder="请输入联系电话" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="联系手机" name="mobile"> | |||
| <a-input v-model:value="createForm.mobile" placeholder="请输入联系手机" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="所属行业"> | |||
| <a-jilian :dict="2004" @saveCascader="industrySave" placeholder="请选择所属行业" | |||
| :cascader_content="addOtherForm.company_industry_cascader"></a-jilian> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="所在地区"> | |||
| <a-jilian :dict="2009" @saveCascader="compantAddressSave" placeholder="请选择公司地址" | |||
| :cascader_content="addOtherForm.company_address_cascader"></a-jilian> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="联系邮箱" name="email"> | |||
| <a-input v-model:value="createForm.email" placeholder="请输入联系邮箱" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="企业性质"> | |||
| <a-jilian :dict="2002" @saveCascader="natureSave" placeholder="请选择企业性质" | |||
| :cascader_content="addOtherForm.company_nature_cascader"></a-jilian> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="企业规模"> | |||
| <a-xuanze :dict="2003" placeholder="请选择企业规模" @saveSelect="scaleSave" | |||
| :select_content="addOtherForm.company_scale_cascader"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="企业传真" name="fax"> | |||
| <a-input v-model:value="createForm.fax" placeholder="请输入传真" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="详细地址" name="address"> | |||
| <a-input v-model:value="createForm.address" placeholder="请输入详细地址" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="企业官网" name="website"> | |||
| <a-input v-model:value="createForm.website" placeholder="请输入官网" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="企业介绍"> | |||
| <QuillEditor theme="snow" :options="options" toolbar="full" | |||
| v-model:content="addOtherForm.content" @update:content="onEditorUpdate($event)" | |||
| contentType="html" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="保存"> | |||
| <a-button type="primary" block @click="sumbitForm">保存</a-button> | |||
| </a-form-item> | |||
| </a-col> | |||
| </a-row> | |||
| </a-col> | |||
| </a-row> | |||
| </a-form> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, computed, defineProps, watch, defineEmits } from 'vue'; | |||
| import { PostCompanyDetailInfo, PostCompanyEdit } from '@/apis/models'; | |||
| import { intersectionAlike } from '@/utils/dataHelper'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| import dayjs from 'dayjs'; | |||
| import 'dayjs/locale/zh-cn'; | |||
| dayjs.locale('zh-cn'); | |||
| const dayjsRef = ref(dayjs); | |||
| const options = ref({ | |||
| debug: 'info', | |||
| modules: { | |||
| }, | |||
| placeholder: '请输入企业简介' | |||
| }) | |||
| let createForm : companyListType.addrFormType = ref({ | |||
| full_name: '', | |||
| registration_number: '', | |||
| establishment_date: '', | |||
| contact: '', | |||
| phone: '', | |||
| mobile: '', | |||
| email: '', | |||
| fax: '', | |||
| website: '', | |||
| province: 0, | |||
| city: 0, | |||
| district: 0, | |||
| street: 0, | |||
| address: '', | |||
| industry: 0, | |||
| industry2: 0, | |||
| nature: 0, | |||
| scale: 0, | |||
| introduction: '', | |||
| }) | |||
| let addOtherForm = ref<companyListType.addOtherFormType>({ | |||
| chengli_date: '', | |||
| content: '', | |||
| company_address_cascader: '', | |||
| company_industry_cascader: '', | |||
| company_nature_cascader: '', | |||
| company_scale_cascader: '', | |||
| }) | |||
| onMounted(async () => { | |||
| getBasic() | |||
| // let res = await listSection({ page: 1, pagesize: 10, sort: 'id', sortby: "asc", keyword: "" }); | |||
| // section_list.value = res.data.sections; | |||
| }) | |||
| const getBasic = () => { | |||
| PostCompanyDetailInfo().then(res => { | |||
| createForm.value = intersectionAlike(createForm.value, res.data) | |||
| addOtherForm.value = { | |||
| chengli_date: dayjsRef.value(res.data.establishment_date), | |||
| content: res.data.introduction, | |||
| company_address_cascader: res.data.province_name + res.data.city_name + res.data.district_name + res.data.street_name, | |||
| company_industry_cascader: res.data.industry_text + res.data.industry2_text, | |||
| company_nature_cascader : res.data.nature_text, | |||
| company_scale_cascader: res.data.scale_text, | |||
| } | |||
| }) | |||
| } | |||
| // 成立日期 | |||
| const establishmentDateChange = (val) => { | |||
| createForm.value.establishment_date = dayjsRef.value(val).format('YYYY-MM-DD'); | |||
| } | |||
| // 所属行业 industrySave | |||
| const industrySave = (data) => { | |||
| createForm.value.industry = data.arr1[0] ? data.arr1[0] : 0; | |||
| createForm.value.industry2 = data.arr1[1] ? data.arr1[1] : 0; | |||
| } | |||
| // 选择地址 | |||
| const compantAddressSave = (data) => { | |||
| createForm.value.province = data.arr1[0] ? data.arr1[0] : 0; | |||
| createForm.value.city = data.arr1[1] ? data.arr1[1] : 0; | |||
| createForm.value.district = data.arr1[2] ? data.arr1[2] : 0; | |||
| createForm.value.street = data.arr1[3] ? data.arr1[3] : 0; | |||
| } | |||
| // 企业性质 | |||
| const natureSave = (data) => { | |||
| createForm.value.nature = data.arr1[1] ? data.arr1[1] : 0; | |||
| } | |||
| // 企业规模 | |||
| const scaleSave = (data) => { | |||
| createForm.value.scale = data.val ? data.val : 0; | |||
| } | |||
| // 富文本 | |||
| const onEditorUpdate = (data) => { | |||
| createForm.value.introduction = data | |||
| } | |||
| // 上传图片 | |||
| // 企业照片 | |||
| // const uploadPhotoSuccess = (data : Object) => { | |||
| // addOtherForm.value.photo_img = "http://114.132.245.7:242494" + data | |||
| // createForm.value.photo = data | |||
| // } | |||
| // // 营业执照 | |||
| // const uploadLicenseSuccess = (data : Object) => { | |||
| // addOtherForm.value.license_img = "http://114.132.245.7:242494" + data | |||
| // createForm.value.license_path = data | |||
| // } | |||
| // // 企业相册 | |||
| // const uploadSuccess = (data : Object) => { | |||
| // addOtherForm.value.company_photo_img = "http://114.132.245.7:242494" + data | |||
| // createForm.value.company_photos.push({ photo: data }) | |||
| // } | |||
| const sumbitForm = () => { | |||
| console.log(createForm.value) | |||
| PostCompanyEdit(createForm.value).then(res => { | |||
| successToast('保存成功'); | |||
| resetForm(); | |||
| getBasic(); | |||
| }).catch(err => { | |||
| }) | |||
| } | |||
| const resetForm = () => { | |||
| createForm.value = { | |||
| chengli_date: '', | |||
| content: '', | |||
| company_address_cascader: '', | |||
| company_industry_cascader: '', | |||
| company_nature_cascader: '', | |||
| company_scale_cascader: '', | |||
| } | |||
| createForm.value = { | |||
| full_name: '', | |||
| registration_number: '', | |||
| establishment_date: '', | |||
| contact: '', | |||
| phone: '', | |||
| mobile: '', | |||
| email: '', | |||
| fax: '', | |||
| website: '', | |||
| province: 0, | |||
| city: 0, | |||
| district: 0, | |||
| street: 0, | |||
| address: '', | |||
| industry: 0, | |||
| industry2: 0, | |||
| nature: 0, | |||
| scale: 0, | |||
| introduction: '', | |||
| } | |||
| } | |||
| </script> | |||
| <style> | |||
| </style> | |||
| <style> | |||
| </style> | |||
| @@ -1,17 +0,0 @@ | |||
| declare namespace companyListType { | |||
| type addrFormType = { | |||
| id ?: Number, | |||
| probation ?: Number, | |||
| famous ?: Number, | |||
| member_type ?: Number, | |||
| member_status ?: Number, | |||
| start_date ?: Date, | |||
| end_date ?: Date, | |||
| sale ?: String, | |||
| } | |||
| // type addOtherFormType = { | |||
| // } | |||
| } | |||
| @@ -1,173 +0,0 @@ | |||
| <template> | |||
| <a-tabs v-model:activeKey="activeKey"> | |||
| <a-tab-pane key="1" tab="部门管理"> | |||
| <div style="margin: 16px;"> | |||
| <a-search @searchData="searchData" @clearData="clearData" | |||
| :search_params="commomParams.search"></a-search> | |||
| </div> | |||
| <a-biaoge :data="commomParams.table.data" :columns="commomParams.table.columns" | |||
| :pagination="commomParams.page" @page="getPage" :loading="loading"> | |||
| <template #default="{ record }"> | |||
| <a-row :gutter="20"> | |||
| <a-popconfirm title="是否删除该部门?" @confirm="del(record.id)"> | |||
| <a-col><a-button type="primary" size="small" danger>删除</a-button></a-col> | |||
| </a-popconfirm> | |||
| </a-row> | |||
| </template> | |||
| </a-biaoge> | |||
| </a-tab-pane> | |||
| <a-tab-pane key="2" tab="部门资料" force-render> | |||
| <a-form :model="createForm" :label-col="{span: 4}" labelAlign="right"> | |||
| <a-row gutter="20"> | |||
| <a-col span="12"> | |||
| <a-row> | |||
| <a-col span="24"> | |||
| <a-form-item required label="部门名称" name="name"> | |||
| <a-input v-model:value="createForm.name" placeholder="请输入部门名称" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item required label="联系人" name="contact"> | |||
| <a-input v-model:value="createForm.contact" placeholder="请输入联系人" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item required label="联系固话" name="phone"> | |||
| <a-input v-model:value="createForm.phone" placeholder="请输入联系电话" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item required label="联系手机" name="mobile"> | |||
| <a-input v-model:value="createForm.mobile" placeholder="请输入手机" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item required label="电子邮箱" name="email"> | |||
| <a-input v-model:value="createForm.email" placeholder="请输入邮箱" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="保存"> | |||
| <a-button type="primary" block @click="saveForm">保存</a-button> | |||
| </a-form-item> | |||
| </a-col> | |||
| </a-row> | |||
| </a-col> | |||
| </a-row> | |||
| </a-form> | |||
| </a-tab-pane> | |||
| </a-tabs> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, computed } from 'vue'; | |||
| import { PostCompanyDepartmentAdd, GetCompanyDepartmentList, PostCompanyDepartmentDel } from '@/apis/models'; | |||
| import ASearch from '@/components/company/department/search.vue'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| import { cols } from '@/components/company/department/columns'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| let activeKey = ref<String>("1") | |||
| let { commomParams } = useCommon(); | |||
| let loading = ref<Boolean>(true); | |||
| onMounted(() => { | |||
| getData(); | |||
| }) | |||
| const searchData = (data : object) => { | |||
| commomParams.value.search = data | |||
| getData(); | |||
| } | |||
| const clearData = (data : object) => { | |||
| if (data) { | |||
| commomParams.value.search = data | |||
| } else { | |||
| commomParams.value.search = { | |||
| page: 1, | |||
| pagesize: 10, | |||
| sort: 'id', | |||
| sortby: 'asc', | |||
| keyword: '' | |||
| } | |||
| } | |||
| getData(); | |||
| } | |||
| const getPage = (data : object) => { | |||
| commomParams.value.search.page = data.current; | |||
| commomParams.value.search.pagesize = data.pageSize; | |||
| getData(); | |||
| } | |||
| const getData = async () => { | |||
| try { | |||
| loading.value = true; | |||
| let res = await GetCompanyDepartmentList(); | |||
| loading.value = false; | |||
| commomParams.value.table.data = res.data.rows; | |||
| commomParams.value.table.columns = cols; | |||
| commomParams.value.page = { | |||
| current: commomParams.value.search.page, | |||
| pageSize: commomParams.value.search.pagesize, | |||
| total: res.data.total, | |||
| pageSizeOptions: ['10', '20', '30', '40'], | |||
| hideOnSinglePage: false, | |||
| showSizeChanger: true | |||
| }; | |||
| } catch { | |||
| loading.value = false; | |||
| } | |||
| } | |||
| let createForm : companyListType.addrFormType = ref({ | |||
| name: '', | |||
| contact: '', | |||
| phone: '', | |||
| mobile: '', | |||
| email: '', | |||
| }) | |||
| const saveForm = () => { | |||
| PostCompanyDepartmentAdd(createForm.value).then(res => { | |||
| successToast('保存成功') | |||
| getData() | |||
| resetForm() | |||
| activeKey.value = "1" | |||
| }) | |||
| } | |||
| const resetForm = () => { | |||
| createForm.value = { | |||
| name: '', | |||
| contact: '', | |||
| phone: '', | |||
| mobile: '', | |||
| email: '', | |||
| } | |||
| } | |||
| const del = (id: number) => { | |||
| commomParams.value.delParam = { id: id }; | |||
| PostCompanyDepartmentDel(commomParams.value.delParam).then(res => { | |||
| successToast('删除成功'); | |||
| getData(); | |||
| }) | |||
| } | |||
| </script> | |||
| <style scoped lang="less"> | |||
| :deep(.ant-table-thead >tr>th) { | |||
| background-color: #fff !important; | |||
| border: none !important; | |||
| color: #bbb !important; | |||
| } | |||
| :deep(.ant-table-thead >tr>th::before) { | |||
| display: none !important; | |||
| } | |||
| :deep(.ant-table-tbody >tr >td) { | |||
| border: none !important; | |||
| } | |||
| </style> | |||
| @@ -1,76 +0,0 @@ | |||
| <template> | |||
| <a-form :model="createForm" :label-col="{span: 6}" labelAlign="right"> | |||
| <a-row gutter="20"> | |||
| <a-col span="12"> | |||
| <a-row> | |||
| <a-col span="24"> | |||
| <a-form-item label="上传企业图片" name="photo"> | |||
| <upload upload_txt="上传企业图片" @uploadSuccess="uploadPhotoSuccess" | |||
| :success_image="addOtherForm.photo_img" images_length="1" image_type="3"></upload> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="保存"> | |||
| <a-button type="primary" block @click="saveForm">保存</a-button> | |||
| </a-form-item> | |||
| </a-col> | |||
| </a-row> | |||
| </a-col> | |||
| </a-row> | |||
| </a-form> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, computed } from 'vue'; | |||
| import { PostCompanyDetailInfo, PostCompanyPhotoUpload } from '@/apis/models'; | |||
| import Upload from '@/components/form/upload.vue'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| let createForm = ref({ | |||
| photo: '', | |||
| }) | |||
| let addOtherForm = ref({ | |||
| photo_img: '', | |||
| }) | |||
| onMounted(async () => { | |||
| getBasic() | |||
| // let res = await listSection({ page: 1, pagesize: 10, sort: 'id', sortby: "asc", keyword: "" }); | |||
| // section_list.value = res.data.sections; | |||
| }) | |||
| const getBasic = () => { | |||
| PostCompanyDetailInfo().then(res => { | |||
| createForm.value.photo = res.data.photo | |||
| addOtherForm.value = { | |||
| photo_img: "https://rcsc-test.jcjob.cn/img/" + res.data.photo, | |||
| } | |||
| }) | |||
| } | |||
| // 营业执照 | |||
| const uploadPhotoSuccess = (data : Object) => { | |||
| addOtherForm.value.photo_img = "https://rcsc-test.jcjob.cn/img/" + data | |||
| createForm.value.photo = data | |||
| } | |||
| const saveForm = () => { | |||
| PostCompanyPhotoUpload(createForm.value).then(res => { | |||
| successToast('保存成功') | |||
| resetForm(); | |||
| getBasic(); | |||
| }) | |||
| } | |||
| const resetForm = () => { | |||
| addOtherForm = { | |||
| photo_img: '', | |||
| } | |||
| createForm.value = { | |||
| photo: '' | |||
| } | |||
| } | |||
| </script> | |||
| <style> | |||
| </style> | |||
| @@ -0,0 +1,35 @@ | |||
| declare namespace CompanyBasicType { | |||
| type BasicFormType = { | |||
| full_name?: String, | |||
| registration_number?: String, | |||
| establishment_date?: String, | |||
| contact?: String, | |||
| phone?: String, | |||
| mobile?: String, | |||
| email?: String, | |||
| fax?: String, | |||
| website?: String, | |||
| province?: Number, | |||
| city?: Number, | |||
| district?: Number, | |||
| street?: Number, | |||
| address?: String, | |||
| industry?: Number, | |||
| industry2?: Number, | |||
| nature?: Number, | |||
| scale?: Number, | |||
| introduction?: String, | |||
| longitude?: Number, | |||
| latitude?: Number, | |||
| } | |||
| type OtherFormType = { | |||
| chengli_date?: String, | |||
| content?: String, | |||
| company_address_cascader?: String, | |||
| company_industry_cascader?: String, | |||
| company_nature_cascader?: String, | |||
| company_scale_cascader?: String, | |||
| } | |||
| } | |||
| @@ -0,0 +1,69 @@ | |||
| export let dataForm = { | |||
| full_name: '', | |||
| registration_number: '', | |||
| establishment_date: '', | |||
| contact: '', | |||
| phone: '', | |||
| mobile: '', | |||
| email: '', | |||
| fax: '', | |||
| website: '', | |||
| province: 0, | |||
| city: 0, | |||
| district: 0, | |||
| street: 0, | |||
| address: '', | |||
| industry: 0, | |||
| industry2: 0, | |||
| nature: 0, | |||
| scale: 0, | |||
| introduction: '', | |||
| longitude: 0, | |||
| latitude: 0, | |||
| } | |||
| export let otherDataForm = { | |||
| chengli_date: '', | |||
| content: '', | |||
| company_address_cascader: '', | |||
| company_industry_cascader: '', | |||
| company_nature_cascader: '', | |||
| company_scale_cascader: '', | |||
| } | |||
| export const reset = () => { | |||
| dataForm = { | |||
| full_name: '', | |||
| registration_number: '', | |||
| establishment_date: '', | |||
| contact: '', | |||
| phone: '', | |||
| mobile: '', | |||
| email: '', | |||
| fax: '', | |||
| website: '', | |||
| province: 0, | |||
| city: 0, | |||
| district: 0, | |||
| street: 0, | |||
| address: '', | |||
| industry: 0, | |||
| industry2: 0, | |||
| nature: 0, | |||
| scale: 0, | |||
| introduction: '', | |||
| longitude: 0, | |||
| latitude: 0, | |||
| } | |||
| otherDataForm = { | |||
| chengli_date: '', | |||
| content: '', | |||
| company_address_cascader: '', | |||
| company_industry_cascader: '', | |||
| company_nature_cascader: '', | |||
| company_scale_cascader: '', | |||
| } | |||
| return { dataForm, otherDataForm } | |||
| } | |||
| @@ -0,0 +1,251 @@ | |||
| <template> | |||
| <div> | |||
| <template v-if="state"> | |||
| <a-form :model="createForm" layout="vertical"> | |||
| <a-row :gutter="20"> | |||
| <a-col span="12"> | |||
| <a-form-item label="企业名称" name="full_name"> | |||
| <a-input v-model:value="createForm.full_name" placeholder="请输入企业名称" size="large" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="注册号" name="registration_number"> | |||
| <a-input v-model:value="createForm.registration_number" placeholder="请输入注册号" | |||
| size="large" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="成立日期" name="establishment_date"> | |||
| <a-date-picker v-model:value="addOtherForm.chengli_date" | |||
| @Change="establishmentDateChange" style="width: 100%;" size="large" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="联系人" name="contact"> | |||
| <a-input v-model:value="createForm.contact" placeholder="请输入联系人" size="large" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="联系固话" name="phone"> | |||
| <a-input v-model:value="createForm.phone" placeholder="请输入联系电话" size="large" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="联系手机" name="mobile"> | |||
| <a-input v-model:value="createForm.mobile" placeholder="请输入联系手机" size="large" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="所属行业"> | |||
| <a-jilian :dict="2000" @saveCascader="industrySave" placeholder="请选择所属行业" | |||
| :cascader_content="addOtherForm.company_industry_cascader"></a-jilian> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="所在地区"> | |||
| <a-jilian :dict="2009" @saveCascader="compantAddressSave" placeholder="请选择公司地址" | |||
| :cascader_content="addOtherForm.company_address_cascader"></a-jilian> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="联系邮箱" name="email"> | |||
| <a-input v-model:value="createForm.email" placeholder="请输入联系邮箱" size="large" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="企业性质"> | |||
| <a-jilian :dict="2002" @saveCascader="natureSave" placeholder="请选择企业性质" | |||
| :cascader_content="addOtherForm.company_nature_cascader"></a-jilian> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="企业规模"> | |||
| <a-xuanze :dict="2003" placeholder="请选择企业规模" @saveSelect="scaleSave" | |||
| :select_content="addOtherForm.company_scale_cascader"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="企业传真" name="fax"> | |||
| <a-input v-model:value="createForm.fax" placeholder="请输入传真" size="large" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="详细地址" name="address"> | |||
| <a-input v-model:value="createForm.address" placeholder="请输入详细地址" size="large" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="企业官网" name="website"> | |||
| <a-input v-model:value="createForm.website" placeholder="请输入官网" size="large" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="地图上选择经度"> | |||
| <a-input v-model:value="createForm.longitude" placeholder="选择经度" disabled/> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="地图上选择纬度"> | |||
| <a-input v-model:value="createForm.latitude" placeholder="选择纬度" disabled/> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="选择经纬度"> | |||
| <a-flex justify="center"> | |||
| <div style="width: 90%;"> | |||
| <a-switch v-model:checked="showMap"> </a-switch> | |||
| <div v-if="showMap"> | |||
| <v-map @getLoc="getLoc"></v-map> | |||
| </div> | |||
| </div> | |||
| </a-flex> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="企业介绍"> | |||
| <QuillEditor theme="snow" :options="richOption" toolbar="full" | |||
| v-model:content="addOtherForm.content" @update:content="onEditorUpdate($event)" | |||
| contentType="html" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-flex justify="flex-end"> | |||
| <a-space> | |||
| <a-button @click="resetForm" size="large">取消</a-button> | |||
| <a-button type="primary" @click="sumbitForm" size="large">保存</a-button> | |||
| </a-space> | |||
| </a-flex> | |||
| </a-col> | |||
| </a-row> | |||
| </a-form> | |||
| </template> | |||
| <template v-else> | |||
| <a-descriptions :title="basic.full_name" :column="3"> | |||
| </a-descriptions> | |||
| <a-descriptions :column="3"> | |||
| <a-descriptions-item label="注册号"> | |||
| {{basic.registration_number ? basic.registration_number : '未知'}} | |||
| </a-descriptions-item> | |||
| <a-descriptions-item label="成立时间">{{basic.establishment_date }}</a-descriptions-item> | |||
| </a-descriptions> | |||
| <a-descriptions :column="3" title="公司概况"> | |||
| <a-descriptions-item label="所属行业">{{basic.industry_text}}/{{basic.industry2_text}}</a-descriptions-item> | |||
| <a-descriptions-item label="公司性质">{{basic.nature_text}}</a-descriptions-item> | |||
| <a-descriptions-item label="公司规模">{{basic.scale_text }}</a-descriptions-item> | |||
| </a-descriptions> | |||
| <a-descriptions :column="3" title="联系方式"> | |||
| <a-descriptions-item label="联系地址" span="2">{{basic.address}}</a-descriptions-item> | |||
| <a-descriptions-item label="联系人">{{basic.contact}}</a-descriptions-item> | |||
| <a-descriptions-item label="联系手机">{{basic.mobile}}</a-descriptions-item> | |||
| <a-descriptions-item label="联系电话">{{basic.phone}}</a-descriptions-item> | |||
| <a-descriptions-item label="Email">{{basic.email}}</a-descriptions-item> | |||
| <a-descriptions-item label="传真">{{basic.fax}}</a-descriptions-item> | |||
| </a-descriptions> | |||
| </template> | |||
| </div> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, computed, defineProps, watch, defineEmits, createVNode } from 'vue'; | |||
| import { PostCompanyDetailInfo, PostCompanyEdit } from '@/apis/models'; | |||
| import vMap from '@/components/map/map-iframe.vue' | |||
| import { intersectionAlike } from '@/utils/dataHelper'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| import { dataForm, otherDataForm, reset } from '@/components/company/information/basic/data.ts'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| let { store, dayjs, richOption, ExclamationCircleOutlined, Modal } = useCommon(); | |||
| const dayjsRef = ref(dayjs); | |||
| let props = defineProps(['form_state']); | |||
| const emit = defineEmits(); | |||
| let state = ref<Boolean>(false) | |||
| let basic = ref({}) | |||
| let createForm = ref<CompanyBasicType.BasicFormType>(dataForm) | |||
| let addOtherForm = ref<CompanyBasicType.OtherFormType>(otherDataForm) | |||
| onMounted(() => { | |||
| getBasic() | |||
| }) | |||
| const getBasic = () => { | |||
| PostCompanyDetailInfo().then(res => { | |||
| basic.value = res.data; | |||
| createForm.value = intersectionAlike(createForm.value, res.data) | |||
| addOtherForm.value = { | |||
| chengli_date: dayjsRef.value(res.data.establishment_date), | |||
| content: res.data.introduction, | |||
| company_address_cascader: [res.data.province, res.data.city, res.data.district, res.data.street], | |||
| company_industry_cascader: [res.data.industry, res.data.industry2], | |||
| company_nature_cascader: [res.data.nature], | |||
| company_scale_cascader: res.data.scale, | |||
| } | |||
| }) | |||
| } | |||
| // 成立日期 | |||
| const establishmentDateChange = (val) => { | |||
| createForm.value.establishment_date = dayjsRef.value(val).format('YYYY-MM-DD'); | |||
| } | |||
| // 所属行业 industrySave | |||
| const industrySave = (data) => { | |||
| createForm.value.industry = data.arr1[0] ? data.arr1[0] : 0; | |||
| createForm.value.industry2 = data.arr1[1] ? data.arr1[1] : 0; | |||
| } | |||
| // 选择地址 | |||
| const compantAddressSave = (data) => { | |||
| createForm.value.province = data.arr1[0] ? data.arr1[0] : 0; | |||
| createForm.value.city = data.arr1[1] ? data.arr1[1] : 0; | |||
| createForm.value.district = data.arr1[2] ? data.arr1[2] : 0; | |||
| createForm.value.street = data.arr1[3] ? data.arr1[3] : 0; | |||
| } | |||
| // 企业性质 | |||
| const natureSave = (data) => { | |||
| createForm.value.nature = data.arr1[1] ? data.arr1[1] : 0; | |||
| } | |||
| // 企业规模 | |||
| const scaleSave = (data) => { | |||
| createForm.value.scale = data.val ? data.val : 0; | |||
| } | |||
| let showMap = ref<Boolean>(false); | |||
| // 经纬度 | |||
| const getLoc = (mapData : Object) => { | |||
| createForm.value.latitude = mapData.latlng.lng; | |||
| createForm.value.longitude = mapData.latlng.lat; | |||
| showMap.value = false; | |||
| } | |||
| // 富文本 | |||
| const onEditorUpdate = (data) => { | |||
| createForm.value.introduction = data | |||
| } | |||
| const sumbitForm = () => { | |||
| PostCompanyEdit(createForm.value).then(res => { | |||
| successToast('保存成功'); | |||
| resetForm() | |||
| }).catch(err => { | |||
| }) | |||
| } | |||
| const resetForm = () => { | |||
| createForm.value = reset().dataForm as CompanyBasicType.BasicFormType; | |||
| addOtherForm.value = reset().otherDataForm as CompanyBasicType.OtherFormType; | |||
| state.value = false; | |||
| getBasic(); | |||
| emit("quitEdit") | |||
| } | |||
| watch(() => [props.form_state], (newVal) => { | |||
| state.value = newVal[0]; | |||
| getBasic(); | |||
| }) | |||
| </script> | |||
| <style> | |||
| </style> | |||
| @@ -0,0 +1,27 @@ | |||
| export let dataForm = { | |||
| name: '', | |||
| contact: '', | |||
| phone: '', | |||
| mobile: '', | |||
| email: '', | |||
| } | |||
| export let otherDataForm = { | |||
| } | |||
| export const reset = () => { | |||
| dataForm = { | |||
| name: '', | |||
| contact: '', | |||
| phone: '', | |||
| mobile: '', | |||
| email: '', | |||
| } | |||
| otherDataForm = { | |||
| } | |||
| return { dataForm, otherDataForm } | |||
| } | |||
| @@ -0,0 +1,14 @@ | |||
| declare namespace CompanyDepartmentType { | |||
| type DepartmentFormType = { | |||
| name?: String, | |||
| contact?: String, | |||
| phone?: String, | |||
| mobile?: String, | |||
| email?: String, | |||
| } | |||
| // type addOtherFormType = { | |||
| // } | |||
| } | |||
| @@ -0,0 +1,208 @@ | |||
| <template> | |||
| <template v-if="state"> | |||
| <a-form :model="createForm" layout="vertical"> | |||
| <a-row :gutter="20"> | |||
| <a-col span="12"> | |||
| <a-form-item label="部门名称" name="name"> | |||
| <a-input v-model:value="createForm.name" placeholder="请输入部门名称" size="large" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="联系人" name="contact"> | |||
| <a-input v-model:value="createForm.contact" placeholder="请输入联系人" size="large" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="企业固话" name="phone"> | |||
| <a-input v-model:value="createForm.phone" placeholder="请输入联系电话" size="large" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="手机号" name="mobile"> | |||
| <a-input v-model:value="createForm.mobile" placeholder="请输入手机" size="large" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="电子邮箱" name="email"> | |||
| <a-input v-model:value="createForm.email" placeholder="请输入邮箱" size="large" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-flex justify="flex-end"> | |||
| <a-space> | |||
| <a-button @click="resetForm" size="large">取消</a-button> | |||
| <a-button type="primary" @click="saveForm" size="large">保存</a-button> | |||
| </a-space> | |||
| </a-flex> | |||
| </a-col> | |||
| </a-row> | |||
| </a-form> | |||
| </template> | |||
| <template v-else> | |||
| <a-search @searchData="searchData"></a-search> | |||
| <a-list :data-source="departmengList"> | |||
| <template #loadMore> | |||
| <div v-if="!loading" | |||
| :style="{ textAlign: 'center', marginTop: '12px', height: '32px', lineHeight: '32px' }"> | |||
| <a-button @click="onLoadMore">加载更多</a-button> | |||
| </div> | |||
| </template> | |||
| <template #renderItem="{ item }"> | |||
| <a-list-item> | |||
| <template #actions> | |||
| <a-button @click="toEdit(item)" size="small"> | |||
| 编辑 | |||
| </a-button> | |||
| <a-popconfirm title="是否删除该部门" @confirm="del(item.id)"> | |||
| <a-button size="small" danger> | |||
| 删除 | |||
| </a-button> | |||
| </a-popconfirm> | |||
| </template> | |||
| <a-skeleton avatar :title="false" :loading="!!loading" active> | |||
| <a-list-item-meta> | |||
| <template #title> | |||
| {{item.name}} | |||
| </template> | |||
| <template #description> | |||
| <div> | |||
| {{item.contact}} | |||
| <a-divider type="vertical" /> | |||
| {{item.phone}} | |||
| <a-divider type="vertical" /> | |||
| {{item.email}} | |||
| </div> | |||
| </template> | |||
| </a-list-item-meta> | |||
| </a-skeleton> | |||
| </a-list-item> | |||
| </template> | |||
| </a-list> | |||
| </template> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, defineEmits,computed, watch } from 'vue'; | |||
| import { PostCompanyDepartmentAdd, GetCompanyDepartmentList, PostCompanyDepartmentDel, PostCompanyDepartmentEdit } from '@/apis/models'; | |||
| import ASearch from '@/components/company/information/department/search.vue'; | |||
| import { cols } from '@/components/company/information/department/columns'; | |||
| import { intersectionAlike } from '@/utils/dataHelper'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| import { dataForm, otherDataForm, reset } from '@/components/company/information/department/data.ts'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| let { store, commomParams, dayjs, richOption, ExclamationCircleOutlined, Modal } = useCommon(); | |||
| let props = defineProps(['form_state']); | |||
| const emit = defineEmits(); | |||
| let state = ref<Boolean>(false) | |||
| let loading = ref<Boolean>(true); | |||
| let departmengList = ref([]); | |||
| let createForm = ref<CompanyDepartmentType.DepartmentFormType>(dataForm) | |||
| onMounted(() => { | |||
| getData(); | |||
| }) | |||
| const searchData = (data : object) => { | |||
| commomParams.value.search = data | |||
| getData(); | |||
| } | |||
| const clearData = (data : object) => { | |||
| if (data) { | |||
| commomParams.value.search = data | |||
| } else { | |||
| commomParams.value.search = { | |||
| page: 1, | |||
| pagesize: 10, | |||
| sort: 'id', | |||
| sortby: 'asc', | |||
| keyword: '' | |||
| } | |||
| } | |||
| getData(); | |||
| } | |||
| const getPage = (data : object) => { | |||
| commomParams.value.search.page = data.current; | |||
| commomParams.value.search.pagesize = data.pageSize; | |||
| getData(); | |||
| } | |||
| const getData = async () => { | |||
| try { | |||
| loading.value = true; | |||
| let res = await GetCompanyDepartmentList(commomParams.value.search); | |||
| loading.value = false; | |||
| commomParams.value.table.data = res.data.rows | |||
| departmengList.value = res.data.rows ? departmengList.value.concat(res.data.rows) : departmengList.value.concat([]); | |||
| commomParams.value.table.columns = cols; | |||
| commomParams.value.page = { | |||
| current: commomParams.value.search.page, | |||
| pageSize: commomParams.value.search.pagesize, | |||
| total: res.data.total, | |||
| pageSizeOptions: ['10', '20', '30', '40'], | |||
| hideOnSinglePage: false, | |||
| showSizeChanger: true | |||
| }; | |||
| } catch { | |||
| loading.value = false; | |||
| } | |||
| } | |||
| const onLoadMore = () => { | |||
| commomParams.value.search.page = commomParams.value.search.page + 1; | |||
| getData(); | |||
| } | |||
| const saveForm = () => { | |||
| if (createForm.value.id) { | |||
| PostCompanyDepartmentEdit(createForm.value).then(res => { | |||
| successToast('修改成功') | |||
| resetForm() | |||
| }) | |||
| } else { | |||
| PostCompanyDepartmentAdd(createForm.value).then(res => { | |||
| successToast('保存成功') | |||
| resetForm() | |||
| }) | |||
| } | |||
| } | |||
| const resetForm = () => { | |||
| departmengList.value = []; | |||
| createForm.value = reset().dataForm as CompanyDepartmentType.DepartmentFormType; | |||
| state.value = false; | |||
| getData(); | |||
| emit("quitEdit") | |||
| } | |||
| watch(() => [props.form_state], (newVal) => { | |||
| state.value = newVal[0]; | |||
| }) | |||
| const toEdit = (item : Object) => { | |||
| createForm.value = intersectionAlike(createForm.value, item) | |||
| createForm.value.id = item.id; | |||
| emit("editEdit") | |||
| } | |||
| const del = (id : number) => { | |||
| commomParams.value.delParam = { id: id }; | |||
| PostCompanyDepartmentDel(commomParams.value.delParam).then(res => { | |||
| successToast('删除成功'); | |||
| departmengList.value = []; | |||
| getData(); | |||
| }) | |||
| } | |||
| </script> | |||
| <style> | |||
| </style> | |||
| @@ -0,0 +1,43 @@ | |||
| <template> | |||
| <a-form :model="commomParams.search"> | |||
| <a-row :gutter="20"> | |||
| <a-col span="12"> | |||
| <a-form-item> | |||
| <a-input-search v-model:value="commomParams.search.keyword" placeholder="请输入部门名称" enter-button="搜索" @search="getData" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| </a-row> | |||
| </a-form> | |||
| </template> | |||
| <script lang="ts" setup> | |||
| import { ref, onMounted, watch, computed } from 'vue'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| let { commomParams } = useCommon(); | |||
| let props = defineProps(['search_params']); | |||
| const emit = defineEmits(); | |||
| watch(() => props.search_params, (newVal) => { | |||
| console.log(newVal) | |||
| }) | |||
| const getData = () => { | |||
| emit('searchData', commomParams.value.search) | |||
| } | |||
| // 清空搜索 | |||
| const clearSearch = () => { | |||
| commomParams.value.search = { | |||
| page: 1, | |||
| pagesize: 10, | |||
| sort: 'id', | |||
| sortby: 'asc', | |||
| keyword: '' | |||
| } | |||
| emit('clearData', commomParams.value.search) | |||
| } | |||
| </script> | |||
| <style> | |||
| </style> | |||
| @@ -0,0 +1,19 @@ | |||
| export let dataForm = { | |||
| photo: '', | |||
| } | |||
| export let otherDataForm = { | |||
| photo_img: '' | |||
| } | |||
| export const reset = () => { | |||
| dataForm = { | |||
| photo: '', | |||
| } | |||
| otherDataForm = { | |||
| photo_img: '' | |||
| } | |||
| return { dataForm, otherDataForm } | |||
| } | |||
| @@ -0,0 +1,10 @@ | |||
| declare namespace CompanyImageType { | |||
| type ImageFormType = { | |||
| photo?: String, | |||
| } | |||
| type OtherFormType = { | |||
| photo_img?: String, | |||
| } | |||
| } | |||
| @@ -0,0 +1,82 @@ | |||
| <template> | |||
| <div> | |||
| <template v-if="state"> | |||
| <a-form :model="createForm" layout="vertical"> | |||
| <a-row :gutter="20"> | |||
| <a-form-item label="上传企业图片" name="photo"> | |||
| <upload upload_txt="上传企业图片" @uploadSuccess="uploadPhotoSuccess" | |||
| :success_image="addOtherForm.photo_img" images_length="1" image_type="3"></upload> | |||
| </a-form-item> | |||
| <a-col span="24"> | |||
| <a-flex justify="flex-end"> | |||
| <a-space> | |||
| <a-button @click="resetForm" size="large">取消</a-button> | |||
| <a-button type="primary" @click="saveForm" size="large">保存</a-button> | |||
| </a-space> | |||
| </a-flex> | |||
| </a-col> | |||
| </a-row> | |||
| </a-form> | |||
| </template> | |||
| <template v-else> | |||
| <image-container :imgObj="{src: addOtherForm.photo_img,width: '200px',height:'280px', mode: 'fill'}"></image-container> | |||
| </template> | |||
| </div> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, computed, defineProps, watch, defineEmits, createVNode } from 'vue'; | |||
| import { PostCompanyDetailInfo, PostCompanyPhotoUpload } from '@/apis/models'; | |||
| import Upload from '@/components/form/upload.vue'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| import { dataForm, otherDataForm, reset } from '@/components/company/information/image/data.ts'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| let { imageprefix } = useCommon(); | |||
| let props = defineProps(['form_state']); | |||
| const emit = defineEmits(); | |||
| let state = ref<Boolean>(false) | |||
| let createForm = ref<CompanyBasicType.BasicFormType>(dataForm) | |||
| let addOtherForm = ref<CompanyBasicType.OtherFormType>(otherDataForm) | |||
| onMounted(async () => { | |||
| getBasic() | |||
| }) | |||
| const getBasic = () => { | |||
| PostCompanyDetailInfo().then(res => { | |||
| createForm.value.photo = res.data.photo | |||
| addOtherForm.value = { | |||
| photo_img: imageprefix + res.data.photo, | |||
| } | |||
| }) | |||
| } | |||
| // 营业执照 | |||
| const uploadPhotoSuccess = (data : Object) => { | |||
| addOtherForm.value.photo_img = imageprefix + data | |||
| createForm.value.photo = data | |||
| } | |||
| const saveForm = () => { | |||
| PostCompanyPhotoUpload(createForm.value).then(res => { | |||
| successToast('保存成功') | |||
| resetForm(); | |||
| getBasic(); | |||
| }) | |||
| } | |||
| const resetForm = () => { | |||
| createForm.value = reset().dataForm as CompanyBasicType.BasicFormType; | |||
| addOtherForm.value = reset().otherDataForm as CompanyBasicType.OtherFormType; | |||
| state.value = false; | |||
| emit("quitEdit") | |||
| } | |||
| watch(() => [props.form_state], (newVal) => { | |||
| state.value = newVal[0]; | |||
| getBasic(); | |||
| }) | |||
| </script> | |||
| <style> | |||
| </style> | |||
| @@ -0,0 +1,19 @@ | |||
| export let dataForm = { | |||
| license_path: '', | |||
| } | |||
| export let otherDataForm = { | |||
| license_img: '' | |||
| } | |||
| export const reset = () => { | |||
| dataForm = { | |||
| license_path: '', | |||
| } | |||
| otherDataForm = { | |||
| license_img: '' | |||
| } | |||
| return { dataForm, otherDataForm } | |||
| } | |||
| @@ -0,0 +1,83 @@ | |||
| <template> | |||
| <div> | |||
| <template v-if="state"> | |||
| <a-form :model="createForm" layout="vertical"> | |||
| <a-row :gutter="20"> | |||
| <a-form-item label="上传营业执照" name="photo"> | |||
| <upload upload_txt="上传营业执照" @uploadSuccess="uploadPhotoSuccess" | |||
| :success_image="addOtherForm.license_img" images_length="1" image_type="4"></upload> | |||
| </a-form-item> | |||
| <a-col span="24"> | |||
| <a-flex justify="flex-end"> | |||
| <a-space> | |||
| <a-button @click="resetForm" size="large">取消</a-button> | |||
| <a-button type="primary" @click="saveForm" size="large">保存</a-button> | |||
| </a-space> | |||
| </a-flex> | |||
| </a-col> | |||
| </a-row> | |||
| </a-form> | |||
| </template> | |||
| <template v-else> | |||
| <image-container :imgObj="{src: addOtherForm.license_img,width: '200px',height:'280px',mode: 'fill'}"></image-container> | |||
| </template> | |||
| </div> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, computed, defineProps, watch, defineEmits, createVNode } from 'vue'; | |||
| import { PostCompanyDetailInfo, PostCompanyLicenseUpload } from '@/apis/models'; | |||
| import Upload from '@/components/form/upload.vue'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| import { dataForm, otherDataForm, reset } from '@/components/company/information/image/data.ts'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| let { imageprefix } = useCommon(); | |||
| let props = defineProps(['form_state']); | |||
| const emit = defineEmits(); | |||
| let state = ref<Boolean>(false) | |||
| let createForm = ref<CompanyLicenceType.LicenceFormType>(dataForm) | |||
| let addOtherForm = ref<CompanyLicenceType.OtherFormType>(otherDataForm) | |||
| onMounted(async () => { | |||
| getBasic() | |||
| }) | |||
| const getBasic = () => { | |||
| PostCompanyDetailInfo().then(res => { | |||
| createForm.value.license_path = res.data.license_path | |||
| addOtherForm.value = { | |||
| license_img: imageprefix + res.data.license_path, | |||
| } | |||
| }) | |||
| } | |||
| // 营业执照 | |||
| const uploadPhotoSuccess = (data : Object) => { | |||
| addOtherForm.value.license_img = imageprefix + data | |||
| createForm.value.license_path = data | |||
| } | |||
| const saveForm = () => { | |||
| PostCompanyLicenseUpload(createForm.value).then(res => { | |||
| successToast('保存成功') | |||
| resetForm(); | |||
| getBasic(); | |||
| }) | |||
| } | |||
| const resetForm = () => { | |||
| createForm.value = reset().dataForm as CompanyLicenceType.LicenceFormType; | |||
| addOtherForm.value = reset().otherDataForm as CompanyLicenceType.OtherFormType; | |||
| state.value = false; | |||
| emit("quitEdit") | |||
| } | |||
| watch(() => [props.form_state], (newVal) => { | |||
| state.value = newVal[0]; | |||
| getBasic(); | |||
| }) | |||
| </script> | |||
| <style> | |||
| </style> | |||
| @@ -0,0 +1,10 @@ | |||
| declare namespace CompanyLicenceType { | |||
| type LicenceFormType = { | |||
| license_path?: String, | |||
| } | |||
| type OtherFormType = { | |||
| license_img?: String, | |||
| } | |||
| } | |||
| @@ -0,0 +1,43 @@ | |||
| export const cols = <ColType.type[]>[ | |||
| { | |||
| title: '职位名称', | |||
| dataIndex: 'name', | |||
| key: 'name', | |||
| }, | |||
| { | |||
| title: '所属部门', | |||
| dataIndex: 'department_name', | |||
| key: 'department_name', | |||
| }, | |||
| { | |||
| title: '状态', | |||
| dataIndex: 'status_text', | |||
| key: 'status_text', | |||
| }, | |||
| { | |||
| title: '招聘时间', | |||
| dataIndex: 'publish_date', | |||
| key: 'publish_date', | |||
| }, | |||
| { | |||
| title: '浏览数', | |||
| dataIndex: 'click_count', | |||
| key: 'click_count', | |||
| }, | |||
| { | |||
| title: '应聘简历(未看)', | |||
| dataIndex: 'apply_count_none_view', | |||
| key: 'apply_count_none_view', | |||
| }, | |||
| { | |||
| title: '推荐简历(未看)', | |||
| dataIndex: 'recommend_count_none_view', | |||
| key: 'recommend_count_none_view', | |||
| }, | |||
| { | |||
| title: '操作', | |||
| dataIndex: 'operation', | |||
| slots: { customRender: 'operation' }, | |||
| }, | |||
| ] | |||
| @@ -0,0 +1,167 @@ | |||
| <template> | |||
| <a-search @searchData="searchData" @clearData="clearData" :search_params="commomParams.search"></a-search> | |||
| <a-biaoge :data="commomParams.table.data" :columns="commomParams.table.columns" :pagination="commomParams.page" | |||
| @page="getPage" :loading="loading"> | |||
| <template #default="{ record }"> | |||
| <a-row :gutter="20"> | |||
| <a-col> | |||
| <a-dropdown placement="bottomRight"> | |||
| <template #overlay> | |||
| <a-menu> | |||
| <a-menu-item key="1"> | |||
| <a-button @click="edit(record)" block>修改</a-button> | |||
| </a-menu-item> | |||
| <!-- <a-menu-item key="2"> | |||
| <a-button @click="edit(record)" block>重新发布</a-button> | |||
| </a-menu-item> --> | |||
| <a-menu-item key="3"> | |||
| <a-button v-if="record.status == 1" @click="inviteStatus(record.id, 2)" block>暂停招聘</a-button> | |||
| <a-button v-if="record.status == 2" @click="inviteStatus(record.id, 1)" block>重新发布</a-button> | |||
| </a-menu-item> | |||
| <a-menu-item key="5"> | |||
| <a-button @click="putInRecycle(record.id)" block>放入回收站</a-button> | |||
| </a-menu-item> | |||
| <a-menu-item key="4"> | |||
| <a-button @click="del(record.id)" block>删除</a-button> | |||
| </a-menu-item> | |||
| </a-menu> | |||
| </template> | |||
| <a-button> | |||
| 操作 | |||
| <DownOutlined /> | |||
| </a-button> | |||
| </a-dropdown> | |||
| </a-col> | |||
| </a-row> | |||
| </template> | |||
| </a-biaoge> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, computed, defineEmits, createVNode } from 'vue'; | |||
| import { PostCompanyJobList, PostCompanyJobRecycle, PostCompanyJobStatusChange, PostCompanyJobDel} from '@/apis/models'; | |||
| import ASearch from '@/components/company/invite/manage/search.vue'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| import { cols } from '@/components/company/invite/manage/columns'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| import { DownOutlined } from '@ant-design/icons-vue'; | |||
| const emit = defineEmits(); | |||
| let { commomParams, ExclamationCircleOutlined, Modal } = useCommon(); | |||
| let loading = ref<Boolean>(true); | |||
| onMounted(() => { | |||
| getData(); | |||
| }) | |||
| const searchData = (data : object) => { | |||
| commomParams.value.search = data | |||
| getData(); | |||
| } | |||
| const clearData = (data : object) => { | |||
| if (data) { | |||
| commomParams.value.search = data | |||
| } else { | |||
| commomParams.value.search = { | |||
| page: 1, | |||
| pagesize: 10, | |||
| sort: 'id', | |||
| sortby: 'asc', | |||
| keyword: '' | |||
| } | |||
| } | |||
| getData(); | |||
| } | |||
| const getPage = (data : object) => { | |||
| commomParams.value.search.page = data.current; | |||
| commomParams.value.search.pagesize = data.pageSize; | |||
| getData(); | |||
| } | |||
| const getData = async () => { | |||
| try { | |||
| loading.value = true; | |||
| let res = await PostCompanyJobList(commomParams.value.search); | |||
| loading.value = false; | |||
| commomParams.value.table.data = res.data.list; | |||
| commomParams.value.table.columns = cols; | |||
| commomParams.value.page = { | |||
| current: commomParams.value.search.page, | |||
| pageSize: commomParams.value.search.pagesize, | |||
| total: res.data.total, | |||
| pageSizeOptions: ['10', '20', '30', '40'], | |||
| hideOnSinglePage: false, | |||
| showSizeChanger: true | |||
| }; | |||
| } catch { | |||
| loading.value = false; | |||
| } | |||
| } | |||
| // 修改 | |||
| const edit = (record : Object) => { | |||
| emit('toEdit', { record: record }) | |||
| } | |||
| // 放入回收站 | |||
| const inviteStatus = (id, num) => { | |||
| Modal.confirm({ | |||
| title: `是否要${num == 2 ? '暂停招聘' : '重新发布'}` , | |||
| centered: true, | |||
| icon: createVNode(ExclamationCircleOutlined), | |||
| onOk() { | |||
| PostCompanyJobStatusChange({ id: id, status:num }).then(res => { | |||
| successToast('保存成功') | |||
| getData(); | |||
| }) | |||
| }, | |||
| onCancel() { | |||
| }, | |||
| }); | |||
| } | |||
| // 放入回收站 | |||
| const putInRecycle = (id) => { | |||
| Modal.confirm({ | |||
| title: '是否要放入回收站', | |||
| centered: true, | |||
| icon: createVNode(ExclamationCircleOutlined), | |||
| onOk() { | |||
| PostCompanyJobRecycle({ id: id }).then(res => { | |||
| successToast('已放入回收站') | |||
| getData(); | |||
| }) | |||
| }, | |||
| onCancel() { | |||
| }, | |||
| }); | |||
| } | |||
| const del = (id : number) => { | |||
| commomParams.value.delParam = { id: id }; | |||
| Modal.confirm({ | |||
| title: '是否要删除该职位', | |||
| centered: true, | |||
| icon: createVNode(ExclamationCircleOutlined), | |||
| onOk() { | |||
| PostCompanyJobDel(commomParams.value.delParam).then(res => { | |||
| successToast('删除成功'); | |||
| getData(); | |||
| }) | |||
| }, | |||
| onCancel() { | |||
| }, | |||
| }); | |||
| } | |||
| </script> | |||
| <style scoped lang="less"> | |||
| </style> | |||
| @@ -0,0 +1,44 @@ | |||
| <template> | |||
| <a-form :model="commomParams.search"> | |||
| <a-row :gutter="20"> | |||
| <a-col span="12"> | |||
| <a-form-item> | |||
| <a-input-search v-model:value="commomParams.search.keyword" placeholder="请输入职位名称" enter-button="搜索" | |||
| @search="getData" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| </a-row> | |||
| </a-form> | |||
| </template> | |||
| <script lang="ts" setup> | |||
| import { ref, onMounted, watch, computed } from 'vue'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| let { commomParams } = useCommon(); | |||
| let props = defineProps(['search_params']); | |||
| const emit = defineEmits(); | |||
| watch(() => props.search_params, (newVal) => { | |||
| console.log(newVal) | |||
| }) | |||
| const getData = () => { | |||
| emit('searchData', commomParams.value.search) | |||
| } | |||
| // 清空搜索 | |||
| const clearSearch = () => { | |||
| commomParams.value.search = { | |||
| page: 1, | |||
| pagesize: 10, | |||
| sort: 'id', | |||
| sortby: 'asc', | |||
| keyword: '' | |||
| } | |||
| emit('clearData', commomParams.value.search) | |||
| } | |||
| </script> | |||
| <style> | |||
| </style> | |||
| @@ -0,0 +1,21 @@ | |||
| declare namespace CompanyInviteContactType { | |||
| type InviteContactFormType = { | |||
| contact: '', | |||
| possession: '', | |||
| phone: '', | |||
| phone_public: 2, | |||
| mobile: '', | |||
| mobile_public: 2, | |||
| email: '', | |||
| email_public: 2, | |||
| fax: '', | |||
| fax_public: 2, | |||
| other_address: '', | |||
| interview_address: '', | |||
| } | |||
| type OtherFormType = { | |||
| } | |||
| } | |||
| @@ -0,0 +1,41 @@ | |||
| export let dataForm = { | |||
| contact: '', | |||
| possession: '', | |||
| phone: '', | |||
| phone_public: 2, | |||
| mobile: '', | |||
| mobile_public: 2, | |||
| email: '', | |||
| email_public: 2, | |||
| fax: '', | |||
| fax_public: 2, | |||
| other_address: '', | |||
| interview_address: '', | |||
| } | |||
| export let otherDataForm = { | |||
| } | |||
| export const reset = () => { | |||
| dataForm = { | |||
| contact: '', | |||
| possession: '', | |||
| phone: '', | |||
| phone_public: 2, | |||
| mobile: '', | |||
| mobile_public: 2, | |||
| email: '', | |||
| email_public: 2, | |||
| fax: '', | |||
| fax_public: 2, | |||
| other_address: '', | |||
| interview_address: '', | |||
| } | |||
| otherDataForm = { | |||
| } | |||
| return { dataForm, otherDataForm } | |||
| } | |||
| @@ -0,0 +1,143 @@ | |||
| <template> | |||
| <a-card title="职位要求" :headStyle="{ 'background-color': '#f0f0f0' }"> | |||
| <a-form :model="createForm" layout="vertical"> | |||
| <a-row :gutter="20"> | |||
| <a-col span="12"> | |||
| <a-form-item required label="联系人" name="contact"> | |||
| <a-input v-model:value="createForm.contact" placeholder="请输入联系人" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="担任职位" name="possession"> | |||
| <a-input v-model:value="createForm.possession" placeholder="请输入联系人职位" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item required label="联系电话" name="phone"> | |||
| <a-input v-model:value="createForm.phone" placeholder="请输入联系电话" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="是否公开联系电话" name="phone_public"> | |||
| <a-radio-group v-model:value="createForm.phone_public" button-style="solid"> | |||
| <a-radio-button :value="1">是</a-radio-button> | |||
| <a-radio-button :value="2">否</a-radio-button> | |||
| </a-radio-group> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="手机" name="mobile"> | |||
| <a-input v-model:value="createForm.mobile" placeholder="请输入手机" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="是否公开手机" name="mobile_public"> | |||
| <a-radio-group v-model:value="createForm.mobile_public" button-style="solid"> | |||
| <a-radio-button :value="1">是</a-radio-button> | |||
| <a-radio-button :value="2">否</a-radio-button> | |||
| </a-radio-group> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="邮箱" name="email"> | |||
| <a-input v-model:value="createForm.email" placeholder="请输入邮箱" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="是否公开邮箱" name="email_public"> | |||
| <a-radio-group v-model:value="createForm.email_public" button-style="solid"> | |||
| <a-radio-button :value="1">是</a-radio-button> | |||
| <a-radio-button :value="2">否</a-radio-button> | |||
| </a-radio-group> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="传真" name="fax"> | |||
| <a-input v-model:value="createForm.fax" placeholder="请输入传真" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="是否公开传真" name="fax_public"> | |||
| <a-radio-group v-model:value="createForm.fax_public" button-style="solid"> | |||
| <a-radio-button :value="1">是</a-radio-button> | |||
| <a-radio-button :value="2">否</a-radio-button> | |||
| </a-radio-group> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="其他地址" name="other_address"> | |||
| <a-input v-model:value="createForm.other_address" placeholder="请输入其他地址" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="面试地址" name="interview_address"> | |||
| <a-input v-model:value="createForm.interview_address" placeholder="请输入面试地址" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-flex justify="flex-end"> | |||
| <a-space> | |||
| <a-button type="primary" @click="sumbitForm" size="large">发布招聘</a-button> | |||
| </a-space> | |||
| </a-flex> | |||
| </a-col> | |||
| </a-row> | |||
| </a-form> | |||
| </a-card> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, computed, watch, defineEmits, defineProps } from 'vue'; | |||
| import { PostCompanyJobAdd, PostCompanyJobEdit } from '@/apis/models'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| import { intersectionAlike } from '@/utils/dataHelper'; | |||
| import { dataForm, otherDataForm, reset } from '@/components/company/invite/position/contact/data.ts'; | |||
| const emit = defineEmits(); | |||
| const props = defineProps(['job_detail']); | |||
| let createForm = ref<CompanyInviteContactType.InviteContactFormType>(dataForm) | |||
| const job_id = ref<object>(null); | |||
| watch(() => [props.job_detail], async (newVal : string[], oldVal) => { | |||
| if (newVal[0]) { | |||
| job_id.value = newVal[0].id; | |||
| createForm.value.id = newVal[0].id; | |||
| createForm.value = intersectionAlike(createForm.value, newVal[0]); | |||
| } | |||
| }, { immediate: true }) | |||
| const sumbitForm = () => { | |||
| const newObject = { ...JSON.parse(sessionStorage.getItem('first')), ...JSON.parse(sessionStorage.getItem('second')), ...createForm.value } | |||
| console.log(newObject) | |||
| if(!job_id.value) { | |||
| PostCompanyJobAdd(newObject).then(res => { | |||
| successToast('保存成功'); | |||
| sessionStorage.removeItem('first') | |||
| sessionStorage.removeItem('firstOther') | |||
| sessionStorage.removeItem('second') | |||
| sessionStorage.removeItem('secondOther') | |||
| resetForm(); | |||
| }).catch(err => { | |||
| }) | |||
| } else { | |||
| PostCompanyJobEdit(newObject).then(res => { | |||
| successToast('编辑成功'); | |||
| sessionStorage.removeItem('first') | |||
| sessionStorage.removeItem('firstOther') | |||
| sessionStorage.removeItem('second') | |||
| sessionStorage.removeItem('secondOther') | |||
| resetForm(); | |||
| }).catch(err => { | |||
| }) | |||
| } | |||
| } | |||
| const resetForm = () => { | |||
| createForm.value = reset().dataForm as CompanyInviteDemandType.InviteDemandFormType; | |||
| } | |||
| </script> | |||
| <style> | |||
| </style> | |||
| @@ -0,0 +1,144 @@ | |||
| export const steps = [ | |||
| { | |||
| title: '基本信息', | |||
| content: 'First-content', | |||
| }, | |||
| { | |||
| title: '应聘要求', | |||
| content: 'Second-content', | |||
| }, | |||
| { | |||
| title: '联系方式', | |||
| content: 'Last-content', | |||
| }, | |||
| ]; | |||
| export let dataForm = { | |||
| urgent: 2, | |||
| department_id: 0, | |||
| name: '', | |||
| invite_count: '', | |||
| job_type: [], | |||
| job_location: [], | |||
| describe_text: '', | |||
| pay_range: 0, | |||
| useful_life: 0, | |||
| disabled_date: '', | |||
| key_word: '', | |||
| fulltime: 2, | |||
| parttime: 2, | |||
| casual: 2, | |||
| practical: 2, | |||
| campus: 2, | |||
| shisu: 0, | |||
| holidays: 0, | |||
| experience: 0, | |||
| school_degree: 0, | |||
| degree_better: 0, | |||
| profelevel: 0, | |||
| certification: 0, | |||
| language: 0, | |||
| language_degree: 0, | |||
| sex: 3, | |||
| age_min: 0, | |||
| age_max: 0, | |||
| marital_status: 3, | |||
| major: '', | |||
| license: [], | |||
| household_province: 0, | |||
| household_city: 0, | |||
| location_province: 0, | |||
| location_city: 0, | |||
| location_town: 0, | |||
| contact: '', | |||
| possession: '', | |||
| phone: '', | |||
| phone_public: 2, | |||
| mobile: '', | |||
| mobile_public: 2, | |||
| email: '', | |||
| email_public: 2, | |||
| fax: '', | |||
| fax_public: 2, | |||
| other_address: '', | |||
| interview_address: '', | |||
| } | |||
| export let otherDataForm = { | |||
| department_name: null, | |||
| describe_content: '', | |||
| daoqi_date: '', | |||
| job_nature: '', | |||
| pay_range_cascader: '', | |||
| shisu_select: '', | |||
| holidays_select: '', | |||
| company_jiguan_cascader: [], | |||
| company_suozaidi_cascader: [], | |||
| } | |||
| export const reset = () => { | |||
| dataForm = { | |||
| urgent: 2, | |||
| department_id: 0, | |||
| name: '', | |||
| invite_count: '', | |||
| job_type: [], | |||
| job_location: [], | |||
| describe_text: '', | |||
| pay_range: 0, | |||
| useful_life: 0, | |||
| disabled_date: '', | |||
| key_word: '', | |||
| fulltime: 2, | |||
| parttime: 2, | |||
| casual: 2, | |||
| practical: 2, | |||
| campus: 2, | |||
| shisu: 0, | |||
| holidays: 0, | |||
| experience: 0, | |||
| school_degree: 0, | |||
| degree_better: 0, | |||
| profelevel: 0, | |||
| certification: 0, | |||
| language: 0, | |||
| language_degree: 0, | |||
| sex: 3, | |||
| age_min: 0, | |||
| age_max: 0, | |||
| marital_status: 3, | |||
| major: '', | |||
| license: [], | |||
| household_province: 0, | |||
| household_city: 0, | |||
| location_province: 0, | |||
| location_city: 0, | |||
| location_town: 0, | |||
| contact: '', | |||
| possession: '', | |||
| phone: '', | |||
| phone_public: 2, | |||
| mobile: '', | |||
| mobile_public: 2, | |||
| email: '', | |||
| email_public: 2, | |||
| fax: '', | |||
| fax_public: 2, | |||
| other_address: '', | |||
| interview_address: '', | |||
| } | |||
| otherDataForm = { | |||
| department_name: null, | |||
| describe_content: '', | |||
| daoqi_date: '', | |||
| job_nature: '', | |||
| pay_range_cascader: '', | |||
| shisu_select: '', | |||
| holidays_select: '', | |||
| company_jiguan_cascader: [], | |||
| company_suozaidi_cascader: [], | |||
| } | |||
| return { dataForm, otherDataForm } | |||
| } | |||
| @@ -0,0 +1,55 @@ | |||
| export let dataForm = { | |||
| experience: 0, | |||
| school_degree: 0, | |||
| degree_better: 0, | |||
| profelevel: 0, | |||
| certification: 0, | |||
| language: 0, | |||
| language_degree: 0, | |||
| sex: 3, | |||
| age_min: 0, | |||
| age_max: 0, | |||
| marital_status: 3, | |||
| major: '', | |||
| license: [], | |||
| household_province: 0, | |||
| household_city: 0, | |||
| location_province: 0, | |||
| location_city: 0, | |||
| location_town: 0, | |||
| } | |||
| export let otherDataForm = { | |||
| company_jiguan_cascader: [], | |||
| company_suozaidi_cascader: [], | |||
| } | |||
| export const reset = () => { | |||
| dataForm = { | |||
| experience: 0, | |||
| school_degree: 0, | |||
| degree_better: 0, | |||
| profelevel: 0, | |||
| certification: 0, | |||
| language: 0, | |||
| language_degree: 0, | |||
| sex: 3, | |||
| age_min: 0, | |||
| age_max: 0, | |||
| marital_status: 3, | |||
| major: '', | |||
| license: [], | |||
| household_province: 0, | |||
| household_city: 0, | |||
| location_province: 0, | |||
| location_city: 0, | |||
| location_town: 0, | |||
| } | |||
| otherDataForm = { | |||
| company_jiguan_cascader: [], | |||
| company_suozaidi_cascader: [], | |||
| } | |||
| return { dataForm, otherDataForm } | |||
| } | |||
| @@ -0,0 +1,29 @@ | |||
| declare namespace CompanyInviteDemandType { | |||
| type InviteDemandFormType = { | |||
| urgent?: Number, | |||
| experience?: Number, | |||
| school_degree?: Number, | |||
| degree_better?: Number, | |||
| profelevel?: Number, | |||
| certification?: Number, | |||
| language?: Number, | |||
| language_degree?: Number, | |||
| sex?: Number, | |||
| age_min?: Number, | |||
| age_max?: Number, | |||
| marital_status?: Number, | |||
| major?: String, | |||
| license: [], | |||
| household_province?: Number, | |||
| household_city?: Number, | |||
| location_province?: Number, | |||
| location_city?: Number, | |||
| location_town?: Number, | |||
| } | |||
| type OtherFormType = { | |||
| company_jiguan_cascader: [], | |||
| company_suozaidi_cascader: [], | |||
| } | |||
| } | |||
| @@ -0,0 +1,74 @@ | |||
| <template> | |||
| <a-card title="职位要求" :headStyle="{ 'background-color': '#f0f0f0' }"> | |||
| <a-form :model="createForm" layout="vertical"> | |||
| <a-row :gutter="20"> | |||
| <a-col span="24"> | |||
| <a-flex justify="flex-end"> | |||
| <a-space> | |||
| <a-button type="primary" @click="sumbitForm" size="large">暂存</a-button> | |||
| </a-space> | |||
| </a-flex> | |||
| </a-col> | |||
| </a-row> | |||
| </a-form> | |||
| </a-card> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, computed, watch, defineEmits, defineProps } from 'vue'; | |||
| import { GetDictTree, PostCompanyJobAdd, alreadyValue } from '@/apis/models'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| import { intersectionAlike } from '@/utils/dataHelper'; | |||
| import { dataForm, otherDataForm, reset } from '@/components/company/invite/position/demand/data.ts'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| let { store, dayjs, richOption, ExclamationCircleOutlined, Modal } = useCommon(); | |||
| const dayjsRef = ref(dayjs); | |||
| const emit = defineEmits(); | |||
| const props = defineProps(['job_detail']); | |||
| let createForm = ref<CompanyInviteDemandType.InviteDemandFormType>(dataForm) | |||
| let addOtherForm = ref<CompanyInviteDemandType.OtherFormType>(otherDataForm) | |||
| const job_id = ref<object>(null); | |||
| let licenseOption = ref<Object[]>([]) | |||
| watch(() => [props.job_detail], async (newVal : string[], oldVal) => { | |||
| if (newVal[0]) { | |||
| job_id.value = newVal[0].id; | |||
| createForm.value = intersectionAlike(createForm.value, newVal[0]); | |||
| addOtherForm.value = { | |||
| company_jiguan_cascader: [newVal[0].household_province, newVal[0].household_city], | |||
| company_suozaidi_cascader: addToLocationArray(newVal[0]) | |||
| } | |||
| sessionStorage.setItem("second", JSON.stringify(createForm.value)) | |||
| sessionStorage.setItem("secondOther", JSON.stringify(addOtherForm.value)) | |||
| addOtherForm.value = sessionStorage.getItem('secondOther') ? JSON.parse(sessionStorage.getItem('secondOther')) : addOtherForm.value | |||
| createForm.value = sessionStorage.getItem('second') ? JSON.parse(sessionStorage.getItem('second')) : createForm.value | |||
| } | |||
| }, { immediate: true }) | |||
| onMounted(async () => { | |||
| }) | |||
| const sumbitForm = () => { | |||
| console.log(createForm.value) | |||
| sessionStorage.setItem("second", JSON.stringify(createForm.value)) | |||
| sessionStorage.setItem("secondOther", JSON.stringify(addOtherForm.value)) | |||
| } | |||
| const resetForm = () => { | |||
| createForm.value = reset().dataForm as CompanyInviteDemandType.InviteDemandFormType; | |||
| addOtherForm.value = reset().otherDataForm as CompanyInviteDemandType.OtherFormType; | |||
| } | |||
| </script> | |||
| <style> | |||
| </style> | |||
| @@ -0,0 +1,567 @@ | |||
| <template> | |||
| <a-card title="职位信息" :headStyle="{ 'background-color': '#f0f0f0' }"> | |||
| <a-form :model="createForm" layout="vertical"> | |||
| <a-steps :current="current" :items="steps"></a-steps> | |||
| <div class="steps-content"> | |||
| <div v-show="current == 0"> | |||
| <a-row :gutter="20"> | |||
| <a-col span="24"> | |||
| <a-form-item label="是否紧急" name="urgent"> | |||
| <a-radio-group v-model:value="createForm.urgent" button-style="solid"> | |||
| <a-radio-button :value="1">是</a-radio-button> | |||
| <a-radio-button :value="2">否</a-radio-button> | |||
| </a-radio-group> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="选择部门" name="department_id"> | |||
| <a-select v-model:value="addOtherForm.department_name" @change="departmentChange" | |||
| placeholder="请进行搜索选择部门" show-search :filter-option="false" label-in-value | |||
| @search="departmentSearch"> | |||
| <a-select-option v-for="item in department_list" :key="item.id" :value="item.id" | |||
| :label="item.name" label-in-value>{{item.name}}</a-select-option> | |||
| </a-select> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item required label="职位名称" name="name"> | |||
| <a-input v-model:value="createForm.name" placeholder="请输入职位名称" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="招聘人数" name="invite_count"> | |||
| <a-input v-model:value="createForm.invite_count" placeholder="请输入招聘人数" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item required label="职位类别"> | |||
| <a-shujilian :dict="2004" placeholder="职位类别(最多三个,多选只取前三)" @saveTreeNode="jobTypeChange" | |||
| :tree_content="createForm.job_type"></a-shujilian> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item required label="工作区域"> | |||
| <a-shujilian :dict="2009" placeholder="工作区域(最多四个,多选只取前四)" | |||
| @saveTreeNode="jobAddressChange" | |||
| :tree_content="createForm.job_location"></a-shujilian> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item required label="职位描述" name="describe_text"> | |||
| <QuillEditor theme="snow" :options="richOption" toolbar="full" | |||
| v-model:content="addOtherForm.describe_content" | |||
| @update:content="onEditorDescribeUpdate($event)" contentType="html" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="薪资范围" name="pay_range"> | |||
| <a-xuanze :dict="2005" placeholder="请选择月薪要求范围" @saveSelect="savePayRange" | |||
| :select_content="addOtherForm.pay_range_cascader"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item required label="有效天数" name="useful_life"> | |||
| <a-input-number :min="0" type="number" v-model:value="createForm.useful_life" | |||
| placeholder="请输入有效天数" style="width: 100%;" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item required label="到期日期"> | |||
| <a-date-picker v-model:value="addOtherForm.daoqi_date" @Change="disabledDateChange" | |||
| style="width: 100%;" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="关键词"> | |||
| <a-input v-model:value="createForm.key_word" placeholder="请输入关键词" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="职位性质"> | |||
| <a-radio-group v-model:value="addOtherForm.job_nature" button-style="solid" | |||
| @change="jobNatureChange" style="width: 100%;" size="large"> | |||
| <a-radio-button :value="1" style="width: 20%;">全职</a-radio-button> | |||
| <a-radio-button :value="2" style="width: 20%;">兼职</a-radio-button> | |||
| <a-radio-button :value="3" style="width: 20%;">临时</a-radio-button> | |||
| <a-radio-button :value="4" style="width: 20%;">实习</a-radio-button> | |||
| <a-radio-button :value="5" style="width: 20%;">校园招聘</a-radio-button> | |||
| </a-radio-group> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item required label="食宿要求"> | |||
| <a-xuanze :dict="2016" placeholder="请选择食宿要求" @saveSelect="saveShisu" | |||
| :select_content="addOtherForm.shisu_select"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item required label="节假日休息情况"> | |||
| <a-xuanze :dict="2017" placeholder="请选择节假日休息情况" @saveSelect="saveHolidays" | |||
| :select_content="addOtherForm.holidays_select"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| </a-row> | |||
| </div> | |||
| <div v-show="current == 1"> | |||
| <a-row gutter="20"> | |||
| <a-col span="12"> | |||
| <a-form-item required label="工作经验"> | |||
| <a-xuanze :dict="2021" placeholder="请选择工作经验" @saveSelect="saveExperience" | |||
| :select_content="createForm.experience"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="学历"> | |||
| <a-xuanze :dict="2006" placeholder="请选择学历" @saveSelect="saveSchoolDegree" | |||
| :select_content="createForm.school_degree"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="含最高学历" name="degree_better" style="width: 100%;" size="large"> | |||
| <a-radio-group v-model:value="createForm.degree_better" button-style="solid"> | |||
| <a-radio-button :value="1" style="width: 50%;">是</a-radio-button> | |||
| <a-radio-button :value="2" style="width: 50%;">否</a-radio-button> | |||
| </a-radio-group> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item required label="职称要求"> | |||
| <a-xuanze :dict="2006" placeholder="请选择职称要求" @saveSelect="saveProfelevel" | |||
| :select_content="createForm.profelevel"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item required label="技能认证"> | |||
| <a-xuanze :dict="2015" placeholder="请选择技能认证" @saveSelect="saveCertification" | |||
| :select_content="createForm.certification"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="语言要求"> | |||
| <a-xuanze :dict="2007" placeholder="请选择语言要求" @saveSelect="saveLanguage" | |||
| :select_content="createForm.language"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="掌握程度"> | |||
| <a-xuanze :dict="2007" placeholder="请选择掌握程度" @saveSelect="saveLanguageDegree" | |||
| :select_content="createForm.language_degree"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="性别要求" name="sex"> | |||
| <a-radio-group v-model:value="createForm.sex" button-style="solid" style="width: 100%;" size="large"> | |||
| <a-radio-button :value="1" style="width: calc(100% / 3);">男</a-radio-button> | |||
| <a-radio-button :value="2" style="width: calc(100% / 3);">女</a-radio-button> | |||
| <a-radio-button :value="3" style="width: calc(100% / 3);">不限</a-radio-button> | |||
| </a-radio-group> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="最小年龄" name="age_min"> | |||
| <a-input-number :min="0" type="number" v-model:value="createForm.age_min" | |||
| placeholder="请输入最小年龄" style="width: 100%;" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="最大年龄" name="age_max"> | |||
| <a-input-number :min="0" type="number" v-model:value="createForm.age_max" | |||
| placeholder="请输入最大年龄" style="width: 100%;" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item required label="婚姻状况" name="marital_status"> | |||
| <a-radio-group v-model:value="createForm.marital_status" button-style="solid" style="width: 100%;" size="large"> | |||
| <a-radio-button :value="1" style="width: calc(100% / 3);">已婚</a-radio-button> | |||
| <a-radio-button :value="2" style="width: calc(100% / 3);">未婚</a-radio-button> | |||
| <a-radio-button :value="3" style="width: calc(100% / 3);">不限</a-radio-button> | |||
| </a-radio-group> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item required label="专业" name="major"> | |||
| <a-input v-model:value="createForm.major" placeholder="请输入专业" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="证书要求"> | |||
| <a-checkbox-group v-model:value="createForm.license" size="large"> | |||
| <a-row> | |||
| <template v-for="(item, index) in licenseOption"> | |||
| <a-col span="8"> | |||
| <a-checkbox :value="item.id" size="large">{{item.name}}</a-checkbox> | |||
| </a-col> | |||
| </template> | |||
| </a-row> | |||
| </a-checkbox-group> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="籍贯要求" name="mandarin"> | |||
| <a-jilian :dict="2009" @saveCascader="compantJiguanSave" placeholder="请选择籍贯" | |||
| :cascader_content="addOtherForm.company_jiguan_cascader"></a-jilian> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="所在地要求" name="mandarin"> | |||
| <a-jilian :dict="2009" @saveCascader="compantSuozaidiSave" placeholder="请选择所在地" | |||
| :cascader_content="addOtherForm.company_suozaidi_cascader"></a-jilian> | |||
| </a-form-item> | |||
| </a-col> | |||
| </a-row> | |||
| </div> | |||
| <div v-show="current == 2"> | |||
| <a-row gutter="20"> | |||
| <a-col span="12"> | |||
| <a-form-item required label="联系人" name="contact"> | |||
| <a-input v-model:value="createForm.contact" placeholder="请输入联系人" size="large"/> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="担任职位" name="possession"> | |||
| <a-input v-model:value="createForm.possession" placeholder="请输入联系人职位" size="large"/> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item required label="联系电话" name="phone"> | |||
| <a-input v-model:value="createForm.phone" placeholder="请输入联系电话" size="large"/> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="是否公开联系电话" name="phone_public"> | |||
| <a-radio-group v-model:value="createForm.phone_public" button-style="solid" style="width: 100%;" size="large"> | |||
| <a-radio-button :value="1" style="width: 50%;">是</a-radio-button> | |||
| <a-radio-button :value="2" style="width: 50%;">否</a-radio-button> | |||
| </a-radio-group> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="手机" name="mobile"> | |||
| <a-input v-model:value="createForm.mobile" placeholder="请输入手机" size="large"/> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="是否公开手机" name="mobile_public"> | |||
| <a-radio-group v-model:value="createForm.mobile_public" button-style="solid" style="width: 100%;" size="large"> | |||
| <a-radio-button :value="1" style="width: 50%;">是</a-radio-button> | |||
| <a-radio-button :value="2" style="width: 50%;">否</a-radio-button> | |||
| </a-radio-group> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="邮箱" name="email"> | |||
| <a-input v-model:value="createForm.email" placeholder="请输入邮箱" size="large"/> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="是否公开邮箱" name="email_public"> | |||
| <a-radio-group v-model:value="createForm.email_public" button-style="solid" style="width: 100%;" size="large"> | |||
| <a-radio-button :value="1" style="width: 50%;">是</a-radio-button> | |||
| <a-radio-button :value="2" style="width: 50%;">否</a-radio-button> | |||
| </a-radio-group> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="传真" name="fax"> | |||
| <a-input v-model:value="createForm.fax" placeholder="请输入传真" size="large"/> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="是否公开传真" name="fax_public"> | |||
| <a-radio-group v-model:value="createForm.fax_public" button-style="solid" style="width: 100%;" size="large"> | |||
| <a-radio-button :value="1" style="width: 50%;">是</a-radio-button> | |||
| <a-radio-button :value="2" style="width: 50%;">否</a-radio-button> | |||
| </a-radio-group> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="其他地址" name="other_address"> | |||
| <a-input v-model:value="createForm.other_address" placeholder="请输入其他地址" size="large"/> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="面试地址" name="interview_address"> | |||
| <a-input v-model:value="createForm.interview_address" placeholder="请输入面试地址" size="large"/> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-flex justify="flex-end"> | |||
| <a-space> | |||
| <a-button type="primary" @click="sumbitForm" size="large">发布招聘</a-button> | |||
| </a-space> | |||
| </a-flex> | |||
| </a-col> | |||
| </a-row> | |||
| </div> | |||
| </div> | |||
| <div class="steps-action"> | |||
| <a-button v-if="current > 0" @click="prev">上一步</a-button> | |||
| <a-button v-if="current < steps.length - 1" type="primary" style="margin-left: 12px" | |||
| @click="next">下一步</a-button> | |||
| </div> | |||
| </a-form> | |||
| </a-card> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, computed, defineProps, watch, defineEmits } from 'vue'; | |||
| import { PostCompanyJobAdd, PostCompanyJobEdit, GetDictTree, GetCompanyDepartmentList, GetCompanyJobInfo } from '@/apis/models'; | |||
| import { intersectionAlike } from '@/utils/dataHelper'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| import { steps, dataForm, otherDataForm, reset } from '@/components/company/invite/position/data.ts'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| let { store, dayjs, richOption, message } = useCommon(); | |||
| const dayjsRef = ref(dayjs); | |||
| let props = defineProps(['job_id']); | |||
| const emit = defineEmits(); | |||
| const current = ref<number>(0); | |||
| const next = () => { | |||
| current.value++; | |||
| }; | |||
| const prev = () => { | |||
| current.value--; | |||
| }; | |||
| const options = ref(richOption) | |||
| const job_id = ref<object>(null); | |||
| let licenseOption = ref<Object[]>([]) | |||
| let createForm = ref(dataForm) | |||
| let addOtherForm = ref(otherDataForm) | |||
| onMounted(async () => { | |||
| departmentSearch() | |||
| let res = await GetDictTree({ code: 2018 }) | |||
| licenseOption.value = res.data.dicts; | |||
| }) | |||
| // 选择部门 | |||
| let department_list = ref<Object[]>([]) | |||
| const departmentSearch = (val) => { | |||
| GetCompanyDepartmentList({ keyword: val }).then(res => { | |||
| department_list.value = res.data.rows; | |||
| }) | |||
| } | |||
| const departmentChange = (val : Object) => { | |||
| addOtherForm.value.department_name = val.option.label; | |||
| createForm.value.department_id = val.key; | |||
| } | |||
| // 职位类别 | |||
| const jobTypeChange = (data) => { | |||
| console.log(data) | |||
| createForm.value.job_type = data.arr1.slice(0, 3); | |||
| } | |||
| // 工作区域 | |||
| const jobAddressChange = (data) => { | |||
| createForm.value.job_location = data.arr1.slice(0, 4); | |||
| } | |||
| // 职位描述 | |||
| const onEditorDescribeUpdate = (data) => { | |||
| createForm.value.describe_text = data | |||
| } | |||
| // 薪资范围 | |||
| const savePayRange = (data) => { | |||
| addOtherForm.value.pay_range_cascader = data.val.option.label; | |||
| createForm.value.pay_range = data.val.key; | |||
| } | |||
| // 到期日期 | |||
| const disabledDateChange = (val) => { | |||
| createForm.value.disabled_date = dayjsRef.value(val).format('YYYY-MM-DD'); | |||
| console.log(createForm.value.disabled_date) | |||
| } | |||
| const jobNatureChange = (val) => { | |||
| switch (val.target.value) { | |||
| case 1: | |||
| createForm.value.fulltime = 1; | |||
| createForm.value.parttime = 2; | |||
| createForm.value.casual = 2; | |||
| createForm.value.practical = 2; | |||
| createForm.value.campus = 2; | |||
| break; | |||
| case 2: | |||
| createForm.value.fulltime = 2; | |||
| createForm.value.parttime = 1; | |||
| createForm.value.casual = 2; | |||
| createForm.value.practical = 2; | |||
| createForm.value.campus = 2; | |||
| break; | |||
| case 3: | |||
| createForm.value.fulltime = 2; | |||
| createForm.value.parttime = 2; | |||
| createForm.value.casual = 1; | |||
| createForm.value.practical = 2; | |||
| createForm.value.campus = 2; | |||
| break; | |||
| case 4: | |||
| createForm.value.fulltime = 2; | |||
| createForm.value.parttime = 2; | |||
| createForm.value.casual = 2; | |||
| createForm.value.practical = 1; | |||
| createForm.value.campus = 2; | |||
| break; | |||
| case 5: | |||
| createForm.value.fulltime = 2; | |||
| createForm.value.parttime = 2; | |||
| createForm.value.casual = 2; | |||
| createForm.value.practical = 2; | |||
| createForm.value.campus = 1; | |||
| break; | |||
| } | |||
| } | |||
| // 食宿要求 | |||
| const saveShisu = (data) => { | |||
| addOtherForm.value.shisu_select = data.val.option.label; | |||
| createForm.value.shisu = data.val.key; | |||
| } | |||
| // 节假日要求 | |||
| const saveHolidays = (data) => { | |||
| addOtherForm.value.holidays_select = data.val.option.label; | |||
| createForm.value.holidays = data.val.key; | |||
| } | |||
| // 工作经验 | |||
| const saveExperience = (data) => { | |||
| createForm.value.experience = data.val.key; | |||
| } | |||
| // 学历要求 | |||
| const saveSchoolDegree = (data) => { | |||
| createForm.value.school_degree = data.val.key; | |||
| } | |||
| // 职称要求 | |||
| const saveProfelevel = (data) => { | |||
| createForm.value.profelevel = data.val.key; | |||
| } | |||
| // 技能认证 | |||
| const saveCertification = (data) => { | |||
| createForm.value.certification = data.val.key; | |||
| } | |||
| // 语言要求 | |||
| const saveLanguage = (data) => { | |||
| createForm.value.language = data.val.key; | |||
| } | |||
| // 掌握程度 | |||
| const saveLanguageDegree = (data) => { | |||
| createForm.value.language_degree = data.val.key; | |||
| } | |||
| // 选择籍贯 | |||
| const compantJiguanSave = (data) => { | |||
| addOtherForm.value.company_jiguan_cascader = data.arr1; | |||
| createForm.value.household_province = data.arr1[0] ? data.arr1[0] : 0; | |||
| createForm.value.household_city = data.arr1[1] ? data.arr1[1] : 0; | |||
| } | |||
| // 选择所在地 | |||
| const compantSuozaidiSave = (data) => { | |||
| addOtherForm.value.company_suozaidi_cascader = data.arr1; | |||
| createForm.value.location_province = data.arr1[0] ? data.arr1[0] : 0; | |||
| createForm.value.location_city = data.arr1[1] ? data.arr1[1] : 0; | |||
| createForm.value.location_town = data.arr1[2] ? data.arr1[2] : 0; | |||
| } | |||
| const sumbitForm = () => { | |||
| if (!job_id.value) { | |||
| PostCompanyJobAdd(createForm.value).then(res => { | |||
| successToast('保存成功'); | |||
| resetForm(); | |||
| }).catch(err => { | |||
| }) | |||
| } else { | |||
| PostCompanyJobEdit(createForm.value).then(res => { | |||
| successToast('编辑成功'); | |||
| resetForm(); | |||
| }).catch(err => { | |||
| }) | |||
| } | |||
| } | |||
| const resetForm = () => { | |||
| addOtherForm.value = reset().otherDataForm; | |||
| createForm.value = reset().dataForm; | |||
| emit('send') | |||
| } | |||
| const addToLocationArray = (data) => { | |||
| let locationArray = []; | |||
| if (data.location_province !== 0) { | |||
| locationArray.push(data.location_province); | |||
| } | |||
| if (data.location_city !== 0) { | |||
| locationArray.push(data.location_city); | |||
| } | |||
| if (data.location_town !== 0) { | |||
| locationArray.push(data.location_town); | |||
| } | |||
| return locationArray; | |||
| } | |||
| watch(() => props.job_id, (newVal) => { | |||
| job_id.value = newVal; | |||
| if (newVal) { | |||
| GetCompanyJobInfo({ id: job_id.value }).then(res => { | |||
| let resData = res.data; | |||
| createForm.value = intersectionAlike(createForm.value, resData); | |||
| createForm.value.id = resData.id; | |||
| addOtherForm.value = { | |||
| department_name: resData.department_id, | |||
| describe_content: resData.describe_text, | |||
| daoqi_date: dayjsRef.value(resData.disabled_date), | |||
| pay_range_cascader: resData.pay_range, | |||
| shisu_select: resData.shisu, | |||
| holidays_select: resData.holidays, | |||
| company_jiguan_cascader: [resData.household_province, resData.household_city], | |||
| company_suozaidi_cascader: addToLocationArray(resData) | |||
| } | |||
| if (resData.fulltime == 1) { | |||
| addOtherForm.value.job_nature = 1 | |||
| } else if (resData.parttime == 1) { | |||
| addOtherForm.value.job_nature = 2 | |||
| } else if (resData.casual == 1) { | |||
| addOtherForm.value.job_nature = 3 | |||
| } else if (resData.practical == 1) { | |||
| addOtherForm.value.job_nature = 4 | |||
| } else if (resData.campus == 1) { | |||
| addOtherForm.value.job_nature = 5 | |||
| } | |||
| }) | |||
| } | |||
| }, { immediate: true }) | |||
| </script> | |||
| <style scoped> | |||
| .steps-content { | |||
| margin-top: 16px; | |||
| border: 1px dashed #e9e9e9; | |||
| border-radius: 6px; | |||
| background-color: #fafafa; | |||
| min-height: 200px; | |||
| padding: 20px; | |||
| } | |||
| .steps-action { | |||
| margin-top: 12px; | |||
| } | |||
| </style> | |||
| @@ -0,0 +1,65 @@ | |||
| export let dataForm = { | |||
| urgent: 2, | |||
| department_id: 0, | |||
| name: '', | |||
| invite_count: '', | |||
| job_type: [], | |||
| job_location: [], | |||
| describe_text: '', | |||
| pay_range: 0, | |||
| useful_life: 0, | |||
| disabled_date: '', | |||
| key_word: '', | |||
| fulltime: 2, | |||
| parttime: 2, | |||
| casual: 2, | |||
| practical: 2, | |||
| campus: 2, | |||
| shisu: 0, | |||
| holidays: 0, | |||
| } | |||
| export let otherDataForm = { | |||
| department_name: null, | |||
| describe_content: '', | |||
| daoqi_date: '', | |||
| job_nature: '', | |||
| pay_range_cascader: '', | |||
| shisu_select: '', | |||
| holidays_select: '', | |||
| } | |||
| export const reset = () => { | |||
| dataForm = { | |||
| urgent: 2, | |||
| department_id: 0, | |||
| name: '', | |||
| invite_count: '', | |||
| job_type: [], | |||
| job_location: [], | |||
| describe_text: '', | |||
| pay_range: 0, | |||
| useful_life: 0, | |||
| disabled_date: '', | |||
| key_word: '', | |||
| fulltime: 2, | |||
| parttime: 2, | |||
| casual: 2, | |||
| practical: 2, | |||
| campus: 2, | |||
| shisu: 0, | |||
| holidays: 0, | |||
| } | |||
| otherDataForm = { | |||
| department_name: null, | |||
| describe_content: '', | |||
| daoqi_date: '', | |||
| job_nature: '', | |||
| pay_range_cascader: '', | |||
| shisu_select: '', | |||
| holidays_select: '', | |||
| } | |||
| return { dataForm, otherDataForm } | |||
| } | |||
| @@ -0,0 +1,62 @@ | |||
| <template> | |||
| <a-card title="职位信息" :headStyle="{ 'background-color': '#f0f0f0' }"> | |||
| <a-form :model="createForm" layout="vertical"> | |||
| <a-row :gutter="20"> | |||
| <a-col span="24"> | |||
| <a-flex justify="flex-end"> | |||
| <a-space> | |||
| <a-button type="primary" @click="sumbitForm" size="large">暂存</a-button> | |||
| </a-space> | |||
| </a-flex> | |||
| </a-col> | |||
| </a-row> | |||
| </a-form> | |||
| </a-card> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, computed, watch, defineEmits, defineProps } from 'vue'; | |||
| import { GetDictTree, GetCompanyDepartmentList, PostCompanyJobAdd } from '@/apis/models'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| import { intersectionAlike } from '@/utils/dataHelper'; | |||
| import { dataForm, otherDataForm, reset } from '@/components/company/invite/position/info/data.ts'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| let { store, dayjs, richOption, ExclamationCircleOutlined, Modal } = useCommon(); | |||
| const dayjsRef = ref(dayjs); | |||
| const emit = defineEmits(); | |||
| const props = defineProps(['job_detail']); | |||
| let createForm = ref<CompanyInviteInfoType.InviteInfoFormType>(dataForm) | |||
| let addOtherForm = ref<CompanyInviteInfoType.OtherFormType>(otherDataForm) | |||
| const job_id = ref<object>(null); | |||
| const sumbitForm = () => { | |||
| sessionStorage.setItem("first", JSON.stringify(createForm.value)) | |||
| sessionStorage.setItem("firstOther", JSON.stringify(addOtherForm.value)) | |||
| } | |||
| const resetForm = () => { | |||
| createForm.value = reset().dataForm as CompanyInviteInfoType.InviteInfoFormType; | |||
| addOtherForm.value = reset().otherDataForm as CompanyInviteInfoType.OtherFormType; | |||
| } | |||
| watch(() => [props.job_detail], async (newVal : string[], oldVal) => { | |||
| if (newVal[0]) { | |||
| job_id.value = newVal[0].id; | |||
| sessionStorage.setItem("first", JSON.stringify(createForm.value)) | |||
| sessionStorage.setItem("firstOther", JSON.stringify(addOtherForm.value)) | |||
| } else { | |||
| addOtherForm.value = sessionStorage.getItem('firstOther') ? JSON.parse(sessionStorage.getItem('firstOther')) : addOtherForm.value | |||
| addOtherForm.value.daoqi_date = addOtherForm.value.daoqi_date ? dayjsRef.value(addOtherForm.value.daoqi_date) : '' | |||
| createForm.value = sessionStorage.getItem('first') ? JSON.parse(sessionStorage.getItem('first')) : createForm.value | |||
| } | |||
| }, { immediate: true }) | |||
| </script> | |||
| <style> | |||
| </style> | |||
| @@ -0,0 +1,33 @@ | |||
| declare namespace CompanyInviteInfoType { | |||
| type InviteInfoFormType = { | |||
| urgent?: Number, | |||
| department_id?: Number, | |||
| name?: String, | |||
| invite_count?: String, | |||
| job_type: [], | |||
| job_location: [], | |||
| describe_text?: String, | |||
| pay_range?: Number, | |||
| useful_life?: Number, | |||
| disabled_date?: String, | |||
| key_word?: String, | |||
| fulltime?: Number, | |||
| parttime?: Number, | |||
| casual?: Number, | |||
| practical?: Number, | |||
| campus?: Number, | |||
| shisu?: Number, | |||
| holidays?: Number, | |||
| } | |||
| type OtherFormType = { | |||
| department_name?: String, | |||
| describe_content?: String, | |||
| daoqi_date?: String, | |||
| job_nature?: String, | |||
| pay_range_cascader?: String, | |||
| shisu_select?: String, | |||
| holidays_select?: String, | |||
| } | |||
| } | |||
| @@ -0,0 +1,43 @@ | |||
| export const cols = <ColType.type[]>[ | |||
| { | |||
| title: '职位名称', | |||
| dataIndex: 'name', | |||
| key: 'name', | |||
| }, | |||
| { | |||
| title: '所属部门', | |||
| dataIndex: 'department_name', | |||
| key: 'department_name', | |||
| }, | |||
| { | |||
| title: '状态', | |||
| dataIndex: 'status_text', | |||
| key: 'status_text', | |||
| }, | |||
| { | |||
| title: '招聘时间', | |||
| dataIndex: 'publish_date', | |||
| key: 'publish_date', | |||
| }, | |||
| { | |||
| title: '浏览数', | |||
| dataIndex: 'click_count', | |||
| key: 'click_count', | |||
| }, | |||
| { | |||
| title: '应聘简历(未看)', | |||
| dataIndex: 'apply_count_none_view', | |||
| key: 'apply_count_none_view', | |||
| }, | |||
| { | |||
| title: '推荐简历(未看)', | |||
| dataIndex: 'recommend_count_none_view', | |||
| key: 'recommend_count_none_view', | |||
| }, | |||
| { | |||
| title: '操作', | |||
| dataIndex: 'operation', | |||
| slots: { customRender: 'operation' }, | |||
| }, | |||
| ] | |||
| @@ -0,0 +1,123 @@ | |||
| <template> | |||
| <a-biaoge :data="commomParams.table.data" :columns="commomParams.table.columns" :pagination="commomParams.page" | |||
| @page="getPage" :loading="loading"> | |||
| <template #default="{ record }"> | |||
| <a-row :gutter="20"> | |||
| <a-col> | |||
| <a-dropdown placement="bottomRight"> | |||
| <template #overlay> | |||
| <a-menu> | |||
| <a-menu-item key="1"> | |||
| <a-button @click="popInRecycle(record.id)">移出回收站</a-button> | |||
| </a-menu-item> | |||
| </a-menu> | |||
| </template> | |||
| <a-button> | |||
| 操作 | |||
| <DownOutlined /> | |||
| </a-button> | |||
| </a-dropdown> | |||
| </a-col> | |||
| </a-row> | |||
| </template> | |||
| </a-biaoge> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, computed, defineEmits, createVNode } from 'vue'; | |||
| import { GetCompanyJobRecycleList, PostCompanyJobRecoverRecycle } from '@/apis/models'; | |||
| import ASearch from '@/components/company/invite/manage/search.vue'; | |||
| import { cols } from '@/components/company/invite/manage/columns'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| import { DownOutlined } from '@ant-design/icons-vue'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| let { commomParams, ExclamationCircleOutlined, Modal } = useCommon(); | |||
| const emit = defineEmits(); | |||
| let loading = ref<Boolean>(true); | |||
| onMounted(() => { | |||
| getData(); | |||
| }) | |||
| const searchData = (data : object) => { | |||
| commomParams.value.search = data | |||
| getData(); | |||
| } | |||
| const clearData = (data : object) => { | |||
| if (data) { | |||
| commomParams.value.search = data | |||
| } else { | |||
| commomParams.value.search = { | |||
| page: 1, | |||
| pagesize: 10, | |||
| sort: 'id', | |||
| sortby: 'asc', | |||
| keyword: '' | |||
| } | |||
| } | |||
| getData(); | |||
| } | |||
| const getPage = (data : object) => { | |||
| commomParams.value.search.page = data.current; | |||
| commomParams.value.search.pagesize = data.pageSize; | |||
| getData(); | |||
| } | |||
| const getData = async () => { | |||
| try { | |||
| loading.value = true; | |||
| let res = await GetCompanyJobRecycleList(commomParams.value.search); | |||
| loading.value = false; | |||
| commomParams.value.table.data = res.data.list; | |||
| commomParams.value.table.columns = cols; | |||
| commomParams.value.page = { | |||
| current: commomParams.value.search.page, | |||
| pageSize: commomParams.value.search.pagesize, | |||
| total: res.data.total, | |||
| pageSizeOptions: ['10', '20', '30', '40'], | |||
| hideOnSinglePage: false, | |||
| showSizeChanger: true | |||
| }; | |||
| } catch { | |||
| loading.value = false; | |||
| } | |||
| } | |||
| // 修改 | |||
| const edit = (record : Object) => { | |||
| emit('toEdit', { record: record }) | |||
| } | |||
| // 移除回收站 | |||
| const popInRecycle = (id) => { | |||
| Modal.confirm({ | |||
| title: '是否要移出回收站', | |||
| centered: true, | |||
| icon: createVNode(ExclamationCircleOutlined), | |||
| onOk() { | |||
| PostCompanyJobRecoverRecycle({ id: id }).then(res => { | |||
| successToast('已移出回收站') | |||
| getData(); | |||
| }) | |||
| }, | |||
| onCancel() { | |||
| }, | |||
| }); | |||
| } | |||
| // const del = (id : number) => { | |||
| // commomParams.value.delParam = { id: id }; | |||
| // PostCompanyDepartmentDel(commomParams.value.delParam).then(res => { | |||
| // successToast('删除成功'); | |||
| // getData(); | |||
| // }) | |||
| // } | |||
| </script> | |||
| <style scoped lang="less"> | |||
| </style> | |||
| @@ -3,7 +3,7 @@ | |||
| <a-row :gutter="20"> | |||
| <a-col span="12"> | |||
| <a-form-item> | |||
| <a-input-search v-model:value="commomParams.search.keyword" placeholder="请输入部门名称" enter-button="搜索" | |||
| <a-input-search v-model:value="commomParams.search.keyword" placeholder="请输入职位名称" enter-button="搜索" | |||
| @search="getData" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| @@ -1,76 +0,0 @@ | |||
| <template> | |||
| <a-form :model="createForm" :label-col="{span: 6}" labelAlign="right"> | |||
| <a-row gutter="20"> | |||
| <a-col span="12"> | |||
| <a-row> | |||
| <a-col span="24"> | |||
| <a-form-item label="上传营业执照" name="photo"> | |||
| <upload upload_txt="上传营业执照" @uploadSuccess="uploadPhotoSuccess" | |||
| :success_image="addOtherForm.license_img" images_length="1" image_type="4"></upload> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="保存"> | |||
| <a-button type="primary" block @click="saveForm">保存</a-button> | |||
| </a-form-item> | |||
| </a-col> | |||
| </a-row> | |||
| </a-col> | |||
| </a-row> | |||
| </a-form> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, computed } from 'vue'; | |||
| import { PostCompanyDetailInfo, PostCompanyLicenseUpload } from '@/apis/models'; | |||
| import Upload from '@/components/form/upload.vue'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| let createForm = ref({ | |||
| license_path: '', | |||
| }) | |||
| let addOtherForm = ref({ | |||
| license_img: '', | |||
| }) | |||
| onMounted(async () => { | |||
| getBasic() | |||
| // let res = await listSection({ page: 1, pagesize: 10, sort: 'id', sortby: "asc", keyword: "" }); | |||
| // section_list.value = res.data.sections; | |||
| }) | |||
| const getBasic = () => { | |||
| PostCompanyDetailInfo().then(res => { | |||
| createForm.value.license_path = res.data.license_path | |||
| addOtherForm.value = { | |||
| license_img: "https://rcsc-test.jcjob.cn/img/" + res.data.license_path, | |||
| } | |||
| }) | |||
| } | |||
| // 营业执照 | |||
| const uploadPhotoSuccess = (data : Object) => { | |||
| addOtherForm.value.license_img = "https://rcsc-test.jcjob.cn/img/" + data | |||
| createForm.value.license_path = data | |||
| } | |||
| const saveForm = () => { | |||
| PostCompanyLicenseUpload(createForm.value).then(res => { | |||
| successToast('保存成功') | |||
| resetForm(); | |||
| getBasic(); | |||
| }) | |||
| } | |||
| const resetForm = () => { | |||
| addOtherForm = { | |||
| license_img: '', | |||
| } | |||
| createForm.value = { | |||
| license_path: '' | |||
| } | |||
| } | |||
| </script> | |||
| <style> | |||
| </style> | |||
| @@ -0,0 +1,16 @@ | |||
| export const cols = <ColType.type[]>[ | |||
| { | |||
| title: '招聘会名称', | |||
| dataIndex: 'title' | |||
| }, { | |||
| title: '地点', | |||
| dataIndex: 'address' | |||
| }, { | |||
| title: '开始时间', | |||
| dataIndex: 'open_date' | |||
| }, { | |||
| title: '审核状态', | |||
| dataIndex: 'status_text' | |||
| } | |||
| ] | |||
| @@ -0,0 +1,84 @@ | |||
| <template> | |||
| <a-biaoge :data="commomParams.table.data" :columns="commomParams.table.columns" :pagination="commomParams.page" | |||
| @page="getPage" :loading="loading"> | |||
| </a-biaoge> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, computed } from 'vue'; | |||
| import {PostCompanyRecrBookList } from '@/apis/models'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| import { cols } from '@/components/company/meet/result/columns'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| let { commomParams } = useCommon(); | |||
| let loading = ref<Boolean>(true); | |||
| onMounted(() => { | |||
| getData(commomParams.value.search); | |||
| }) | |||
| const searchData = (data : object) => { | |||
| commomParams.value.search = data | |||
| getData(); | |||
| } | |||
| const clearData = (data : object) => { | |||
| if (data) { | |||
| commomParams.value.search = data | |||
| } else { | |||
| commomParams.value.search = { | |||
| page: 1, | |||
| pagesize: 10, | |||
| sort: 'id', | |||
| sortby: 'asc', | |||
| keyword: '' | |||
| } | |||
| } | |||
| getData(); | |||
| } | |||
| const getPage = (data : object) => { | |||
| commomParams.value.search.page = data.current; | |||
| commomParams.value.search.pagesize = data.pageSize; | |||
| getData(); | |||
| } | |||
| const getData = async () => { | |||
| try { | |||
| loading.value = true; | |||
| let res = await PostCompanyRecrBookList(); | |||
| loading.value = false; | |||
| commomParams.value.table.data = res.data.list; | |||
| commomParams.value.table.columns = cols; | |||
| commomParams.value.page = { | |||
| current: commomParams.value.search.page, | |||
| pageSize: commomParams.value.search.pagesize, | |||
| total: res.data.total, | |||
| pageSizeOptions: ['10', '20', '30', '40'], | |||
| hideOnSinglePage: false, | |||
| showSizeChanger: true | |||
| }; | |||
| } catch { | |||
| loading.value = false; | |||
| } | |||
| } | |||
| // 申请 | |||
| const applyFor = (val) => { | |||
| PostRecruitmentbookAdd({ recruitment_id: val, company_id: 0}).then(res => { | |||
| successToast('预定成功') | |||
| }) | |||
| } | |||
| // 详情 | |||
| let detailData = ref<object>({}) | |||
| const toDetail = (val) => { | |||
| PostRecruitmentbookAdd({ id: val}).then(res => { | |||
| detailData.value = res.data | |||
| }) | |||
| } | |||
| </script> | |||
| <style scoped lang="less"> | |||
| </style> | |||
| @@ -0,0 +1,21 @@ | |||
| export const cols = <ColType.type[]>[ | |||
| { | |||
| title: '招聘会名称', | |||
| dataIndex: 'title' | |||
| }, { | |||
| title: '地点', | |||
| dataIndex: 'address' | |||
| }, { | |||
| title: '开始时间', | |||
| dataIndex: 'open_date' | |||
| }, { | |||
| title: '开通状态', | |||
| dataIndex: 'status' | |||
| }, | |||
| { | |||
| title: '操作', | |||
| dataIndex: 'operation', | |||
| slots: { customRender: 'operation' }, | |||
| }, | |||
| ] | |||
| @@ -0,0 +1,105 @@ | |||
| <template> | |||
| <a-search @searchData="searchData" @clearData="clearData" :search_params="commomParams.search"></a-search> | |||
| <a-biaoge :data="commomParams.table.data" :columns="commomParams.table.columns" :pagination="commomParams.page" | |||
| @page="getPage" :loading="loading"> | |||
| <template #default="{ record }"> | |||
| <a-row :gutter="20"> | |||
| <a-popconfirm title="是否要申请参加该招聘会?" @confirm="applyFor(record.id)"> | |||
| <a-col><a-button type="primary" size="small">申请</a-button></a-col> | |||
| </a-popconfirm> | |||
| <a-popconfirm placement="topLeft" ok-text="关闭" @confirm="confirm"> | |||
| <template #title> | |||
| <a-typography> | |||
| <a-typography-title :level="3">{{detailData.title}}</a-typography-title> | |||
| <a-typography-paragraph>发布时间:{{detailData.created_at}}</a-typography-paragraph> | |||
| <a-typography-text > | |||
| <div v-html="detailData.content"></div> | |||
| </a-typography-text> | |||
| </a-typography> | |||
| </template> | |||
| <a-button type="primary" size="small" @click="toDetail(record.id)">详情</a-button> | |||
| </a-popconfirm> | |||
| </a-row> | |||
| </template> | |||
| </a-biaoge> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, computed } from 'vue'; | |||
| import { PostRecruitmentList, PostRecruitmentbookAdd, PostRecruitmentBookcompany } from '@/apis/models'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| import { cols } from '@/components/company/meet/subscribe/columns'; | |||
| import ASearch from '@/components/company/meet/subscribe/search.vue'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| let { commomParams } = useCommon(); | |||
| let loading = ref<Boolean>(true); | |||
| onMounted(() => { | |||
| getData(commomParams.value.search); | |||
| }) | |||
| const searchData = (data : object) => { | |||
| commomParams.value.search = data | |||
| getData(); | |||
| } | |||
| const clearData = (data : object) => { | |||
| if (data) { | |||
| commomParams.value.search = data | |||
| } else { | |||
| commomParams.value.search = { | |||
| page: 1, | |||
| pagesize: 10, | |||
| sort: 'id', | |||
| sortby: 'asc', | |||
| keyword: '' | |||
| } | |||
| } | |||
| getData(); | |||
| } | |||
| const getPage = (data : object) => { | |||
| commomParams.value.search.page = data.current; | |||
| commomParams.value.search.pagesize = data.pageSize; | |||
| getData(); | |||
| } | |||
| const getData = async () => { | |||
| try { | |||
| loading.value = true; | |||
| let res = await PostRecruitmentList(commomParams.value.search); | |||
| loading.value = false; | |||
| commomParams.value.table.data = res.data.recruitments; | |||
| commomParams.value.table.columns = cols; | |||
| commomParams.value.page = { | |||
| current: commomParams.value.search.page, | |||
| pageSize: commomParams.value.search.pagesize, | |||
| total: res.data.total, | |||
| pageSizeOptions: ['10', '20', '30', '40'], | |||
| hideOnSinglePage: false, | |||
| showSizeChanger: true | |||
| }; | |||
| } catch { | |||
| loading.value = false; | |||
| } | |||
| } | |||
| // 申请 | |||
| const applyFor = (val) => { | |||
| PostRecruitmentbookAdd({ recruitment_id: val, company_id: 0}).then(res => { | |||
| successToast('预定成功') | |||
| }) | |||
| } | |||
| // 详情 | |||
| let detailData = ref<object>({}) | |||
| const toDetail = (val) => { | |||
| PostRecruitmentbookAdd({ id: val}).then(res => { | |||
| detailData.value = res.data | |||
| }) | |||
| } | |||
| </script> | |||
| <style scoped lang="less"> | |||
| </style> | |||
| @@ -0,0 +1,44 @@ | |||
| <template> | |||
| <a-form :model="commomParams.search"> | |||
| <a-row :gutter="20"> | |||
| <a-col span="12"> | |||
| <a-form-item> | |||
| <a-input-search v-model:value="commomParams.search.keyword" placeholder="请输入招聘会名称" enter-button="搜索" | |||
| @search="getData" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| </a-row> | |||
| </a-form> | |||
| </template> | |||
| <script lang="ts" setup> | |||
| import { ref, onMounted, watch, computed } from 'vue'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| let { commomParams } = useCommon(); | |||
| let props = defineProps(['search_params']); | |||
| const emit = defineEmits(); | |||
| watch(() => props.search_params, (newVal) => { | |||
| console.log(newVal) | |||
| }) | |||
| const getData = () => { | |||
| emit('searchData', commomParams.value.search) | |||
| } | |||
| // 清空搜索 | |||
| const clearSearch = () => { | |||
| commomParams.value.search = { | |||
| page: 1, | |||
| pagesize: 10, | |||
| sort: 'id', | |||
| sortby: 'asc', | |||
| keyword: '' | |||
| } | |||
| emit('clearData', commomParams.value.search) | |||
| } | |||
| </script> | |||
| <style> | |||
| </style> | |||
| @@ -0,0 +1,43 @@ | |||
| export const cols = <ColType.type[]>[ | |||
| { | |||
| title: '姓名', | |||
| dataIndex: 'customer_name', | |||
| key: 'customer_name', | |||
| }, | |||
| { | |||
| title: '性别', | |||
| dataIndex: 'gender', | |||
| key: 'gender', | |||
| }, | |||
| { | |||
| title: '应聘职位', | |||
| dataIndex: 'job_name', | |||
| key: 'job_name', | |||
| }, | |||
| { | |||
| title: '学历', | |||
| dataIndex: 'education_txt', | |||
| key: 'education_txt', | |||
| }, | |||
| { | |||
| title: '工作经验', | |||
| dataIndex: 'work_experience_txt', | |||
| key: 'work_experience_txt', | |||
| }, | |||
| { | |||
| title: '面试时间', | |||
| dataIndex: 'invite_date_txt', | |||
| key: 'invite_date_txt', | |||
| }, | |||
| { | |||
| title: '接收面试状态', | |||
| dataIndex: 'employ_status_txt', | |||
| key: 'employ_status_txt', | |||
| }, | |||
| { | |||
| title: '操作', | |||
| dataIndex: 'operation', | |||
| slots: { customRender: 'operation' }, | |||
| }, | |||
| ] | |||
| @@ -0,0 +1,141 @@ | |||
| <template> | |||
| <a-search @searchData="searchData" @clearData="clearData" :search_params="commomParams.search"></a-search> | |||
| <a-biaoge :data="commomParams.table.data" :columns="commomParams.table.columns" :pagination="commomParams.page" | |||
| @page="getPage" :loading="loading"> | |||
| <template #default="{ record }"> | |||
| <a-row :gutter="20"> | |||
| <a-col> | |||
| <a-dropdown placement="bottomRight"> | |||
| <template #overlay> | |||
| <a-menu> | |||
| <a-menu-item key="1"> | |||
| <a-button @click="cancel(record.id)" v-if="record.employ_status == 1" block>取消面试</a-button> | |||
| </a-menu-item> | |||
| <a-menu-item key="1"> | |||
| <a-button v-if="record.employ_status == 1" @click="hire(record.id)" block>录用</a-button> | |||
| <a-button v-if="record.employ_status == 2" disabled block>已录用</a-button> | |||
| </a-menu-item> | |||
| </a-menu> | |||
| </template> | |||
| <a-button> | |||
| 操作 | |||
| <DownOutlined /> | |||
| </a-button> | |||
| </a-dropdown> | |||
| </a-col> | |||
| </a-row> | |||
| </template> | |||
| </a-biaoge> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, computed, defineEmits, createVNode } from 'vue'; | |||
| import { GetCompanyResumeInterviewList, PostCompanyResumeInterviewDel,PostCompanyResumeInterviewAdmission } from '@/apis/models'; | |||
| import ASearch from '@/components/company/resume/interview/search.vue'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| import { cols } from '@/components/company/resume/interview/columns'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| import { DownOutlined } from '@ant-design/icons-vue'; | |||
| const emit = defineEmits(); | |||
| let { commomParams, ExclamationCircleOutlined, Modal } = useCommon(); | |||
| let loading = ref<Boolean>(true); | |||
| onMounted(() => { | |||
| getData(); | |||
| }) | |||
| const searchData = (data : object) => { | |||
| commomParams.value.search = data | |||
| getData(); | |||
| } | |||
| const clearData = (data : object) => { | |||
| if (data) { | |||
| commomParams.value.search = data | |||
| } else { | |||
| commomParams.value.search = { | |||
| page: 1, | |||
| pagesize: 10, | |||
| sort: 'id', | |||
| sortby: 'asc', | |||
| keyword: '' | |||
| } | |||
| } | |||
| getData(); | |||
| } | |||
| const getPage = (data : object) => { | |||
| commomParams.value.search.page = data.current; | |||
| commomParams.value.search.pagesize = data.pageSize; | |||
| getData(); | |||
| } | |||
| const getData = async () => { | |||
| try { | |||
| loading.value = true; | |||
| let res = await GetCompanyResumeInterviewList(commomParams.value.search); | |||
| loading.value = false; | |||
| commomParams.value.table.data = res.data.list; | |||
| commomParams.value.table.columns = cols; | |||
| commomParams.value.page = { | |||
| current: commomParams.value.search.page, | |||
| pageSize: commomParams.value.search.pagesize, | |||
| total: res.data.total, | |||
| pageSizeOptions: ['10', '20', '30', '40'], | |||
| hideOnSinglePage: false, | |||
| showSizeChanger: true | |||
| }; | |||
| } catch { | |||
| loading.value = false; | |||
| } | |||
| } | |||
| // 取消面试 | |||
| const cancel = (id : Number) => { | |||
| Modal.confirm({ | |||
| title: '是否要取消本次面试', | |||
| icon: createVNode(ExclamationCircleOutlined), | |||
| centered: true, | |||
| onOk() { | |||
| PostCompanyResumeInterviewDel({ id: id }).then(res => { | |||
| successToast('取消成功') | |||
| getData(); | |||
| }) | |||
| }, | |||
| onCancel() { | |||
| }, | |||
| }); | |||
| } | |||
| // 录用 | |||
| const hire = (id : Number) => { | |||
| Modal.confirm({ | |||
| title: '是否要录用该求职者', | |||
| icon: createVNode(ExclamationCircleOutlined), | |||
| centered: true, | |||
| onOk() { | |||
| PostCompanyResumeInterviewAdmission({ id: id, employ_status:2 }).then(res => { | |||
| successToast('已保存') | |||
| getData(); | |||
| }) | |||
| }, | |||
| onCancel() { | |||
| }, | |||
| }); | |||
| } | |||
| // const del = (id : number) => { | |||
| // commomParams.value.delParam = { id: id }; | |||
| // PostCompanyDepartmentDel(commomParams.value.delParam).then(res => { | |||
| // successToast('删除成功'); | |||
| // getData(); | |||
| // }) | |||
| // } | |||
| </script> | |||
| <style scoped lang="less"> | |||
| </style> | |||
| @@ -0,0 +1,123 @@ | |||
| <template> | |||
| <a-form :model="commomParams.search"> | |||
| <a-row :gutter="20"> | |||
| <a-col span="6"> | |||
| <a-form-item> | |||
| <a-select v-model:value="commomParams.search.department_id" @change="departmentChange" | |||
| placeholder="请进行搜索选择部门" show-search :filter-option="false" label-in-value | |||
| @search="departmentSearch"> | |||
| <a-select-option v-for="item in department_list" :key="item.id" :value="item.id" | |||
| :label="item.name" label-in-value>{{item.name}}</a-select-option> | |||
| </a-select> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="6"> | |||
| <a-form-item> | |||
| <a-select v-model:value="commomParams.search.job_id" @change="jobChange" | |||
| placeholder="请进行搜索选择职位" show-search :filter-option="false" label-in-value | |||
| @search="jobSearch"> | |||
| <a-select-option v-for="item in job_list" :key="item.id" :value="item.id" | |||
| :label="item.name" label-in-value>{{item.name}}</a-select-option> | |||
| </a-select> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="6"> | |||
| <a-form-item> | |||
| <a-select v-model:value="commomParams.search.status" @change="statusChange" | |||
| placeholder="简历查看状态"> | |||
| <a-select-option :key="1">已查看</a-select-option> | |||
| <a-select-option :key="2">未查看</a-select-option> | |||
| </a-select> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="6"> | |||
| <a-button type="primary" @click="clearSearch">重置</a-button> | |||
| </a-col> | |||
| </a-row> | |||
| </a-form> | |||
| </template> | |||
| <script lang="ts" setup> | |||
| import { ref, onMounted, watch, computed } from 'vue'; | |||
| import { GetCompanyDepartmentList, PostCompanyJobList } from '@/apis/models'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| let { commomParams } = useCommon(); | |||
| let props = defineProps(['search_params']); | |||
| const emit = defineEmits(); | |||
| interface listType { | |||
| department_id : String | |||
| job_id : String | |||
| status : String, | |||
| customer_name : String | |||
| } | |||
| commomParams.value.search = commomParams.value.search as listType; | |||
| commomParams.value.search.department_id = null; | |||
| commomParams.value.search.job_id = null; | |||
| commomParams.value.search.status = null; | |||
| commomParams.value.search.customer_name = ''; | |||
| watch(() => props.search_params, (newVal) => { | |||
| emit('searchData', commomParams.value.search) | |||
| },{ | |||
| immediate: true | |||
| }) | |||
| const getData = () => { | |||
| emit('searchData', commomParams.value.search) | |||
| } | |||
| // 清空搜索 | |||
| const clearSearch = () => { | |||
| commomParams.value.search = { | |||
| page: 1, | |||
| pagesize: 10, | |||
| sort: 'id', | |||
| sortby: 'asc', | |||
| keyword: '' | |||
| } | |||
| emit('clearData', commomParams.value.search) | |||
| } | |||
| onMounted(() => { | |||
| departmentSearch() | |||
| JobSearch() | |||
| }) | |||
| // 选择部门 | |||
| let department_list = ref<Object[]>([]) | |||
| const departmentSearch = (val) => { | |||
| GetCompanyDepartmentList({pagesize: 100, keyword: val }).then(res => { | |||
| department_list.value = res.data.rows; | |||
| }) | |||
| } | |||
| const departmentChange = (val : Object) => { | |||
| commomParams.value.search.department_id = val.key; | |||
| getData() | |||
| } | |||
| // 选择职位 | |||
| let job_list = ref<Object[]>([]) | |||
| const JobSearch = (val) => { | |||
| PostCompanyJobList({pagesize: 100, keyword: val }).then(res => { | |||
| job_list.value = res.data.list; | |||
| }) | |||
| } | |||
| const jobChange = (val : Object) => { | |||
| commomParams.value.search.job_id = val.key; | |||
| getData() | |||
| } | |||
| const statusChange = (val : Object) => { | |||
| commomParams.value.search.status = val; | |||
| getData() | |||
| } | |||
| </script> | |||
| <style> | |||
| </style> | |||
| @@ -0,0 +1,42 @@ | |||
| export const cols = <ColType.type[]>[ | |||
| { | |||
| title: '姓名', | |||
| dataIndex: 'customer_name', | |||
| key: 'customer_name', | |||
| }, | |||
| { | |||
| title: '性别', | |||
| dataIndex: 'gender', | |||
| key: 'gender', | |||
| }, | |||
| { | |||
| title: '应聘职位', | |||
| dataIndex: 'job_name', | |||
| key: 'job_name', | |||
| }, | |||
| { | |||
| title: '学历', | |||
| dataIndex: 'education_txt', | |||
| key: 'education_txt', | |||
| }, | |||
| { | |||
| title: '期望工作地', | |||
| dataIndex: 'desire_location_text', | |||
| key: 'desire_location_text', | |||
| }, | |||
| { | |||
| title: '工作经验', | |||
| dataIndex: 'work_experience_text', | |||
| key: 'work_experience_text', | |||
| }, | |||
| { | |||
| title: '联系方式', | |||
| dataIndex: 'mobile', | |||
| key: 'mobile', | |||
| },{ | |||
| title: '操作', | |||
| dataIndex: 'operation', | |||
| slots: { customRender: 'operation' }, | |||
| }, | |||
| ] | |||
| @@ -0,0 +1,125 @@ | |||
| <template> | |||
| <a-search @searchData="searchData" @clearData="clearData" :search_params="commomParams.search"></a-search> | |||
| <a-biaoge :data="commomParams.table.data" :columns="commomParams.table.columns" :pagination="commomParams.page" | |||
| @page="getPage" :loading="loading"> | |||
| <template #default="{ record }"> | |||
| <a-row :gutter="20"> | |||
| <a-col> | |||
| <a-dropdown placement="bottomRight"> | |||
| <template #overlay> | |||
| <a-menu> | |||
| <a-menu-item key="1"> | |||
| <a-button @click="edit(record)" block>预览简历</a-button> | |||
| </a-menu-item> | |||
| <a-menu-item key="2"> | |||
| <a-button @click="edit(record)" block>查看联系方式</a-button> | |||
| </a-menu-item> | |||
| </a-menu> | |||
| </template> | |||
| <a-button> | |||
| 操作 | |||
| <DownOutlined /> | |||
| </a-button> | |||
| </a-dropdown> | |||
| </a-col> | |||
| </a-row> | |||
| </template> | |||
| </a-biaoge> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, computed, defineEmits, createVNode } from 'vue'; | |||
| import { GetCompanyResumeViewedContactList } from '@/apis/models'; | |||
| import ASearch from '@/components/company/resume/read/search.vue'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| import { cols } from '@/components/company/resume/read/columns'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| import { DownOutlined } from '@ant-design/icons-vue'; | |||
| const emit = defineEmits(); | |||
| let { commomParams, ExclamationCircleOutlined, Modal } = useCommon(); | |||
| let loading = ref<Boolean>(true); | |||
| onMounted(() => { | |||
| getData(); | |||
| }) | |||
| const searchData = (data : object) => { | |||
| commomParams.value.search = data | |||
| getData(); | |||
| } | |||
| const clearData = (data : object) => { | |||
| if (data) { | |||
| commomParams.value.search = data | |||
| } else { | |||
| commomParams.value.search = { | |||
| page: 1, | |||
| pagesize: 10, | |||
| sort: 'id', | |||
| sortby: 'asc', | |||
| keyword: '' | |||
| } | |||
| } | |||
| getData(); | |||
| } | |||
| const getPage = (data : object) => { | |||
| commomParams.value.search.page = data.current; | |||
| commomParams.value.search.pagesize = data.pageSize; | |||
| getData(); | |||
| } | |||
| const getData = async () => { | |||
| try { | |||
| loading.value = true; | |||
| let res = await GetCompanyResumeViewedContactList(commomParams.value.search); | |||
| loading.value = false; | |||
| commomParams.value.table.data = res.data.list; | |||
| commomParams.value.table.columns = cols; | |||
| commomParams.value.page = { | |||
| current: commomParams.value.search.page, | |||
| pageSize: commomParams.value.search.pagesize, | |||
| total: res.data.total, | |||
| pageSizeOptions: ['10', '20', '30', '40'], | |||
| hideOnSinglePage: false, | |||
| showSizeChanger: true | |||
| }; | |||
| } catch { | |||
| loading.value = false; | |||
| } | |||
| } | |||
| // 修改 | |||
| const edit = (record : Object) => { | |||
| emit('toEdit', { record: record }) | |||
| } | |||
| // 放入回收站 | |||
| const putInRecycle = (id) => { | |||
| Modal.confirm({ | |||
| title: '是否要放入回收站', | |||
| icon: createVNode(ExclamationCircleOutlined), | |||
| onOk() { | |||
| PostCompanyJobRecycle({ id: id }).then(res => { | |||
| successToast('已放入回收站') | |||
| }) | |||
| }, | |||
| onCancel() { | |||
| }, | |||
| }); | |||
| } | |||
| // const del = (id : number) => { | |||
| // commomParams.value.delParam = { id: id }; | |||
| // PostCompanyDepartmentDel(commomParams.value.delParam).then(res => { | |||
| // successToast('删除成功'); | |||
| // getData(); | |||
| // }) | |||
| // } | |||
| </script> | |||
| <style scoped lang="less"> | |||
| </style> | |||
| @@ -0,0 +1,54 @@ | |||
| <template> | |||
| <a-form :model="commomParams.search"> | |||
| <a-row :gutter="20"> | |||
| <a-col span="6"> | |||
| <a-form-item> | |||
| <a-input-search v-model:value="commomParams.search.keyword" placeholder="请输入求职者" enter-button="搜索" | |||
| @search="getData" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="6"> | |||
| <a-button type="primary" @click="clearSearch">重置</a-button> | |||
| </a-col> | |||
| </a-row> | |||
| </a-form> | |||
| </template> | |||
| <script lang="ts" setup> | |||
| import { ref, onMounted, watch, computed } from 'vue'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| let { commomParams } = useCommon(); | |||
| let props = defineProps(['search_params']); | |||
| const emit = defineEmits(); | |||
| watch(() => props.search_params, (newVal) => { | |||
| emit('searchData', commomParams.value.search) | |||
| },{ | |||
| immediate: true | |||
| }) | |||
| const getData = () => { | |||
| emit('searchData', commomParams.value.search) | |||
| } | |||
| // 清空搜索 | |||
| const clearSearch = () => { | |||
| commomParams.value.search = { | |||
| page: 1, | |||
| pagesize: 10, | |||
| sort: 'id', | |||
| sortby: 'asc', | |||
| keyword: '' | |||
| } | |||
| emit('clearData', commomParams.value.search) | |||
| } | |||
| </script> | |||
| <style> | |||
| </style> | |||
| @@ -0,0 +1,43 @@ | |||
| export const cols = <ColType.type[]>[ | |||
| { | |||
| title: '姓名', | |||
| dataIndex: 'customer_name', | |||
| key: 'customer_name', | |||
| }, | |||
| { | |||
| title: '性别', | |||
| dataIndex: 'gender', | |||
| key: 'gender', | |||
| }, | |||
| { | |||
| title: '应聘职位', | |||
| dataIndex: 'job_name', | |||
| key: 'job_name', | |||
| }, | |||
| { | |||
| title: '学历', | |||
| dataIndex: 'education_txt', | |||
| key: 'education_txt', | |||
| }, | |||
| { | |||
| title: '工作经验', | |||
| dataIndex: 'work_experience_txt', | |||
| key: 'work_experience_txt', | |||
| }, | |||
| { | |||
| title: '投递时间', | |||
| dataIndex: 'apply_time_txt', | |||
| key: 'apply_time_txt', | |||
| }, | |||
| { | |||
| title: '状态', | |||
| dataIndex: 'status_text', | |||
| key: 'status_text', | |||
| }, | |||
| { | |||
| title: '操作', | |||
| dataIndex: 'operation', | |||
| slots: { customRender: 'operation' }, | |||
| }, | |||
| ] | |||
| @@ -0,0 +1,203 @@ | |||
| <template> | |||
| <a-search @searchData="searchData" @clearData="clearData" :search_params="commomParams.search"></a-search> | |||
| <a-biaoge :data="commomParams.table.data" :columns="commomParams.table.columns" :pagination="commomParams.page" | |||
| @page="getPage" :loading="loading"> | |||
| <template #default="{ record }"> | |||
| <a-row :gutter="20"> | |||
| <a-col> | |||
| <a-dropdown placement="bottomRight"> | |||
| <template #overlay> | |||
| <a-menu> | |||
| <a-menu-item key="1"> | |||
| <a-button @click="contact(record)" block>查看联系方式</a-button> | |||
| </a-menu-item> | |||
| <a-menu-item key="1"> | |||
| <a-button @click="interview(record)" block>预览简历</a-button> | |||
| </a-menu-item> | |||
| <a-menu-item key="2"> | |||
| <a-button @click="interview(record)" block>邀请面试</a-button> | |||
| </a-menu-item> | |||
| <a-menu-item key="3"> | |||
| <a-button @click="putInTatent(record.customer_id)" block>放入人才库</a-button> | |||
| </a-menu-item> | |||
| <a-menu-item key="4"> | |||
| <a-button @click="putInRecycle(record.id)" block>放入回收站</a-button> | |||
| </a-menu-item> | |||
| </a-menu> | |||
| </template> | |||
| <a-button> | |||
| 操作 | |||
| <DownOutlined /> | |||
| </a-button> | |||
| </a-dropdown> | |||
| </a-col> | |||
| </a-row> | |||
| </template> | |||
| </a-biaoge> | |||
| <a-modal v-model:open="openInterview" centered title="面试邀请" @ok="interviewOk"> | |||
| <a-date-picker v-model:value="time" @Change="timeChange" show-time style="width: 100%;" placeholder="请选择面试日期" size="large" | |||
| :disabled-date="disabledDate" /> | |||
| </a-modal> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, computed, defineEmits, createVNode } from 'vue'; | |||
| import { GetCompanyResumeList, PostCompanyResumeInterviewAdd, PostCompanyTalentPoolAdd, PostCompanyResumeRecycle, GetJobapplicantContactdetail } from '@/apis/models'; | |||
| import ASearch from '@/components/company/resume/interview/search.vue'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| import { cols } from '@/components/company/resume/interview/columns'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| import { DownOutlined } from '@ant-design/icons-vue'; | |||
| const emit = defineEmits(); | |||
| let { commomParams, ExclamationCircleOutlined, Modal, dayjs, disabledDate } = useCommon(); | |||
| const dayjsRef = ref(dayjs); | |||
| let loading = ref<Boolean>(true); | |||
| onMounted(() => { | |||
| getData(); | |||
| }) | |||
| const searchData = (data : object) => { | |||
| commomParams.value.search = data | |||
| getData(); | |||
| } | |||
| const clearData = (data : object) => { | |||
| if (data) { | |||
| commomParams.value.search = data | |||
| } else { | |||
| commomParams.value.search = { | |||
| page: 1, | |||
| pagesize: 10, | |||
| sort: 'id', | |||
| sortby: 'asc', | |||
| keyword: '' | |||
| } | |||
| } | |||
| getData(); | |||
| } | |||
| const getPage = (data : object) => { | |||
| commomParams.value.search.page = data.current; | |||
| commomParams.value.search.pagesize = data.pageSize; | |||
| getData(); | |||
| } | |||
| const getData = async () => { | |||
| try { | |||
| loading.value = true; | |||
| let res = await GetCompanyResumeList(commomParams.value.search); | |||
| loading.value = false; | |||
| commomParams.value.table.data = res.data.list; | |||
| commomParams.value.table.columns = cols; | |||
| commomParams.value.page = { | |||
| current: commomParams.value.search.page, | |||
| pageSize: commomParams.value.search.pagesize, | |||
| total: res.data.total, | |||
| pageSizeOptions: ['10', '20', '30', '40'], | |||
| hideOnSinglePage: false, | |||
| showSizeChanger: true | |||
| }; | |||
| } catch { | |||
| loading.value = false; | |||
| } | |||
| } | |||
| const contact = () => { | |||
| Modal.confirm({ | |||
| title: `是否要放入人才库`, | |||
| centered: true, | |||
| icon: createVNode(ExclamationCircleOutlined), | |||
| onOk() { | |||
| PostCompanyTalentPoolAdd({ customer_id: id }).then(res => { | |||
| successToast('已放入人才库') | |||
| getData(); | |||
| }) | |||
| }, | |||
| onCancel() { | |||
| }, | |||
| }); | |||
| } | |||
| // 邀请面试 | |||
| let openInterview = ref<Boolean>(false); | |||
| let form = { | |||
| job_id: '', | |||
| customer_id: '', | |||
| interview_date_time: '' | |||
| } | |||
| const interview = (record : Object) => { | |||
| openInterview.value = true | |||
| form.job_id = record.job_id; | |||
| form.customer_id = record.customer_id; | |||
| form.interview_date_time = '' | |||
| time.value = '' | |||
| } | |||
| let time = ref<String>(''); | |||
| const timeChange = (val) => { | |||
| form.interview_date_time = dayjsRef.value(val).format('YYYY-MM-DD HH:mm:ss'); | |||
| } | |||
| const interviewOk = () => { | |||
| console.log(form) | |||
| if (!form.interview_date_time) { | |||
| warnToast('请选择面试时间') | |||
| return; | |||
| } else { | |||
| PostCompanyResumeInterviewAdd(form).then(res => { | |||
| successToast('已发送邀请') | |||
| getData(); | |||
| }) | |||
| } | |||
| } | |||
| // 放入人才库 | |||
| const putInTatent = (id, num) => { | |||
| Modal.confirm({ | |||
| title: `是否要放入人才库`, | |||
| centered: true, | |||
| icon: createVNode(ExclamationCircleOutlined), | |||
| onOk() { | |||
| PostCompanyTalentPoolAdd({ customer_id: id }).then(res => { | |||
| successToast('已放入人才库') | |||
| getData(); | |||
| }) | |||
| }, | |||
| onCancel() { | |||
| }, | |||
| }); | |||
| } | |||
| // 放入回收站 | |||
| const putInRecycle = (id) => { | |||
| Modal.confirm({ | |||
| title: '是否要放入回收站', | |||
| centered: true, | |||
| icon: createVNode(ExclamationCircleOutlined), | |||
| onOk() { | |||
| PostCompanyResumeRecycle({ selected: [id] }).then(res => { | |||
| successToast('已放入回收站') | |||
| getData(); | |||
| }) | |||
| }, | |||
| onCancel() { | |||
| }, | |||
| }); | |||
| } | |||
| </script> | |||
| <style scoped lang="less"> | |||
| </style> | |||
| @@ -0,0 +1,123 @@ | |||
| <template> | |||
| <a-form :model="commomParams.search"> | |||
| <a-row :gutter="20"> | |||
| <a-col span="6"> | |||
| <a-form-item> | |||
| <a-select v-model:value="commomParams.search.department_id" @change="departmentChange" | |||
| placeholder="请进行搜索选择部门" show-search :filter-option="false" label-in-value | |||
| @search="departmentSearch"> | |||
| <a-select-option v-for="item in department_list" :key="item.id" :value="item.id" | |||
| :label="item.name" label-in-value>{{item.name}}</a-select-option> | |||
| </a-select> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="6"> | |||
| <a-form-item> | |||
| <a-select v-model:value="commomParams.search.job_id" @change="jobChange" | |||
| placeholder="请进行搜索选择职位" show-search :filter-option="false" label-in-value | |||
| @search="jobSearch"> | |||
| <a-select-option v-for="item in job_list" :key="item.id" :value="item.id" | |||
| :label="item.name" label-in-value>{{item.name}}</a-select-option> | |||
| </a-select> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="6"> | |||
| <a-form-item> | |||
| <a-select v-model:value="commomParams.search.status" @change="statusChange" | |||
| placeholder="简历查看状态"> | |||
| <a-select-option :key="1">已查看</a-select-option> | |||
| <a-select-option :key="2">未查看</a-select-option> | |||
| </a-select> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="6"> | |||
| <a-button type="primary" @click="clearSearch">重置</a-button> | |||
| </a-col> | |||
| </a-row> | |||
| </a-form> | |||
| </template> | |||
| <script lang="ts" setup> | |||
| import { ref, onMounted, watch, computed } from 'vue'; | |||
| import { GetCompanyDepartmentList, PostCompanyJobList } from '@/apis/models'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| let { commomParams } = useCommon(); | |||
| let props = defineProps(['search_params']); | |||
| const emit = defineEmits(); | |||
| interface listType { | |||
| department_id : String | |||
| job_id : String | |||
| status : String, | |||
| customer_name : String | |||
| } | |||
| commomParams.value.search = commomParams.value.search as listType; | |||
| commomParams.value.search.department_id = null; | |||
| commomParams.value.search.job_id = null; | |||
| commomParams.value.search.status = null; | |||
| commomParams.value.search.customer_name = ''; | |||
| watch(() => props.search_params, (newVal) => { | |||
| emit('searchData', commomParams.value.search) | |||
| },{ | |||
| immediate: true | |||
| }) | |||
| const getData = () => { | |||
| emit('searchData', commomParams.value.search) | |||
| } | |||
| // 清空搜索 | |||
| const clearSearch = () => { | |||
| commomParams.value.search = { | |||
| page: 1, | |||
| pagesize: 10, | |||
| sort: 'id', | |||
| sortby: 'asc', | |||
| keyword: '' | |||
| } | |||
| emit('clearData', commomParams.value.search) | |||
| } | |||
| onMounted(() => { | |||
| departmentSearch() | |||
| JobSearch() | |||
| }) | |||
| // 选择部门 | |||
| let department_list = ref<Object[]>([]) | |||
| const departmentSearch = (val) => { | |||
| GetCompanyDepartmentList({pagesize: 100, keyword: val }).then(res => { | |||
| department_list.value = res.data.rows; | |||
| }) | |||
| } | |||
| const departmentChange = (val : Object) => { | |||
| commomParams.value.search.department_id = val.key; | |||
| getData() | |||
| } | |||
| // 选择职位 | |||
| let job_list = ref<Object[]>([]) | |||
| const JobSearch = (val) => { | |||
| PostCompanyJobList({pagesize: 100, keyword: val }).then(res => { | |||
| job_list.value = res.data.list; | |||
| }) | |||
| } | |||
| const jobChange = (val : Object) => { | |||
| commomParams.value.search.job_id = val.key; | |||
| getData() | |||
| } | |||
| const statusChange = (val : Object) => { | |||
| commomParams.value.search.status = val; | |||
| getData() | |||
| } | |||
| </script> | |||
| <style> | |||
| </style> | |||
| @@ -0,0 +1,43 @@ | |||
| export const cols = <ColType.type[]>[ | |||
| { | |||
| title: '姓名', | |||
| dataIndex: 'customer_name', | |||
| key: 'customer_name', | |||
| }, | |||
| { | |||
| title: '性别', | |||
| dataIndex: 'gender', | |||
| key: 'gender', | |||
| }, | |||
| { | |||
| title: '应聘职位', | |||
| dataIndex: 'job_name', | |||
| key: 'job_name', | |||
| }, | |||
| { | |||
| title: '学历', | |||
| dataIndex: 'education_txt', | |||
| key: 'education_txt', | |||
| }, | |||
| { | |||
| title: '工作经验', | |||
| dataIndex: 'work_experience_txt', | |||
| key: 'work_experience_txt', | |||
| }, | |||
| { | |||
| title: '面试时间', | |||
| dataIndex: 'invite_date_txt', | |||
| key: 'invite_date_txt', | |||
| }, | |||
| { | |||
| title: '接收面试状态', | |||
| dataIndex: 'employ_status_txt', | |||
| key: 'employ_status_txt', | |||
| }, | |||
| { | |||
| title: '操作', | |||
| dataIndex: 'operation', | |||
| slots: { customRender: 'operation' }, | |||
| }, | |||
| ] | |||
| @@ -0,0 +1,124 @@ | |||
| <template> | |||
| <a-search @searchData="searchData" @clearData="clearData" :search_params="commomParams.search"></a-search> | |||
| <a-biaoge :data="commomParams.table.data" :columns="commomParams.table.columns" :pagination="commomParams.page" | |||
| @page="getPage" :loading="loading"> | |||
| <template #default="{ record }"> | |||
| <a-row :gutter="20"> | |||
| <a-col> | |||
| <a-dropdown placement="bottomRight"> | |||
| <template #overlay> | |||
| <a-menu> | |||
| <a-menu-item key="1"> | |||
| <a-button @click="popInRecycle(record.id)">移出回收站</a-button> | |||
| </a-menu-item> | |||
| </a-menu> | |||
| </template> | |||
| <a-button> | |||
| 操作 | |||
| <DownOutlined /> | |||
| </a-button> | |||
| </a-dropdown> | |||
| </a-col> | |||
| </a-row> | |||
| </template> | |||
| </a-biaoge> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, computed, defineEmits, createVNode } from 'vue'; | |||
| import { GetCompanyResumeRecyclelist, PostCompanyResumeRecover } from '@/apis/models'; | |||
| import ASearch from '@/components/company/resume/interview/search.vue'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| import { cols } from '@/components/company/resume/interview/columns'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| import { DownOutlined } from '@ant-design/icons-vue'; | |||
| const emit = defineEmits(); | |||
| let { commomParams, ExclamationCircleOutlined, Modal } = useCommon(); | |||
| let loading = ref<Boolean>(true); | |||
| onMounted(() => { | |||
| getData(); | |||
| }) | |||
| const searchData = (data : object) => { | |||
| commomParams.value.search = data | |||
| getData(); | |||
| } | |||
| const clearData = (data : object) => { | |||
| if (data) { | |||
| commomParams.value.search = data | |||
| } else { | |||
| commomParams.value.search = { | |||
| page: 1, | |||
| pagesize: 10, | |||
| sort: 'id', | |||
| sortby: 'asc', | |||
| keyword: '' | |||
| } | |||
| } | |||
| getData(); | |||
| } | |||
| const getPage = (data : object) => { | |||
| commomParams.value.search.page = data.current; | |||
| commomParams.value.search.pagesize = data.pageSize; | |||
| getData(); | |||
| } | |||
| const getData = async () => { | |||
| try { | |||
| loading.value = true; | |||
| let res = await GetCompanyResumeRecyclelist(commomParams.value.search); | |||
| loading.value = false; | |||
| commomParams.value.table.data = res.data.list; | |||
| commomParams.value.table.columns = cols; | |||
| commomParams.value.page = { | |||
| current: commomParams.value.search.page, | |||
| pageSize: commomParams.value.search.pagesize, | |||
| total: res.data.total, | |||
| pageSizeOptions: ['10', '20', '30', '40'], | |||
| hideOnSinglePage: false, | |||
| showSizeChanger: true | |||
| }; | |||
| } catch { | |||
| loading.value = false; | |||
| } | |||
| } | |||
| // 修改 | |||
| const edit = (record : Object) => { | |||
| emit('toEdit', { record: record }) | |||
| } | |||
| // 移除回收站 | |||
| const popInRecycle = (id) => { | |||
| Modal.confirm({ | |||
| title: '是否要移出回收站', | |||
| centered: true, | |||
| icon: createVNode(ExclamationCircleOutlined), | |||
| onOk() { | |||
| PostCompanyResumeRecover({ selected: [id] }).then(res => { | |||
| successToast('已移出回收站') | |||
| getData(); | |||
| }) | |||
| }, | |||
| onCancel() { | |||
| }, | |||
| }); | |||
| } | |||
| // const del = (id : number) => { | |||
| // commomParams.value.delParam = { id: id }; | |||
| // PostCompanyDepartmentDel(commomParams.value.delParam).then(res => { | |||
| // successToast('删除成功'); | |||
| // getData(); | |||
| // }) | |||
| // } | |||
| </script> | |||
| <style scoped lang="less"> | |||
| </style> | |||
| @@ -0,0 +1,123 @@ | |||
| <template> | |||
| <a-form :model="commomParams.search"> | |||
| <a-row :gutter="20"> | |||
| <a-col span="6"> | |||
| <a-form-item> | |||
| <a-select v-model:value="commomParams.search.department_id" @change="departmentChange" | |||
| placeholder="请进行搜索选择部门" show-search :filter-option="false" label-in-value | |||
| @search="departmentSearch"> | |||
| <a-select-option v-for="item in department_list" :key="item.id" :value="item.id" | |||
| :label="item.name" label-in-value>{{item.name}}</a-select-option> | |||
| </a-select> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="6"> | |||
| <a-form-item> | |||
| <a-select v-model:value="commomParams.search.job_id" @change="jobChange" | |||
| placeholder="请进行搜索选择职位" show-search :filter-option="false" label-in-value | |||
| @search="jobSearch"> | |||
| <a-select-option v-for="item in job_list" :key="item.id" :value="item.id" | |||
| :label="item.name" label-in-value>{{item.name}}</a-select-option> | |||
| </a-select> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="6"> | |||
| <a-form-item> | |||
| <a-select v-model:value="commomParams.search.status" @change="statusChange" | |||
| placeholder="简历查看状态"> | |||
| <a-select-option :key="1">已查看</a-select-option> | |||
| <a-select-option :key="2">未查看</a-select-option> | |||
| </a-select> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="6"> | |||
| <a-button type="primary" @click="clearSearch">重置</a-button> | |||
| </a-col> | |||
| </a-row> | |||
| </a-form> | |||
| </template> | |||
| <script lang="ts" setup> | |||
| import { ref, onMounted, watch, computed } from 'vue'; | |||
| import { GetCompanyDepartmentList, PostCompanyJobList } from '@/apis/models'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| let { commomParams } = useCommon(); | |||
| let props = defineProps(['search_params']); | |||
| const emit = defineEmits(); | |||
| interface listType { | |||
| department_id : String | |||
| job_id : String | |||
| status : String, | |||
| customer_name : String | |||
| } | |||
| commomParams.value.search = commomParams.value.search as listType; | |||
| commomParams.value.search.department_id = null; | |||
| commomParams.value.search.job_id = null; | |||
| commomParams.value.search.status = null; | |||
| commomParams.value.search.customer_name = ''; | |||
| watch(() => props.search_params, (newVal) => { | |||
| emit('searchData', commomParams.value.search) | |||
| },{ | |||
| immediate: true | |||
| }) | |||
| const getData = () => { | |||
| emit('searchData', commomParams.value.search) | |||
| } | |||
| // 清空搜索 | |||
| const clearSearch = () => { | |||
| commomParams.value.search = { | |||
| page: 1, | |||
| pagesize: 10, | |||
| sort: 'id', | |||
| sortby: 'asc', | |||
| keyword: '' | |||
| } | |||
| emit('clearData', commomParams.value.search) | |||
| } | |||
| onMounted(() => { | |||
| departmentSearch() | |||
| JobSearch() | |||
| }) | |||
| // 选择部门 | |||
| let department_list = ref<Object[]>([]) | |||
| const departmentSearch = (val) => { | |||
| GetCompanyDepartmentList({pagesize: 100, keyword: val }).then(res => { | |||
| department_list.value = res.data.rows; | |||
| }) | |||
| } | |||
| const departmentChange = (val : Object) => { | |||
| commomParams.value.search.department_id = val.key; | |||
| getData() | |||
| } | |||
| // 选择职位 | |||
| let job_list = ref<Object[]>([]) | |||
| const JobSearch = (val) => { | |||
| PostCompanyJobList({pagesize: 100, keyword: val }).then(res => { | |||
| job_list.value = res.data.list; | |||
| }) | |||
| } | |||
| const jobChange = (val : Object) => { | |||
| commomParams.value.search.job_id = val.key; | |||
| getData() | |||
| } | |||
| const statusChange = (val : Object) => { | |||
| commomParams.value.search.status = val; | |||
| getData() | |||
| } | |||
| </script> | |||
| <style> | |||
| </style> | |||
| @@ -0,0 +1,26 @@ | |||
| <template> | |||
| <job-talents :list="jobList"></job-talents> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, computed, onMounted } from 'vue'; | |||
| import JobTalents from '@/components/job/talents/index.vue' | |||
| import { PostJobseekerList } from '@/apis/models'; | |||
| let jobList = ref<object[]>([]) | |||
| onMounted(() => { | |||
| PostJobseekerList().then(res => { | |||
| if (res.data.list.length > 10) { | |||
| jobList.value = res.data.list.slice(0, 10) | |||
| } else { | |||
| jobList.value = res.data.list | |||
| } | |||
| }) | |||
| }) | |||
| </script> | |||
| <style scoped lang="less"> | |||
| </style> | |||
| @@ -0,0 +1,213 @@ | |||
| <template> | |||
| <a-form :model="createForm" :label-col="{span: 4}" labelAlign="right"> | |||
| <a-row gutter="20"> | |||
| <a-col span="12"> | |||
| <a-row> | |||
| <a-col span="24"> | |||
| <a-form-item label="关键字" name="keyword"> | |||
| <a-input v-model:value="createForm.keyword" placeholder="Basic usage" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="应聘职位"> | |||
| <a-shujilian :dict="2004" placeholder="职位类别(最多三个,多选只取前三)" @saveTreeNode="jobTypeChange" | |||
| :select_content="job_type"></a-shujilian> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="期望地区"> | |||
| <a-shujilian :dict="2009" placeholder="工作区域(最多四个,多选只取前四)" @saveTreeNode="jobAddressChange" | |||
| :select_content="job_location"></a-shujilian> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="户口所在地"> | |||
| <a-jilian :dict="2009" @saveCascader="regLevelSave" placeholder="请选择籍贯" | |||
| :cascader_content="addOtherForm.company_jiguan_cascader"></a-jilian> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="学历"> | |||
| <a-xuanze :dict="2006" placeholder="请选择学历" @saveSelect="saveSchoolDegree" | |||
| :select_content="createForm.school_degree"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="含最高学历" name="degree_better"> | |||
| <a-radio-group v-model:value="createForm.degree_better" button-style="solid"> | |||
| <a-radio-button :value="1">是</a-radio-button> | |||
| <a-radio-button :value="2">否</a-radio-button> | |||
| </a-radio-group> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item required label="英语"> | |||
| <a-xuanze :dict="2007" placeholder="请选择掌握程度" @saveSelect="saveEnglish" | |||
| :select_content="createForm.language_degree"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item required label="国语"> | |||
| <a-xuanze :dict="2007" placeholder="请选择掌握程度" @saveSelect="saveMandarin" | |||
| :select_content="createForm.language_degree"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item required label="粤语"> | |||
| <a-xuanze :dict="2007" placeholder="请选择掌握程度" @saveSelect="saveCantonese" | |||
| :select_content="createForm.language_degree"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item required label="第二外语"> | |||
| <a-xuanze :dict="2007" placeholder="请选择第二外语" @saveSelect="saveOtherLanguage" | |||
| :select_content="createForm.language"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item required label="计算机能力"> | |||
| <a-input v-model:value="value" placeholder="请输入计算机能力" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item required label="工作经验"> | |||
| <a-xuanze :dict="2021" placeholder="请选择工作经验" @saveSelect="saveExperience" | |||
| :select_content="createForm.experience"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="性别" name="sex"> | |||
| <a-radio-group v-model:value="createForm.gender" button-style="solid"> | |||
| <a-radio-button value="男">男</a-radio-button> | |||
| <a-radio-button value="女">女</a-radio-button> | |||
| <a-radio-button value="不限">不限</a-radio-button> | |||
| </a-radio-group> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="最小年龄" name="age_min"> | |||
| <a-input-number :min="0" type="number" v-model:value="createForm.age_min" | |||
| placeholder="请输入最小年龄" style="width: 100%;" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="最大年龄" name="age_max"> | |||
| <a-input-number :min="0" type="number" v-model:value="createForm.age_max" | |||
| placeholder="请输入最大年龄" style="width: 100%;" /> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item required label="简历更新" name="marital_status"> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-form-item label="搜索"> | |||
| <a-button type="primary" block @click="saveForm">搜索</a-button> | |||
| </a-form-item> | |||
| </a-col> | |||
| </a-row> | |||
| </a-col> | |||
| </a-row> | |||
| </a-form> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, computed, defineProps, watch, defineEmits } from 'vue'; | |||
| let createForm : companyListType.addrFormType = ref({ | |||
| keyword: "", | |||
| gender: "女", | |||
| title: 0, | |||
| education: 0, | |||
| marital_status: 0, | |||
| ethnicity: 0, | |||
| reg_level1: 0, | |||
| reg_level2: 0, | |||
| reg_level3: 0, | |||
| reg_level4: 0, | |||
| now_level1: 0, | |||
| now_level2: 0, | |||
| now_level3: 0, | |||
| now_level4: 0, | |||
| maxdob: "9999-12-31 23:59:59", | |||
| mindob: "1000-01-01 00:00:00", | |||
| maxheight: 230, | |||
| minheight: 60, | |||
| maxweight: 200, | |||
| minweight: 30, | |||
| political_status: 0, | |||
| native_place: 0, | |||
| desire_area: [], | |||
| desire_position: [], | |||
| desire_industry: [], | |||
| job_type_desire: 0, | |||
| talent_type_desire: 0, | |||
| max_work_experience: 0, | |||
| min_work_experience: 0, | |||
| salary_range_desire: 0, | |||
| available_date_desire: 0, | |||
| title_requirement_desire: 0, | |||
| skill_certification_desire: 0, | |||
| english: 0, | |||
| mandarin: 0, | |||
| cantonese: 0, | |||
| other_language: 0, | |||
| sort: "id", | |||
| sortby: "asc", | |||
| page: 1, | |||
| pagesize: 20 | |||
| }) | |||
| let addOtherForm : companyListType.addrFormType = ref({ | |||
| company_jiguan_cascader: [] | |||
| }) | |||
| // 户口所在地 | |||
| const regLevelSave = (data) => { | |||
| for (let i = 0; i < 4; i++) { | |||
| createForm.value[`reg_level${i + 1}`] = data.arr1[i] || 0; | |||
| } | |||
| } | |||
| // 学历要求 | |||
| const saveSchoolDegree = (data) => { | |||
| createForm.value.education = data.val.key; | |||
| } | |||
| // 英语掌握程度 | |||
| const saveEnglish = (data) => { | |||
| createForm.value.english = data.val.key;; | |||
| } | |||
| // 国语掌握程度 | |||
| const saveMandarin = (data) => { | |||
| createForm.value.mandarin = data.val.key;; | |||
| } | |||
| // 粤语掌握程度 | |||
| const saveCantonese = (data) => { | |||
| createForm.value.cantonese = data.val.key;; | |||
| } | |||
| // 第二外语 | |||
| const saveOtherLanguage = (data) => { | |||
| createForm.value.other_language = data.val.key;; | |||
| } | |||
| // 工作经验 | |||
| const saveExperience = (data) => { | |||
| createForm.value.experience = data.val.key; | |||
| } | |||
| </script> | |||
| <style> | |||
| </style> | |||
| <style> | |||
| </style> | |||
| @@ -0,0 +1,43 @@ | |||
| export const cols = <ColType.type[]>[ | |||
| { | |||
| title: '姓名', | |||
| dataIndex: 'customer_name', | |||
| key: 'customer_name', | |||
| }, | |||
| { | |||
| title: '性别', | |||
| dataIndex: 'gender', | |||
| key: 'gender', | |||
| }, | |||
| { | |||
| title: '应聘职位', | |||
| dataIndex: 'job_name', | |||
| key: 'job_name', | |||
| }, | |||
| { | |||
| title: '学历', | |||
| dataIndex: 'education_txt', | |||
| key: 'education_txt', | |||
| }, | |||
| { | |||
| title: '工作经验', | |||
| dataIndex: 'work_experience_txt', | |||
| key: 'work_experience_txt', | |||
| }, | |||
| { | |||
| title: '面试时间', | |||
| dataIndex: 'invite_date_txt', | |||
| key: 'invite_date_txt', | |||
| }, | |||
| { | |||
| title: '接收面试状态', | |||
| dataIndex: 'employ_status_txt', | |||
| key: 'employ_status_txt', | |||
| }, | |||
| { | |||
| title: '操作', | |||
| dataIndex: 'operation', | |||
| slots: { customRender: 'operation' }, | |||
| }, | |||
| ] | |||
| @@ -0,0 +1,119 @@ | |||
| <template> | |||
| <a-search @searchData="searchData" @clearData="clearData" :search_params="commomParams.search"></a-search> | |||
| <a-biaoge :data="commomParams.table.data" :columns="commomParams.table.columns" :pagination="commomParams.page" | |||
| @page="getPage" :loading="loading"> | |||
| <template #default="{ record }"> | |||
| <a-row :gutter="20"> | |||
| <a-col> | |||
| <a-dropdown placement="bottomRight"> | |||
| <template #overlay> | |||
| <a-menu> | |||
| <a-menu-item key="1"> | |||
| <a-button @click="popInRecycle(record.id)">移出人才库</a-button> | |||
| </a-menu-item> | |||
| </a-menu> | |||
| </template> | |||
| <a-button> | |||
| 操作 | |||
| <DownOutlined /> | |||
| </a-button> | |||
| </a-dropdown> | |||
| </a-col> | |||
| </a-row> | |||
| </template> | |||
| </a-biaoge> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, computed, defineEmits, createVNode } from 'vue'; | |||
| import { GetCompanyTalentPoolList, PostCompanyTalentPoolDel } from '@/apis/models'; | |||
| import ASearch from '@/components/company/resume/talent/search.vue'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| import { cols } from '@/components/company/resume/talent/columns'; | |||
| import { warnToast, successToast } from '@/utils/toastHelper'; | |||
| import { DownOutlined } from '@ant-design/icons-vue'; | |||
| const emit = defineEmits(); | |||
| let { commomParams, ExclamationCircleOutlined, Modal } = useCommon(); | |||
| let loading = ref<Boolean>(true); | |||
| onMounted(() => { | |||
| getData(); | |||
| }) | |||
| const searchData = (data : object) => { | |||
| commomParams.value.search = data | |||
| getData(); | |||
| } | |||
| const clearData = (data : object) => { | |||
| if (data) { | |||
| commomParams.value.search = data | |||
| } else { | |||
| commomParams.value.search = { | |||
| page: 1, | |||
| pagesize: 10, | |||
| sort: 'id', | |||
| sortby: 'asc', | |||
| keyword: '' | |||
| } | |||
| } | |||
| getData(); | |||
| } | |||
| const getPage = (data : object) => { | |||
| commomParams.value.search.page = data.current; | |||
| commomParams.value.search.pagesize = data.pageSize; | |||
| getData(); | |||
| } | |||
| const getData = async () => { | |||
| try { | |||
| loading.value = true; | |||
| let res = await GetCompanyTalentPoolList(commomParams.value.search); | |||
| loading.value = false; | |||
| commomParams.value.table.data = res.data.list; | |||
| commomParams.value.table.columns = cols; | |||
| commomParams.value.page = { | |||
| current: commomParams.value.search.page, | |||
| pageSize: commomParams.value.search.pagesize, | |||
| total: res.data.total, | |||
| pageSizeOptions: ['10', '20', '30', '40'], | |||
| hideOnSinglePage: false, | |||
| showSizeChanger: true | |||
| }; | |||
| } catch { | |||
| loading.value = false; | |||
| } | |||
| } | |||
| // 移除回收站 | |||
| const popInRecycle = (id) => { | |||
| Modal.confirm({ | |||
| title: '是否要移出人才库', | |||
| centered: true, | |||
| icon: createVNode(ExclamationCircleOutlined), | |||
| onOk() { | |||
| PostCompanyTalentPoolDel({ selected: [id] }).then(res => { | |||
| successToast('已移出人才库') | |||
| getData(); | |||
| }) | |||
| }, | |||
| onCancel() { | |||
| }, | |||
| }); | |||
| } | |||
| // const del = (id : number) => { | |||
| // commomParams.value.delParam = { id: id }; | |||
| // PostCompanyDepartmentDel(commomParams.value.delParam).then(res => { | |||
| // successToast('删除成功'); | |||
| // getData(); | |||
| // }) | |||
| // } | |||
| </script> | |||
| <style scoped lang="less"> | |||
| </style> | |||
| @@ -0,0 +1,123 @@ | |||
| <template> | |||
| <a-form :model="commomParams.search"> | |||
| <a-row :gutter="20"> | |||
| <a-col span="6"> | |||
| <a-form-item> | |||
| <a-select v-model:value="commomParams.search.department_id" @change="departmentChange" | |||
| placeholder="请进行搜索选择部门" show-search :filter-option="false" label-in-value | |||
| @search="departmentSearch"> | |||
| <a-select-option v-for="item in department_list" :key="item.id" :value="item.id" | |||
| :label="item.name" label-in-value>{{item.name}}</a-select-option> | |||
| </a-select> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="6"> | |||
| <a-form-item> | |||
| <a-select v-model:value="commomParams.search.job_id" @change="jobChange" | |||
| placeholder="请进行搜索选择职位" show-search :filter-option="false" label-in-value | |||
| @search="jobSearch"> | |||
| <a-select-option v-for="item in job_list" :key="item.id" :value="item.id" | |||
| :label="item.name" label-in-value>{{item.name}}</a-select-option> | |||
| </a-select> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="6"> | |||
| <a-form-item> | |||
| <a-select v-model:value="commomParams.search.status" @change="statusChange" | |||
| placeholder="简历查看状态"> | |||
| <a-select-option :key="1">已查看</a-select-option> | |||
| <a-select-option :key="2">未查看</a-select-option> | |||
| </a-select> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="6"> | |||
| <a-button type="primary" @click="clearSearch">重置</a-button> | |||
| </a-col> | |||
| </a-row> | |||
| </a-form> | |||
| </template> | |||
| <script lang="ts" setup> | |||
| import { ref, onMounted, watch, computed } from 'vue'; | |||
| import { GetCompanyDepartmentList, PostCompanyJobList } from '@/apis/models'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| let { commomParams } = useCommon(); | |||
| let props = defineProps(['search_params']); | |||
| const emit = defineEmits(); | |||
| interface listType { | |||
| department_id : String | |||
| job_id : String | |||
| status : String, | |||
| customer_name : String | |||
| } | |||
| commomParams.value.search = commomParams.value.search as listType; | |||
| commomParams.value.search.department_id = null; | |||
| commomParams.value.search.job_id = null; | |||
| commomParams.value.search.status = null; | |||
| commomParams.value.search.customer_name = ''; | |||
| watch(() => props.search_params, (newVal) => { | |||
| emit('searchData', commomParams.value.search) | |||
| },{ | |||
| immediate: true | |||
| }) | |||
| const getData = () => { | |||
| emit('searchData', commomParams.value.search) | |||
| } | |||
| // 清空搜索 | |||
| const clearSearch = () => { | |||
| commomParams.value.search = { | |||
| page: 1, | |||
| pagesize: 10, | |||
| sort: 'id', | |||
| sortby: 'asc', | |||
| keyword: '' | |||
| } | |||
| emit('clearData', commomParams.value.search) | |||
| } | |||
| onMounted(() => { | |||
| departmentSearch() | |||
| JobSearch() | |||
| }) | |||
| // 选择部门 | |||
| let department_list = ref<Object[]>([]) | |||
| const departmentSearch = (val) => { | |||
| GetCompanyDepartmentList({pagesize: 100, keyword: val }).then(res => { | |||
| department_list.value = res.data.rows; | |||
| }) | |||
| } | |||
| const departmentChange = (val : Object) => { | |||
| commomParams.value.search.department_id = val.key; | |||
| getData() | |||
| } | |||
| // 选择职位 | |||
| let job_list = ref<Object[]>([]) | |||
| const JobSearch = (val) => { | |||
| PostCompanyJobList({pagesize: 100, keyword: val }).then(res => { | |||
| job_list.value = res.data.list; | |||
| }) | |||
| } | |||
| const jobChange = (val : Object) => { | |||
| commomParams.value.search.job_id = val.key; | |||
| getData() | |||
| } | |||
| const statusChange = (val : Object) => { | |||
| commomParams.value.search.status = val; | |||
| getData() | |||
| } | |||
| </script> | |||
| <style> | |||
| </style> | |||
| @@ -0,0 +1,191 @@ | |||
| <template> | |||
| <a-card title="简历搜索" :headStyle="{ 'background-color': '#f0f0f0' }"> | |||
| <a-form :model="commomParams.search" layout="vertical"> | |||
| <a-row :gutter="20"> | |||
| <a-col span="12"> | |||
| <a-form-item label="关键字" name="keyword"> | |||
| <a-input v-model:value="commomParams.search.keyword" placeholder="请输入关键字" size="large"/> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="职称"> | |||
| <a-xuanze :dict="2012" placeholder="请选择职称" @saveSelect="saveTitle" | |||
| :select_content="commomParams.search.title"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="性别" name="sex"> | |||
| <a-radio-group v-model:value="commomParams.search.gender" button-style="solid" style="width: 100%;" size="large"> | |||
| <a-radio-button value="男" style="width: calc(100% / 3);">男</a-radio-button> | |||
| <a-radio-button value="女" style="width: calc(100% / 3);">女</a-radio-button> | |||
| <a-radio-button value="不限" style="width: calc(100% / 3);">不限</a-radio-button> | |||
| </a-radio-group> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="学历"> | |||
| <a-xuanze :dict="2012" placeholder="请选择学历" @saveSelect="saveEducation" | |||
| :select_content="commomParams.search.education"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="户口所在地"> | |||
| <a-xuanze :dict="2012" placeholder="请选择民族" @saveSelect="saveEthnicity" | |||
| :select_content="commomParams.search.marital_status"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="学历"> | |||
| <a-xuanze :dict="2006" placeholder="请选择学历" @saveSelect="saveSchoolDegree" | |||
| :select_content="commomParams.search.political_status"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="含最高学历" name="degree_better"> | |||
| <a-xuanze :dict="2012" placeholder="请选择民族" @saveSelect="saveEthnicity" | |||
| :select_content="commomParams.search.available_date_desire"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item required label="英语"> | |||
| <a-xuanze :dict="2012" placeholder="请选择民族" @saveSelect="saveEthnicity" | |||
| :select_content="commomParams.search.english"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item required label="国语"> | |||
| <a-xuanze :dict="2012" placeholder="请选择民族" @saveSelect="saveEthnicity" | |||
| :select_content="commomParams.search.ethnicity"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item required label="粤语"> | |||
| <a-xuanze :dict="2012" placeholder="请选择民族" @saveSelect="saveEthnicity" | |||
| :select_content="commomParams.search.cantonese"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item required label="第二外语"> | |||
| <a-xuanze :dict="2012" placeholder="请选择民族" @saveSelect="saveEthnicity" | |||
| :select_content="commomParams.search.other_language"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item required label="计算机能力"> | |||
| <a-input v-model:value="value" placeholder="请输入计算机能力" size="large"/> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item required label="工作经验"> | |||
| <a-xuanze :dict="2012" placeholder="请选择民族" @saveSelect="saveEthnicity" | |||
| :select_content="commomParams.search.ethnicity"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="最小年龄" name="age_min"> | |||
| <a-xuanze :dict="2012" placeholder="请选择民族" @saveSelect="saveEthnicity" | |||
| :select_content="commomParams.search.ethnicity"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="12"> | |||
| <a-form-item label="最大年龄" name="age_max"> | |||
| <a-xuanze :dict="2012" placeholder="请选择民族" @saveSelect="saveEthnicity" | |||
| :select_content="commomParams.search.ethnicity"></a-xuanze> | |||
| </a-form-item> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-flex justify="flex-end"> | |||
| <a-space> | |||
| <a-button type="primary" @click="saveForm" size="large">开始搜索</a-button> | |||
| </a-space> | |||
| </a-flex> | |||
| </a-col> | |||
| </a-row> | |||
| </a-form> | |||
| </a-card> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, onMounted, watch, computed } from 'vue'; | |||
| import { PostJobseekerList } from '@/apis/models'; | |||
| import { useCommon } from '@/hooks/useCommon'; | |||
| let { store, commomParams, dayjs, richOption, ExclamationCircleOutlined, Modal } = useCommon(); | |||
| let props = defineProps(['search_params']); | |||
| const emit = defineEmits(); | |||
| interface listType { | |||
| title ?: Number, | |||
| education ?: Number, | |||
| marital_status ?: Number, | |||
| ethnicity ?: Number, | |||
| political_status ?: Number, | |||
| available_date_desire ?: Number, | |||
| english ?: Number, | |||
| mandarin ?: Number, | |||
| cantonese ?: Number, | |||
| other_language ?: Number, | |||
| max_work_experience ?: Number, | |||
| min_work_experience ?: Number, | |||
| gender ?: Number, | |||
| maxheight ?: Number, | |||
| minheight ?: Number, | |||
| maxweight ?: Number, | |||
| minweight ?: Number, | |||
| } | |||
| commomParams.value.search = commomParams.value.search as listType; | |||
| commomParams.value.search.title = 0; | |||
| commomParams.value.search.education = 0; | |||
| commomParams.value.search.marital_status = 0; | |||
| commomParams.value.search.ethnicity = 0; | |||
| commomParams.value.search.political_status = 0; | |||
| commomParams.value.search.available_date_desire = 0; | |||
| commomParams.value.search.english = 0; | |||
| commomParams.value.search.mandarin = 0; | |||
| commomParams.value.search.cantonese = 0; | |||
| commomParams.value.search.other_language = ''; | |||
| commomParams.value.search.max_work_experience = 0; | |||
| commomParams.value.search.min_work_experience = 0; | |||
| commomParams.value.search.gender = 0; | |||
| commomParams.value.search.maxheight = 0; | |||
| commomParams.value.search.minheight = 0; | |||
| commomParams.value.search.maxweight = 0; | |||
| commomParams.value.search.minweight = 0; | |||
| watch(() => props.search_params, (newVal) => { | |||
| emit('searchData', commomParams.value.search) | |||
| }, { | |||
| immediate: true | |||
| }) | |||
| const getData = () => { | |||
| emit('searchData', commomParams.value.search) | |||
| } | |||
| // 清空搜索 | |||
| const clearSearch = () => { | |||
| commomParams.value.search = { | |||
| page: 1, | |||
| pagesize: 12, | |||
| sort: 'id', | |||
| sortby: 'asc', | |||
| keyword: '' | |||
| } | |||
| emit('clearData', commomParams.value.search) | |||
| } | |||
| </script> | |||
| <style> | |||
| </style> | |||
| <style> | |||
| </style> | |||
| @@ -0,0 +1,74 @@ | |||
| <template> | |||
| <div style="height: 100%;"> | |||
| <template v-if="detail"> | |||
| <a-page-header> | |||
| <template #title> | |||
| <a-button @click="back" type="link"> | |||
| <ArrowLeftOutlined />返回 | |||
| </a-button> | |||
| </template> | |||
| <a-card style="width: 100%"> | |||
| <a-card-meta :title="detail.title" :description="'发布时间:'+detail.created_at"> | |||
| </a-card-meta> | |||
| <a-divider /> | |||
| <div v-html="detail.content"></div> | |||
| </a-card> | |||
| </a-page-header> | |||
| </template> | |||
| <template v-else> | |||
| <a-list item-layout="horizontal" :data-source="articleList"> | |||
| <template #renderItem="{ item }"> | |||
| <a-list-item> | |||
| <a-list-item-meta description="2020-11-12"> | |||
| <template #title> | |||
| {{ item.title }} | |||
| </template> | |||
| </a-list-item-meta> | |||
| <template #extra> | |||
| <a-button @click="download(item.cover_img)">下载</a-button> | |||
| </template> | |||
| </a-list-item> | |||
| </template> | |||
| </a-list> | |||
| <a-pagination v-model:current="current" :total="500" style="text-align: center;" /> | |||
| </template> | |||
| </div> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, computed, onMounted, defineProps, watch } from 'vue'; | |||
| import { GetArticleList } from '@/apis/models'; | |||
| import { ArrowLeftOutlined } from '@ant-design/icons-vue'; | |||
| let props = defineProps(['key_id']); | |||
| let articleList = ref<object[]>([]) | |||
| let detail = ref<Object>(null) | |||
| let key = ref<Number>(10) | |||
| const getArticleList = (val) => { | |||
| GetArticleList({ section_id: val }).then(res => { | |||
| articleList.value = res.data.articles | |||
| }) | |||
| } | |||
| const toDetail = (data) => { | |||
| detail.value = data | |||
| } | |||
| const back = (data) => { | |||
| detail.value = null | |||
| } | |||
| const download = (val) => { | |||
| let url = 'https://rcsc-test.jcjob.cn/img' + val; | |||
| window.open(url); | |||
| } | |||
| watch(() => props.key_id, (newVal) => { | |||
| key.value = newVal | |||
| getArticleList(newVal) | |||
| }, { immediate: true }) | |||
| </script> | |||
| <style> | |||
| </style> | |||
| @@ -1,18 +1,36 @@ | |||
| <template> | |||
| <a-cascader v-model:value="cascaderParentId" @change="parentChange" :options="listOptions" | |||
| :fieldNames="listFieldNames" :changeOnSelect="true" :placeholder="placeholder" style="width: 100%" change-on-select/> | |||
| :fieldNames="listFieldNames" :changeOnSelect="true" :placeholder="placeholder" style="width: 100%" | |||
| change-on-select :size="size" /> | |||
| </template> | |||
| <script lang="ts" setup> | |||
| import { ref, onMounted, defineProps, watch, defineEmits } from 'vue'; | |||
| import { GetDictTree } from '@/apis/models'; | |||
| const props = defineProps(['dict', 'placeholder', 'cascader_content']); | |||
| const props = defineProps({ | |||
| dict: { | |||
| type: String, | |||
| default: '' | |||
| }, | |||
| placeholder: { | |||
| type: String, | |||
| default: '' | |||
| }, | |||
| cascader_content: { | |||
| type: Array, | |||
| default: [] | |||
| }, | |||
| size: { | |||
| type: String, | |||
| default: 'large' | |||
| }, | |||
| }); | |||
| let listOptions = ref([]); | |||
| let cascaderParentId = ref<String>([]); | |||
| let cascaderParentId = ref<Number>([]); | |||
| const listFieldNames = ref({ label: 'name', value: 'id', children: 'children' }); | |||
| let placeholder = ref('请选择'); | |||
| placeholder.value = props.placeholder | |||
| watch(() => [props.dict, props.cascader_content], | |||
| let size = ref('large'); | |||
| watch(() => [props.dict, props.cascader_content, props.placeholder, props.size], | |||
| (newVal, oldVal) => { | |||
| GetDictTree({ | |||
| code: newVal[0] | |||
| @@ -20,19 +38,21 @@ | |||
| listOptions.value = res.data.dicts | |||
| }) | |||
| cascaderParentId.value = newVal[1] | |||
| }) | |||
| placeholder.value = newVal[2] | |||
| size.value = newVal[3] | |||
| },{immediate: true}) | |||
| onMounted(() => { | |||
| GetDictTree({ | |||
| code: props.dict | |||
| }).then(res => { | |||
| listOptions.value = res.data.dicts | |||
| listOptions.value = res.data.dicts | |||
| }) | |||
| }) | |||
| const emit = defineEmits(); | |||
| const parentChange = (val, selectedOptions) => { | |||
| console.log(val) | |||
| emit('saveCascader', {arr1: val, arr2: selectedOptions}); | |||
| emit('saveCascader', { arr1: val, arr2: selectedOptions }); | |||
| } | |||
| </script> | |||
| @@ -2,14 +2,31 @@ | |||
| <a-tree-select v-model:value="treecCascaderParentId" style="width: 100%" | |||
| :tree-data="treeData" tree-checkable allow-clear :show-checked-strategy="SHOW_PARENT" | |||
| :placeholder="placeholder" tree-node-filter-prop="label" | |||
| :fieldNames="listFieldNames" :maxTagCount="3" @change="parentChange" /> | |||
| :fieldNames="listFieldNames" :maxTagCount="3" @change="parentChange" :size="size"/> | |||
| </template> | |||
| <script lang="ts" setup> | |||
| import { ref, onMounted, defineProps, watch, defineEmits } from 'vue'; | |||
| import { GetDictTree } from '@/apis/models'; | |||
| import { TreeSelect } from 'ant-design-vue'; | |||
| const props = defineProps(['dict', 'placeholder', 'tree_content']); | |||
| const props = defineProps({ | |||
| dict: { | |||
| type: String, | |||
| default: '' | |||
| }, | |||
| placeholder: { | |||
| type: String, | |||
| default: '' | |||
| }, | |||
| tree_content: { | |||
| type: Array, | |||
| default: [] | |||
| }, | |||
| size: { | |||
| type: String, | |||
| default: 'large' | |||
| }, | |||
| }); | |||
| let treeData = ref([]); | |||
| let treecCascaderParentId = ref<number[]>([]); | |||
| const listFieldNames = ref({ label: 'name', value: 'id', children: 'children' }); | |||
| @@ -23,6 +40,7 @@ | |||
| }).then(res => { | |||
| treeData.value = res.data.dicts | |||
| }) | |||
| treecCascaderParentId.value = newVal[1] | |||
| }, {immediate: true}) | |||
| @@ -1,5 +1,5 @@ | |||
| <template> | |||
| <a-select v-model:value="selectValue" @change="handleChange" :placeholder="placeholder" label-in-value> | |||
| <a-select v-model:value="selectValue" @change="handleChange" :placeholder="placeholder" label-in-value size="large"> | |||
| <a-select-option v-for="item in listOptions" :key="item.id" :value="item.id" :label="item.name">{{item.name}}</a-select-option> | |||
| </a-select> | |||
| </template> | |||
| @@ -9,7 +9,7 @@ | |||
| import { GetDictTree } from '@/apis/models'; | |||
| const props = defineProps(['dict', 'placeholder', 'select_content']); | |||
| let listOptions = ref([]); | |||
| let selectValue = ref<String>(props.select_content); | |||
| let selectValue = ref<String>(null); | |||
| let placeholder = ref<String>(props.placeholder); | |||
| watch(() => [props.dict, props.select_content], | |||
| (newVal:string, oldVal:string) => { | |||
| @@ -18,7 +18,7 @@ | |||
| }).then((res:object) => { | |||
| listOptions.value = res.data.dicts | |||
| }) | |||
| selectValue.value = newVal[1] == 0 ? props.placeholder : newVal[1] ; | |||
| selectValue.value = newVal[1] ? newVal[1] : null; | |||
| }, { immediate: true }) | |||
| onMounted(() => { | |||
| @@ -0,0 +1,65 @@ | |||
| <template> | |||
| <template v-if="detail"> | |||
| <a-page-header> | |||
| <template #title> | |||
| <a-button @click="back" type="link"> | |||
| <ArrowLeftOutlined />返回 | |||
| </a-button> | |||
| </template> | |||
| <a-card style="width: 100%"> | |||
| <a-card-meta :title="detail.title" :description="'发布时间:'+detail.created_at"> | |||
| </a-card-meta> | |||
| <a-divider /> | |||
| <div v-html="detail.content"></div> | |||
| </a-card> | |||
| </a-page-header> | |||
| </template> | |||
| <template v-else> | |||
| <a-list item-layout="horizontal" :data-source="articleList"> | |||
| <template #renderItem="{ item }"> | |||
| <a-list-item @click="toDetail(item)"> | |||
| <a-list-item-meta> | |||
| <template #title> | |||
| {{ item.title }} | |||
| </template> | |||
| </a-list-item-meta> | |||
| </a-list-item> | |||
| </template> | |||
| </a-list> | |||
| <a-pagination v-model:current="current" :total="500" style="text-align: center;" /> | |||
| </template> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, computed, onMounted, defineProps, watch } from 'vue'; | |||
| import { GetArticleList } from '@/apis/models'; | |||
| import { ArrowLeftOutlined } from '@ant-design/icons-vue'; | |||
| let props = defineProps(['key_id']); | |||
| let articleList = ref<object[]>([]) | |||
| let detail = ref<Object>(null) | |||
| let key = ref<Number>(3) | |||
| const getArticleList = (val) => { | |||
| GetArticleList({section_id: val}).then(res => { | |||
| articleList.value = res.data.articles | |||
| }) | |||
| } | |||
| const toDetail = (data) => { | |||
| detail.value = data | |||
| } | |||
| const back = (data) => { | |||
| detail.value = null | |||
| } | |||
| watch(() => props.key_id, (newVal) => { | |||
| key.value = newVal | |||
| getArticleList(newVal) | |||
| }, { immediate: true }) | |||
| </script> | |||
| <style> | |||
| </style> | |||
| @@ -151,7 +151,7 @@ | |||
| let addOtherForm = ref({ | |||
| department_name: '请选择部门', | |||
| department_name: null, | |||
| describe_content: '', | |||
| daoqi_date: '', | |||
| job_nature: '', | |||
| @@ -1,29 +1,37 @@ | |||
| <template> | |||
| <template v-for="(item, index) in list"> | |||
| <div class="job-box"> | |||
| <div class="job-title"> | |||
| <div class="aaaa mt10"> | |||
| <div>前端工程师</div> | |||
| <div>500000-7000元</div> | |||
| </div> | |||
| <div> | |||
| <a-tag>Tag 1</a-tag> | |||
| <a-tag>Tag 1</a-tag> | |||
| <a-tag>Tag 1</a-tag> | |||
| <a-tag>Tag 1</a-tag> | |||
| </div> | |||
| </div> | |||
| <div class="job-company"> | |||
| <div class="aaaa mt10"> | |||
| <div>中山市海港城安域有限公司</div> | |||
| <div>查看更多</div> | |||
| </div> | |||
| <!-- <div> | |||
| 小榄镇 | |||
| </div> --> | |||
| </div> | |||
| </div> | |||
| </template> | |||
| <a-row :gutter="[10,20]"> | |||
| <a-col span="24" v-for="(item, index) in list"> | |||
| <a-flex vertical style="width: 100%;border-radius: 10px;padding: 20px 20px 0;"> | |||
| <a-space direction="vertical" :size="20"> | |||
| <a-flex justify="space-between" style="width: 100%;"> | |||
| <div style="font-size: 18px; font-weight: 600;width: 70%;">{{item.name}}</div> | |||
| <div>{{item.pay_range_text}}</div> | |||
| </a-flex> | |||
| <a-flex style="width: 100%;"> | |||
| <a-tag>{{item.experience_text ? item.experience_text : '不限'}}</a-tag> | |||
| <a-tag>{{item.certification_text ? item.certification_text : '不限'}}</a-tag> | |||
| <a-tag>{{item.school_degree_text ? item.school_degree_text : '不限'}}</a-tag> | |||
| <a-tag>{{item.profelevel_text ? item.profelevel_text : '不限'}}</a-tag> | |||
| </a-flex> | |||
| <a-flex justify="flex-end"> | |||
| <a-space> | |||
| <a-button type="primary" ghost size="small" @click="toDetail(item.id)">查看详情</a-button> | |||
| </a-space> | |||
| </a-flex> | |||
| </a-space> | |||
| <a-divider /> | |||
| <!-- <a-space direction="vertical"> | |||
| <a-flex justify="space-between" style="width: 100%;"> | |||
| <div>{{item.full_name}}</div> | |||
| <a-button type="primary" ghost size="small" @click="toDetail(item.id)">查看详情</a-button> | |||
| </a-flex> | |||
| <a-flex style="width: 100%;"> | |||
| {{item.locations ? item.locations[0].name : '未知地址'}} | |||
| </a-flex> | |||
| </a-space> --> | |||
| </a-flex> | |||
| </a-col> | |||
| </a-row> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| @@ -34,10 +42,16 @@ | |||
| let props = defineProps(['list']); | |||
| const emit = defineEmits(); | |||
| let list = ref<Object[]>([]) | |||
| const toDetail = (val) => { | |||
| emit('detail', {id: val}) | |||
| } | |||
| watch(() => [props.list], (newVal) => { | |||
| console.log(newVal[0]) | |||
| list.value = newVal[0] | |||
| }) | |||
| },{immediate: true}) | |||
| </script> | |||
| <style lang="less" scoped> | |||
| @@ -1,90 +1,85 @@ | |||
| <template> | |||
| <!-- <a-modal v-model:visible="visible" @ok="handleOk" :footer="null" title="职位详情"> --> | |||
| <!-- justify flex 布局下的水平排列方式:start end center space-around space-between --> | |||
| <!-- align flex 布局下的垂直对齐方式:top middle bottom --> | |||
| <!-- <div style="margin-top: 30px;"> --> | |||
| <a-row :gutter="[10,10]" type="flex" justify="space-between"> | |||
| <a-col span="14"> | |||
| <a-row :gutter="[10,10]"> | |||
| <a-col span="24"> | |||
| <a-row :gutter="[10,10]" type="flex"> | |||
| <a-col> | |||
| 前端工程师 | |||
| </a-col> | |||
| <a-col> | |||
| 2000-1000000 | |||
| </a-col> | |||
| </a-row> | |||
| <a-row :gutter="[10,10]" type="flex" justify="space-between" v-if="detail"> | |||
| <a-col span="14"> | |||
| <a-row :gutter="[10,10]"> | |||
| <a-col span="24"> | |||
| <a-row :gutter="[10,20]" type="flex"> | |||
| <a-col> | |||
| <div style="font-size: 18px; font-weight: 600;">{{detail.base.name}}</div> | |||
| </a-col> | |||
| <a-col span="24"> | |||
| <a-row :gutter="[10,10]" type="flex"> | |||
| <a-col> | |||
| <a-tag>Tag 1</a-tag> | |||
| </a-col> | |||
| <a-col> | |||
| <a-tag>Tag 1</a-tag> | |||
| </a-col> | |||
| <a-col> | |||
| <a-tag>Tag 1</a-tag> | |||
| </a-col> | |||
| </a-row> | |||
| <a-col> | |||
| <div style="font-size: 18px;">{{detail.base.pay_range_text}}</div> | |||
| </a-col> | |||
| </a-row> | |||
| </a-col> | |||
| <a-col span="10"> | |||
| <div style="height: 100%;display: flex;align-items: center;justify-content: flex-end;"> | |||
| <a-button> | |||
| <StarOutlined /> | |||
| 收藏 | |||
| </a-button> | |||
| <a-button> | |||
| <StarOutlined /> | |||
| 打印 | |||
| </a-button> | |||
| <a-button> | |||
| 投简历 | |||
| </a-button> | |||
| </div> | |||
| <a-col span="24"> | |||
| <a-row :gutter="[10,10]" type="flex"> | |||
| <a-tag>{{detail.require.experience_text ? detail.require.experience_text : '不限'}}</a-tag> | |||
| <a-tag>{{detail.require.certification_text ? detail.require.certification_text : '不限'}}</a-tag> | |||
| <a-tag>{{detail.require.school_degree_text ? detail.require.school_degree_text : '不限'}}</a-tag> | |||
| <a-tag>{{detail.require.profelevel_text ? detail.require.profelevel_text : '不限'}}</a-tag> | |||
| </a-row> | |||
| </a-col> | |||
| </a-row> | |||
| <div style="margin-top: 30px;"> | |||
| <!-- <div>职位描述:</div> --> | |||
| <!-- <div v-html=""></div> --> | |||
| <a-descriptions :column="2" title="职位描述" > | |||
| <a-descriptions-item label="职位性质" >Zhou Maomao</a-descriptions-item> | |||
| <a-descriptions-item label="招聘人数">1810000000</a-descriptions-item> | |||
| <a-descriptions-item label="工作地区">Hangzhou, Zhejiang</a-descriptions-item> | |||
| <a-descriptions-item label="月新范围">empty</a-descriptions-item> | |||
| <a-descriptions-item label="食宿条件">empty</a-descriptions-item> | |||
| <a-descriptions-item label="节假日">Zhou Maomao</a-descriptions-item> | |||
| <a-descriptions-item label="有效期">1810000000</a-descriptions-item> | |||
| <a-descriptions-item label="有效期至">Hangzhou, Zhejiang</a-descriptions-item> | |||
| <a-descriptions-item label="联系人">empty</a-descriptions-item> | |||
| <a-descriptions-item label="职业类别">empty</a-descriptions-item> | |||
| <a-descriptions-item label="联系电话">empty</a-descriptions-item> | |||
| <a-descriptions-item></a-descriptions-item> | |||
| <a-descriptions-item label="职业描述">empty</a-descriptions-item> | |||
| </a-descriptions> | |||
| </a-col> | |||
| <a-col span="10"> | |||
| <div style="height: 100%;display: flex;align-items: center;justify-content: flex-end;"> | |||
| <a-button> | |||
| <StarOutlined /> | |||
| 收藏 | |||
| </a-button> | |||
| <a-button> | |||
| 投简历 | |||
| </a-button> | |||
| </div> | |||
| <!-- </div> --> | |||
| <!-- </a-modal> --> | |||
| </a-col> | |||
| </a-row> | |||
| <div style="margin-top: 30px;" v-if="detail"> | |||
| <a-descriptions :column="2" title="职位描述"> | |||
| <a-descriptions-item label="职位性质">{{detail.company.nature_text}}</a-descriptions-item> | |||
| <a-descriptions-item label="招聘人数">{{detail.base.invite_count}}人</a-descriptions-item> | |||
| <a-descriptions-item | |||
| label="工作地区">{{detail.locations ? detail.locations[0].name : '未知地址'}}</a-descriptions-item> | |||
| <a-descriptions-item label="月新范围">{{detail.base.pay_range_text}}</a-descriptions-item> | |||
| <a-descriptions-item label="食宿条件">{{detail.base.shisu_text}}</a-descriptions-item> | |||
| <a-descriptions-item label="节假日">{{detail.base.holidays_text}}</a-descriptions-item> | |||
| <a-descriptions-item label="有效期">{{detail.base.disabled_date}}</a-descriptions-item> | |||
| <a-descriptions-item label="有效期至">{{detail.base.name}}</a-descriptions-item> | |||
| <a-descriptions-item label="联系人">{{detail.contact.contact}}</a-descriptions-item> | |||
| <a-descriptions-item | |||
| label="职业类别">{{detail.base.types ? detail.base.types[0].name : '未知'}}</a-descriptions-item> | |||
| <a-descriptions-item label="联系电话">{{detail.contact.mobile}} <a-button size="small"> | |||
| 查看 | |||
| </a-button></a-descriptions-item> | |||
| <a-descriptions-item></a-descriptions-item> | |||
| <a-descriptions-item label="职业描述"> | |||
| <div v-html="detail.base.describe_text"></div></a-descriptions-item> | |||
| </a-descriptions> | |||
| </div> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, computed, onMounted } from 'vue'; | |||
| import { StarOutlined } from '@ant-design/icons-vue'; | |||
| let visible = ref(false) | |||
| onMounted(() => { | |||
| }) | |||
| import { ref, computed, onMounted, defineProps, watch } from 'vue'; | |||
| import { GetJobDetail } from '@/apis/models'; | |||
| let props = defineProps(['id']); | |||
| let job_id = ref<Number>(0) | |||
| let detail = ref<Object>(null) | |||
| const getDetail = () => { | |||
| GetJobDetail({ id: job_id.value }).then(res => { | |||
| detail.value = res.data; | |||
| }) | |||
| } | |||
| watch(() => props.id, (newVal) => { | |||
| job_id.value = newVal | |||
| if (job_id.value) { | |||
| getDetail() | |||
| } | |||
| }, { immediate: true }) | |||
| </script> | |||
| <style scoped lang="less"> | |||
| :deep(.ant-btn) { | |||
| border-radius: 0 !important; | |||
| } | |||
| </style> | |||
| </style> | |||
| @@ -0,0 +1,113 @@ | |||
| <template> | |||
| <a-flex justify="center"> | |||
| <a-space :size="50"> | |||
| <div style="font-size: 36px;">精选职位</div> | |||
| </a-space> | |||
| </a-flex> | |||
| <a-tabs v-model:activeKey="activeKey" @change="activeKeyChange"> | |||
| <a-tab-pane :key="1" tab="最新招聘"> | |||
| <job-list :list="jobList"></job-list> | |||
| </a-tab-pane> | |||
| <a-tab-pane :key="2" tab="急招职位" force-render> <job-list :list="jobList"></job-list></a-tab-pane> | |||
| <a-tab-pane :key="3" tab="高薪职位"> <job-list :list="jobList"></job-list></a-tab-pane> | |||
| <a-tab-pane :key="4" tab="校园招聘"> <job-list :list="jobList"></job-list></a-tab-pane> | |||
| </a-tabs> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, computed, onMounted } from 'vue'; | |||
| import { GetJobNewest, GetJobUrgentjobs, GetJobHighpayjobs, GetJobCampusjobs } from '@/apis/models'; | |||
| import JobList from '@/components/job/home/choiceness-job/job-list.vue' | |||
| let activeKey = ref<Number>(1); | |||
| let jobList = ref<object[]>([]) | |||
| let showData = ref(false) | |||
| const activeKeyChange = (val) => { | |||
| switch (val) { | |||
| case 1: | |||
| getNew() | |||
| break; | |||
| case 2: | |||
| getJobUrgentjobs() | |||
| break; | |||
| case 3: | |||
| getJobHighpayjobs() | |||
| break; | |||
| case 4: | |||
| getJobCampusjobs() | |||
| break | |||
| } | |||
| } | |||
| const getNew = () => { | |||
| GetJobNewest().then(res => { | |||
| sliceData(res.data.jobs) | |||
| }) | |||
| } | |||
| const getJobUrgentjobs = () => { | |||
| GetJobUrgentjobs().then(res => { | |||
| sliceData(res.data.jobs) | |||
| }) | |||
| } | |||
| const getJobHighpayjobs = () => { | |||
| GetJobHighpayjobs().then(res => { | |||
| sliceData(res.data.jobs) | |||
| }) | |||
| } | |||
| const getJobCampusjobs = () => { | |||
| GetJobCampusjobs().then(res => { | |||
| sliceData(res.data.jobs) | |||
| }) | |||
| } | |||
| const sliceData = (val) => { | |||
| if (val.length > 9) { | |||
| jobList.value = val.slice(0, 9) | |||
| } else { | |||
| jobList.value = val; | |||
| showData.value = false; | |||
| } | |||
| } | |||
| onMounted(() => { | |||
| getNew() | |||
| }) | |||
| </script> | |||
| <style lang="less" scoped> | |||
| .job-box { | |||
| display: flex; | |||
| flex-direction: column; | |||
| justify-content: space-around; | |||
| // align-items: center; | |||
| width: 100%; | |||
| .job-title { | |||
| padding: 20px; | |||
| background-color: #ffffff; | |||
| .aaaa { | |||
| display: flex; | |||
| justify-content: space-between; | |||
| } | |||
| } | |||
| .job-company { | |||
| padding: 20px; | |||
| background-color: #cccccc; | |||
| .aaaa { | |||
| display: flex; | |||
| justify-content: space-between; | |||
| } | |||
| } | |||
| } | |||
| .mt10 { | |||
| margin-bottom: 10px; | |||
| } | |||
| </style> | |||
| @@ -0,0 +1,92 @@ | |||
| <template> | |||
| <a-row :gutter="[10,10]"> | |||
| <a-col span="8" v-for="(item, index) in jobList"> | |||
| <a-flex vertical style="width: 100%;background-color: #fff;border-radius: 10px;padding: 20px;"> | |||
| <a-space direction="vertical" :size="20"> | |||
| <a-flex justify="space-between" style="width: 100%;"> | |||
| <div style="font-size: 18px; font-weight: 600;">{{item.name}}</div> | |||
| <div>{{item.pay_range_text}}</div> | |||
| </a-flex> | |||
| <a-flex style="width: 100%;"> | |||
| <a-tag>{{item.experience_text ? item.experience_text : '不限'}}</a-tag> | |||
| <a-tag>{{item.certification_text ? item.certification_text : '不限'}}</a-tag> | |||
| <a-tag>{{item.school_degree_text ? item.school_degree_text : '不限'}}</a-tag> | |||
| <a-tag>{{item.profelevel_text ? item.profelevel_text : '不限'}}</a-tag> | |||
| </a-flex> | |||
| </a-space> | |||
| <a-divider /> | |||
| <a-space direction="vertical"> | |||
| <a-flex justify="space-between" style="width: 100%;"> | |||
| <div>{{item.full_name}}</div> | |||
| <a-button type="primary" ghost size="small" | |||
| @click="toDetail(item.id, item.company_id)">查看详情</a-button> | |||
| </a-flex> | |||
| <a-flex style="width: 100%;"> | |||
| {{item.locations ? item.locations[0].name : '未知地址'}} | |||
| </a-flex> | |||
| </a-space> | |||
| </a-flex> | |||
| </a-col> | |||
| </a-row> | |||
| <a-flex justify="center"> | |||
| <a-space :size="50"> | |||
| <div style="font-size: 36px;">更多职位</div> | |||
| </a-space> | |||
| </a-flex> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, computed, onMounted, defineProps, watch } from 'vue'; | |||
| import { router } from '@/router'; | |||
| let props = defineProps(['list']); | |||
| let jobList = ref<Object[]>([]) | |||
| const toDetail = (job_id : Number, company_id : Number) => { | |||
| sessionStorage.setItem('job_id', job_id) | |||
| sessionStorage.setItem('tab_key', 2) | |||
| sessionStorage.setItem('pubilc_id', company_id) | |||
| sessionStorage.setItem('mode', 'detail') | |||
| router.push({ | |||
| path: '/personal' | |||
| }) | |||
| } | |||
| watch(() => props.list, (newVal) => { | |||
| jobList.value = newVal | |||
| }, { immediate: true }) | |||
| </script> | |||
| <style lang="less" scoped> | |||
| .job-box { | |||
| display: flex; | |||
| flex-direction: column; | |||
| justify-content: space-around; | |||
| // align-items: center; | |||
| width: 100%; | |||
| .job-title { | |||
| padding: 20px; | |||
| background-color: #ffffff; | |||
| .aaaa { | |||
| display: flex; | |||
| justify-content: space-between; | |||
| } | |||
| } | |||
| .job-company { | |||
| padding: 20px; | |||
| background-color: #cccccc; | |||
| .aaaa { | |||
| display: flex; | |||
| justify-content: space-between; | |||
| } | |||
| } | |||
| } | |||
| .mt10 { | |||
| margin-bottom: 10px; | |||
| } | |||
| </style> | |||
| @@ -0,0 +1,162 @@ | |||
| <!-- slice(0,6), 6,14 --> | |||
| <template> | |||
| <div style="display: flex;align-items: center;justify-content: center;padding: 30px;font-size: 36px;">热门企业</div> | |||
| <div class="mt10"> | |||
| <a-row :gutter="[10,10]"> | |||
| <a-col span="18"> | |||
| <a-row :gutter="[10,10]"> | |||
| <a-col span="8" v-for="(item, index) in data1"> | |||
| <a-card hoverable style="width: 100%;height: 222px;" @click="toCompanyDetail(item.id)"> | |||
| <template #cover> | |||
| <div style="width: 100%;padding-top: 20px;"> | |||
| <a-flex justify="center" align="center"> | |||
| <image-container | |||
| :imgObj="{src: 'https://admin1.jcjob.cn/img/' + item.image_url, width: adposition.width+'px',height: adposition.height+'px', mode: ''}"></image-container> | |||
| </a-flex> | |||
| </div> | |||
| </template> | |||
| <a-space direction="vertical" align="center" :size="2" style="width: 100%;"> | |||
| <div style="font-size: 16px;font-weight: bold;text-align: center;height: 48px;"> | |||
| {{item.company_name ? item.company_name : '企业'}} | |||
| </div> | |||
| <div>{{item.company_nature}} · {{item.company_scale}} | |||
| </div> | |||
| </a-space> | |||
| </a-card> | |||
| </a-col> | |||
| </a-row> | |||
| </a-col> | |||
| <a-col span="6"> | |||
| <a-row> | |||
| <a-col span="24"> | |||
| <a-card title="热门资讯" style="width: 100%;height: 454px;"> | |||
| <a-list size="small" :data-source="articleList"> | |||
| <template #renderItem="{ item, index }"> | |||
| <a-list-item> | |||
| <a-list-item-meta> | |||
| <template #title> | |||
| <a-avatar v-if="index + 1 == 1" :size="26" style="background-color: #ff1a1a"> | |||
| <span style="font-size: 14px;">{{index + 1}}</span> | |||
| </a-avatar> | |||
| <a-avatar v-if="index + 1 == 2" :size="26" style="background-color: #ff4d4d"> | |||
| <span style="font-size: 14px;">{{index + 1}}</span> | |||
| </a-avatar> | |||
| <a-avatar v-if="index + 1 == 3" :size="26" style="background-color: #ff6b6b"> | |||
| <span style="font-size: 14px;">{{index + 1}}</span> | |||
| </a-avatar> | |||
| <a-avatar v-if="index + 1 >= 4" :size="26"> | |||
| <span style="font-size: 14px;">{{index + 1}}</span> | |||
| </a-avatar> | |||
| {{ item.title }} | |||
| </template> | |||
| <template #avatar> | |||
| </template> | |||
| </a-list-item-meta> | |||
| </a-list-item> | |||
| </template> | |||
| </a-list> | |||
| </a-card> | |||
| </a-col> | |||
| </a-row> | |||
| </a-col> | |||
| </a-row> | |||
| </div> | |||
| <template v-if="showData"> | |||
| <a-row :gutter="[10,10]"> | |||
| <a-col span="6" v-for="(item, index) in data2"> | |||
| <a-card hoverable style="width: 100%;height: 222px;" @click="toCompanyDetail(item.id)"> | |||
| <template #cover> | |||
| <div style="width: 100%;padding-top: 20px;"> | |||
| <a-flex justify="center" align="center"> | |||
| <image-container | |||
| :imgObj="{src: 'https://admin1.jcjob.cn/img/' + item.image_url, width: adposition.width+'px',height: adposition.height+'px',mode: 'fill'}"></image-container> | |||
| </a-flex> | |||
| </div> | |||
| </template> | |||
| <a-space direction="vertical" align="center" :size="2" style="width: 100%;"> | |||
| <div style="font-size: 16px;font-weight: bold;text-align: center;height: 48px;"> | |||
| {{item.company_name ? item.company_name : '企业'}} | |||
| </div> | |||
| <div>{{item.company_nature}} · {{item.company_scale}} | |||
| </div> | |||
| </a-space> | |||
| </a-card> | |||
| </a-col> | |||
| </a-row> | |||
| </template> | |||
| </template> | |||
| <script setup lang="ts"> | |||
| import { ref, computed, onMounted } from 'vue'; | |||
| import { GetAdvertscheduleList, GetArticleList } from '@/apis/models'; | |||
| import { router } from '@/router'; | |||
| let data1 = ref([]) | |||
| let data2 = ref([]) | |||
| let adposition = ref(null) | |||
| let showData = ref(false) | |||
| let articleList = ref([]) | |||
| const getData = () => { | |||
| GetAdvertscheduleList({ pagesize: 20, area_id: 13 }).then(res => { | |||
| adposition.value = res.data.advertarea; | |||
| sliceData(res.data.advertschedules) | |||
| }) | |||
| } | |||
| const sliceData = (val) => { | |||
| if (val.length > 14) { | |||
| data1.value = val.slice(0, 6) | |||
| data2.value = val.slice(6, 14) | |||
| showData.value = true; | |||
| } else { | |||
| data1.value = val; | |||
| showData.value = false; | |||
| } | |||
| } | |||
| const getSection = () => { | |||
| GetArticleList({ pagesize: 8, hot: 2 }).then(res => { | |||
| articleList.value = res.data.articles; | |||
| }) | |||
| } | |||
| const toCompanyDetail = (val : Number) => { | |||
| sessionStorage.setItem('pubilc_id', val) | |||
| sessionStorage.setItem('mode', 'detail') | |||
| router.push({ | |||
| path: '/personal' | |||
| }) | |||
| } | |||
| onMounted(() => { | |||
| getData() | |||
| getSection() | |||
| }) | |||
| </script> | |||
| <style lang="less" scoped> | |||
| .compamy-box { | |||
| display: flex; | |||
| flex-direction: column; | |||
| justify-content: space-around; | |||
| align-items: center; | |||
| width: 100%; | |||
| padding: 10px; | |||
| background-color: #ffffff; | |||
| .compamy-img {} | |||
| .compamy-title {} | |||
| .compamy-nature {} | |||
| } | |||
| .mt10 { | |||
| margin-bottom: 10px; | |||
| } | |||
| </style> | |||