瀏覽代碼

Merge remote-tracking branch 'origin/master'

liao-sea 11 月之前
父節點
當前提交
43638b30fa

+ 2 - 0
src/main/java/com/hz/employmentsite/vo/companyService/PostVo.java

@@ -91,4 +91,6 @@ public class PostVo {
     public String professionID;
 
     public String professionName;
+
+    public String recommendNum; //推荐数量
 }

+ 1 - 0
src/main/java/com/hz/employmentsite/vo/jobUserManager/JobHuntVo.java

@@ -29,4 +29,5 @@ public class JobHuntVo {
     public String otherDemand;
     public Boolean isAccomplish;
     public String errorMessage;
+    public String recommendNum; // 推荐数量
 }

+ 1 - 0
src/main/java/com/hz/employmentsite/vo/jobUserManager/RecommendCompanyPostVo.java

@@ -9,4 +9,5 @@ public class RecommendCompanyPostVo {
     public String startTime;
     public String endTime;
     public String isRecommend;
+    public String companyAddress;
 }

+ 7 - 2
src/main/resources/mapping/cquery/JobHuntCQuery.xml

@@ -2,10 +2,13 @@
 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
 <mapper namespace="com.hz.employmentsite.mapper.cquery.JobHuntCQuery">
     <select id="getJobHuntList" resultType="com.hz.employmentsite.vo.jobUserManager.JobHuntVo">
-        select jobHunt.*,jobUser.name as JobUserName,dic_jobUserType.Name as jobUserTypeStr,dic_huntJobType.Name as jobHuntTypeStr,
-               profession.ProfessionName from pc_jobhunt jobHunt
+        select jobHunt.JobHuntID, jobHunt.JobUserID, jobHunt.ProfessionID, jobHunt.WorkCode, jobHunt.WorkName, jobHunt.AreaWork, jobHunt.InDate, jobHunt.WorkYear, jobHunt.JobHuntType, jobHunt.JobUserType, jobHunt.MinSalary, jobHunt.MaxSalary, jobHunt.CreateUserID, jobHunt.CreateTime, jobHunt.ModifyUserID, jobHunt.ModifyTime, jobHunt.OtherDemand
+        ,jobUser.name as JobUserName,dic_jobUserType.Name as jobUserTypeStr,dic_huntJobType.Name as jobHuntTypeStr
+        ,profession.ProfessionName, IFNULL(count(rmgt.RecommendMgtID),0) as recommendNum
+        from pc_jobhunt jobHunt
         left join pc_jobuser jobUser on jobHunt.JobUserID = jobUser.JobUserID
         left join pc_profession profession on jobHunt.professionID = profession.professionID
+        left join pc_recommend_mgt rmgt on jobHunt.JobHuntID = rmgt.JobHuntID
         left join (select * from sys_dictionary_item where DictionaryCode ='JobUserType') dic_jobUserType on jobHunt.JobUserType = dic_jobUserType.value
         left join (select * from sys_dictionary_item where DictionaryCode ='JobHuntType') dic_huntJobType on jobHunt.JobHuntType = dic_huntJobType.value
         where 1=1
@@ -46,6 +49,8 @@
        <!-- <if test="isAccomplish != '' and isAccomplish != null">
             and isAccomplish = #{isAccomplish}
         </if>-->
+        group by jobHunt.JobHuntID, jobHunt.JobUserID, jobHunt.ProfessionID, jobHunt.WorkCode, jobHunt.WorkName, jobHunt.AreaWork, jobHunt.InDate, jobHunt.WorkYear, jobHunt.JobHuntType, jobHunt.JobUserType, jobHunt.MinSalary, jobHunt.MaxSalary, jobHunt.CreateUserID, jobHunt.CreateTime, jobHunt.ModifyUserID, jobHunt.ModifyTime, jobHunt.OtherDemand
+        ,jobUser.`Name`,dic_jobUserType.`Name`,dic_huntJobType.`Name`, profession.ProfessionName
         order by jobHunt.CreateTime desc
     </select>
 </mapper>

+ 12 - 6
src/main/resources/mapping/cquery/PostCQuery.xml

@@ -3,15 +3,16 @@
 <mapper namespace="com.hz.employmentsite.mapper.cquery.PostCQuery">
     <select id="selectPostList" resultType="com.hz.employmentsite.vo.companyService.PostVo">
         select post.postID,post.workCode,post.workName,post.recruitCount,post.companyID,post.postName,post.recordStatus,post.workNature,post.validDay,
-               post.workYear,post.cultureRank,post.postDesc,post.maxSalary,post.minSalary,post.welfare,post.postEmail,post.workTime,post.isTrail,post.trailMonths,
-               post.TrailMaxSalary,post.trailMinSalary,post.createUserID,post.createTime,post.modifyUserID,post.modifyTime,post.validTime,post.startTime,post.endTime,
-               post.jobPlace,company.userName,company.userMobile,company.companyEmail,company.CompanyName,company.insuredCount,item.`Name` as cultureLevelName,
-               post.ProfessionID,pro.ProfessionName
+        post.workYear,post.cultureRank,post.postDesc,post.maxSalary,post.minSalary,post.welfare,post.postEmail,post.workTime,post.isTrail,post.trailMonths,
+        post.TrailMaxSalary,post.trailMinSalary,post.createUserID,post.createTime,post.modifyUserID,post.modifyTime,post.validTime,post.startTime,post.endTime,
+        post.jobPlace,company.userName,company.userMobile,company.companyEmail,company.CompanyName,company.insuredCount,item.`Name` as cultureLevelName,
+        post.ProfessionID,pro.ProfessionName
+        , IFNULL(count(rmgt.RecommendMgtID),0) as recommendNum
         from pc_post post
         left join pc_company company on post.CompanyID = company.CompanyID
         left join sys_dictionary_item item on item.value=post.CultureRank and item.DictionaryCode='CultureLevel'
         left join pc_profession pro on post.ProfessionID = pro.ProfessionID
-        where 1=1
+        left join pc_recommend_mgt rmgt on post.PostID = rmgt.PostID
         <if test="postIDList != '' and postIDList != null">
             and post.postID in (${postIDList})
         </if>
@@ -36,7 +37,12 @@
         <if test="companyID != null and companyID != ''">
             and post.CompanyID = #{companyID}
         </if>
-          order by post.CreateTime desc
+        group by post.postID,post.workCode,post.workName,post.recruitCount,post.companyID,post.postName,post.recordStatus,post.workNature,post.validDay,
+        post.workYear,post.cultureRank,post.postDesc,post.maxSalary,post.minSalary,post.welfare,post.postEmail,post.workTime,post.isTrail,post.trailMonths,
+        post.TrailMaxSalary,post.trailMinSalary,post.createUserID,post.createTime,post.modifyUserID,post.modifyTime,post.validTime,post.startTime,post.endTime,
+        post.jobPlace,company.userName,company.userMobile,company.companyEmail,company.CompanyName,company.insuredCount,item.`Name`,
+        post.ProfessionID,pro.ProfessionName
+        order by post.CreateTime desc
     </select>
     <select id="selectRecommendPostList" resultType="com.hz.employmentsite.vo.companyService.RecommendPostVo">
         select post.*,recommend.recommendID,jobhunt.JobUserID,recommend.isRead,recommend.isSendNotes,company.CompanyName,company.InsuredCount  from

+ 3 - 1
src/main/resources/mapping/cquery/RecommendMgtCQuery.xml

@@ -41,8 +41,9 @@
         </where>
         order by a.createtime desc
     </select>
+<!--    推荐岗位信息-->
     <select id="getRecommendCompanyPostList" resultType="com.hz.employmentsite.vo.jobUserManager.RecommendCompanyPostVo">
-        select a.postid,b.companyname,c.professionname,a.recruitcount,a.starttime,a.endtime,
+        select a.postid,b.companyname,c.professionname,a.recruitcount,a.starttime,a.endtime,b.companyAddress,
         case when d.recommendmgtid is null then '未推荐' else '已推荐' end as isRecommend,d.recommendMgtID
         from pc_post a
         left join pc_company b on a.CompanyID = b.CompanyID
@@ -64,6 +65,7 @@
         </where>
         order by a.CreateTime desc
     </select>
+<!--    推荐求职人员信息-->
     <select id="getRecommendJobList" resultType="com.hz.employmentsite.vo.jobUserManager.RecommendJobVo">
         select a.jobhuntid,b.username,b.usermobile,e.sitename,dic1.`name` as culturerankname,dic2.`name` as keypersontypename,
         case when d.recommendmgtid is null then '未推荐' else '已推荐' end as isrecommend,d.recommendMgtID

+ 13 - 5
vue/src/views/companyService/post/index.vue

@@ -93,11 +93,16 @@
                :row-key="record=>record.postID"
                bordered>
         <template #bodyCell="{ column, text, record }">
+          <template v-if="column.key === 'recommendNum'">
+            <div class="table-operation">
+              <a-button type="link" size="small" @click='onRecommendInfo(record)'>{{record.recommendNum}}</a-button>
+            </div>
+          </template>
           <template v-if="column.key === 'operation'">
             <div class="table-operation">
               <a-button type="link" size="small" @click='onEdit(record)' functioncode="T01020203">编辑</a-button>
               <a-button type="link" size="small" @click="onDel(record)" functioncode="T01020204">删除</a-button>
-              <a-button type="link" size="small" functioncode="T01030207" @click="onRecommendJob(record)" >推荐求职人员</a-button>
+              <a-button type="link" size="small"  @click="onRecommendJob(record)" functioncode="T01030207">推荐求职人员</a-button>
             </div>
           </template>
         </template>
@@ -208,6 +213,7 @@ export default defineComponent({
       },
       {title: '联系人', dataIndex: 'userName', key: 'userName', align: "center"},
       {title: '联系电话', dataIndex: 'userMobile', key: 'userMobile', width: 200, align: "center"},
+      {title: '推荐数量', key: 'recommendNum', align: "center"},
       {title: '操作', key: 'operation', fixed: 'right', width: 200, align: "center"},
     ];
     const pagination = computed(() => ({
@@ -217,7 +223,6 @@ export default defineComponent({
       showSizeChanger: true,
       showTotal: total => getPaginationTotalTitle(total)
     }));
-
     const tabsViewStore = useTabsViewStore();
     const dataList = ref([]);
     const loadData = async function () {
@@ -233,13 +238,15 @@ export default defineComponent({
       tabsViewStore.addTabByPath('/companyService/post/add', {});
     };
     const onEdit = (item: any) => {
-      console.log(item);
-      console.log(item.postID);
       tabsViewStore.addTabByPath('/companyService/post/edit', {id: item.postID});
     };
 
     const onRecommendJob = (item) =>{
-      recommendRef.value.show(item.professionID,item.professionName,item.postID,item.companyName);
+      recommendRef.value.show(item.professionID,item.professionName,item.postID,item.companyName,0,'推荐求职人员');
+    }
+
+    const onRecommendInfo = (item) =>{
+      recommendRef.value.show(item.professionID,item.professionName,item.postID,item.companyName,1,'求职人员信息');
     }
 
     const handleTableChange: TableProps['onChange'] = (pag: { pageSize: number; current: number },) => {
@@ -319,6 +326,7 @@ export default defineComponent({
       onAdd,
       onEdit,
       onRecommendJob,
+      onRecommendInfo,
       expand,
       postStatusList,
       companyList

+ 13 - 9
vue/src/views/companyService/post/recommend.vue

@@ -2,7 +2,7 @@
   <a-modal
     :width="1300"
     v-model:visible="visible"
-    title="推荐求职人员"
+    :title="title"
     :confirm-loading="confirmLoading"
     @ok="handleOk"
     ok-text="确认"
@@ -29,7 +29,7 @@
                        placeholder=""/>
             </a-form-item>
           </a-col>
-          <a-col :span="4"></a-col>
+          <a-col :span="7"></a-col>
           <a-col :span="5" style="text-align: left">
             <a-button type="primary" html-type="submit" @click="onSearch">查询</a-button>
             <a-button
@@ -89,7 +89,7 @@
         </a-row>
         <a-row class="edit-operation">
           <a-col :span="24" style="text-align: right">
-            <a-button type="primary" html-type="submit" functioncode="T01030202" @click='onBatchRecommend()'>批量推荐
+            <a-button type="primary" html-type="submit" v-if="searchParams.type===0" functioncode="T01030202" @click='onBatchRecommend()'>批量推荐
             </a-button>
           </a-col>
         </a-row>
@@ -100,7 +100,7 @@
                  :row-selection="{ selectedRowKeys: formState.selectedRowKeys, onChange: onSelectChange }"
                  :row-key="(record) => record.recommendMgtID" bordered @change="handleTableChange">
           <template #bodyCell="{ column, text, record }">
-            <template v-if="column.key === 'operation'">
+            <template v-if="searchParams.type===0 && column.key === 'operation'">
               <div class="table-operation">
                 <a-button type="link" size="small" @click='onRecommend(record)'>推荐
                 </a-button>
@@ -129,6 +129,7 @@ export default defineComponent({
     const confirmLoading = ref<boolean>(false);
     const formRef = ref<FormInstance>();
     const expand = ref(true);
+    const title = ref<string>('');
     const searchParams = reactive({
       pageIndex: 1,
       pageSize: 10,
@@ -139,7 +140,7 @@ export default defineComponent({
       professionName: null,
       cultureLeve: null,
       keyPersonType: null,
-      type: 0
+      type: null
     });
     const formState = reactive({
       total: 0,
@@ -199,15 +200,17 @@ export default defineComponent({
       dataList.value = result.list;
       formState.total = result.total;
       formState.loading = false;
-      console.log("huntParams", searchParams);
     };
 
-    const show = (professionID: any, professionName: any, postID: any, companyName: any) => {
+    const show = (professionID: any, professionName: any, postID: any, companyName: any, type: any, titleName: string) => {
       visible.value = true;
+      title.value = titleName;
       searchParams.postID = postID;
       searchParams.companyName = companyName;
       searchParams.professionID = professionID;
       searchParams.professionName = professionName;
+      searchParams.professionName = professionName;
+      searchParams.type = type;
       loadData();
     }
 
@@ -216,7 +219,7 @@ export default defineComponent({
         recommendMgtID: item.recommendMgtID,
         jobHuntID: item.jobhuntID,
         postID: searchParams.postID,
-        recommendType: searchParams.type
+        recommendType: 0
       });
       addRecommend(addRecommendList.value).then(() => {
         loadData();
@@ -236,7 +239,7 @@ export default defineComponent({
             recommendMgtID: item.recommendMgtID,
             jobHuntID: item.jobhuntID,
             postID: searchParams.postID,
-            recommendType: searchParams.type
+            recommendType: 0
           });
         }
       })
@@ -267,6 +270,7 @@ export default defineComponent({
     };
 
     return {
+      title,
       visible,
       confirmLoading,
       formRef,

+ 12 - 2
vue/src/views/jobUserManager/jobhunt/index.vue

@@ -115,6 +115,11 @@
         :loading="formState.loading" :row-selection="{ selectedRowKeys: formState.selectedRowKeys, onChange: onSelectChange }"
         :row-key="(record) => record.jobHuntID" bordered @change="handleTableChange" >
         <template #bodyCell="{ column, text, record }">
+          <template v-if="column.key === 'recommendNum'">
+            <div class="table-operation">
+              <a-button type="link" size="small" @click='onRecommendInfo(record)'>{{record.recommendNum}}</a-button>
+            </div>
+          </template>
           <template v-if="column.key === 'operation'">
             <div class="table-operation">
               <a-button type="link" size="small" functioncode="T01030203" @click='onEdit(record.jobHuntID)' >编辑</a-button>
@@ -194,6 +199,7 @@ import Recommend from "@/views/jobUserManager/jobhunt/recommend.vue";
           return salary;
           }
         },
+        {title: '推荐数量', key: 'recommendNum', align: "center"},
         { title: '操作', key: 'operation', fixed: 'right', width: 170, align: "center"},
       ];
       const pagination = computed(() => ({
@@ -299,7 +305,6 @@ import Recommend from "@/views/jobUserManager/jobhunt/recommend.vue";
         dataList.value = result.list;
         formState.total = result.total;
         formState.loading = false;
-        console.log("huntParams",searchParamsState);
       };
 
       const onAdd =()=>{
@@ -311,7 +316,11 @@ import Recommend from "@/views/jobUserManager/jobhunt/recommend.vue";
       };
 
       const onRecommendCompanyPost = (item) =>{
-        recommendRef.value.show(item.professionID,item.professionName,item.jobHuntID,item.jobUserName);
+        recommendRef.value.show(item.professionID,item.professionName,item.jobHuntID,item.jobUserName,0,"推荐求职人员");
+      }
+
+      const onRecommendInfo = (item) =>{
+        recommendRef.value.show(item.professionID,item.professionName,item.jobHuntID,item.jobUserName,1,'求职人员信息');
       }
 
       const getJobHuntTypeList = () => {
@@ -352,6 +361,7 @@ import Recommend from "@/views/jobUserManager/jobhunt/recommend.vue";
         onEdit,
         onDel,
         onRecommendCompanyPost,
+        onRecommendInfo,
         onSelectChange,
         handleTableChange,
         getJobHuntTypeList,

+ 11 - 7
vue/src/views/jobUserManager/jobhunt/recommend.vue

@@ -2,7 +2,7 @@
   <a-modal
     :width="1100"
     v-model:visible="visible"
-    title="推荐岗位"
+    :title="title"
     :confirm-loading="confirmLoading"
     @ok="handleOk"
     ok-text="确认"
@@ -60,7 +60,7 @@
         </a-row>
         <a-row class="edit-operation">
           <a-col :span="24" style="text-align: right">
-            <a-button type="primary" html-type="submit" functioncode="T01030202" @click='onBatchRecommend()'>批量推荐
+            <a-button type="primary" v-if="searchParams.type===0" html-type="submit" functioncode="T01030202" @click='onBatchRecommend()'>批量推荐
             </a-button>
           </a-col>
         </a-row>
@@ -71,7 +71,7 @@
                  :row-selection="{ selectedRowKeys: formState.selectedRowKeys, onChange: onSelectChange }"
                  :row-key="(record) => record.recommendMgtID" bordered @change="handleTableChange">
           <template #bodyCell="{ column, text, record }">
-            <template v-if="column.key === 'operation'">
+            <template v-if="searchParams.type===0 && column.key === 'operation'">
               <div class="table-operation">
                 <a-button type="link" size="small" @click='onRecommend(record)'>推荐</a-button>
               </div>
@@ -98,6 +98,7 @@ export default defineComponent({
     const confirmLoading = ref<boolean>(false);
     const formRef = ref<FormInstance>();
     const expand = ref(false);
+    const title = ref<string>();
     const searchParams = reactive({
       pageIndex: 1,
       pageSize: 10,
@@ -133,6 +134,7 @@ export default defineComponent({
         title: '工作结束时间', dataIndex: 'endTime', key: 'endTime', width: 100, align: "center",
         customRender: ({record}) => record.endTime == null ? "" : dayjs(record.endTime).format('YYYY-MM-DD'),
       },
+      {title: '工作地点', dataIndex: 'companyAddress', key: 'companyAddress', width: 150, align: "center",},
       {title: '操作', key: 'operation', width: 60, align: 'center'},
     ];
     const pagination = computed(() => ({
@@ -168,15 +170,16 @@ export default defineComponent({
       dataList.value = result.list;
       formState.total = result.total;
       formState.loading = false;
-      console.log("huntParams", searchParams);
     };
 
-    const show = (professionID: any, professionName: any, jobHuntID: any, jobUserName: any) => {
+    const show = (professionID: any, professionName: any, jobHuntID: any, jobUserName: any, type: any, titleName: string) => {
       visible.value = true;
       searchParams.jobHuntID = jobHuntID;
       searchParams.jobUserName = jobUserName;
       searchParams.professionID = professionID;
       searchParams.professionName = professionName;
+      searchParams.type = type;
+      title.value = titleName;
       loadData();
     }
 
@@ -185,7 +188,7 @@ export default defineComponent({
         recommendMgtID: item.recommendMgtID,
         postID: item.postID,
         jobHuntID: searchParams.jobHuntID,
-        recommendType: searchParams.type
+        recommendType: 1
       });
       addRecommend(addRecommendList.value).then(() => {
         loadData();
@@ -205,7 +208,7 @@ export default defineComponent({
             recommendMgtID: item.recommendMgtID,
             postID: item.postID,
             jobHuntID: searchParams.jobHuntID,
-            recommendType: searchParams.type
+            recommendType: 1
           });
         }
       })
@@ -224,6 +227,7 @@ export default defineComponent({
     };
 
     return {
+      title,
       visible,
       confirmLoading,
       formRef,

+ 3 - 3
vue/src/views/jobUserManager/recommendMgt/index.vue

@@ -151,17 +151,17 @@ export default defineComponent({
         customRender: (item) =>
           `${searchParamsState.limit * (searchParamsState.page - 1) + item.index + 1}`,
       },
-      {title: '企业', dataIndex: 'companyName', key: 'companyName', width: 150},
-      {title: '企业电话', dataIndex: 'companyMobile', key: 'companyMobile', width: 150},
       {title: '求职者', dataIndex: 'name', key: 'name', width: 100},
       {title: '求职者电话', dataIndex: 'userMobile', key: 'userMobile', width: 150},
       {title: '岗位', dataIndex: 'professionName', key: 'professionName', width: 150},
+      {title: '企业', dataIndex: 'companyName', key: 'companyName', width: 150},
+      {title: '企业电话', dataIndex: 'companyMobile', key: 'companyMobile', width: 150},
       {title: '类型', dataIndex: 'recommendTypeName', key: 'recommendTypeName', width: 100},
       {title: '入职状态', dataIndex: 'entryStateName', key: 'entryStateName'},
       {title: '推送人', dataIndex: 'pushName', key: 'pushName'},
       {
         title: '推送时间', dataIndex: 'createTime', key: 'createTime',
-        customRender: ({record}) => dayjs(record.endDate).format('YYYY-MM-DD'),
+        customRender: ({record}) => dayjs(record.createTime).format('YYYY-MM-DD'),
       },
       {title: '操作', key: 'operation', width: 100, align: 'center'},
     ];