feat: Add functionality for companies to query their registered jobs without accessing admin details
This commit is contained in:
@@ -226,6 +226,16 @@ public class CmsPublicJobFairController extends BaseController {
|
||||
return publicJobFairService.removeCurrentCompanyJob(jobFairId, jobId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 企业查询自己已报名的岗位,不进入管理员招聘会详情页。
|
||||
*/
|
||||
@ApiOperation("查询企业报名岗位")
|
||||
@PreAuthorize("@ss.hasPermi('cms:publicJobFair:job:edit')")
|
||||
@GetMapping("/{jobFairId}/company/jobs")
|
||||
public AjaxResult getCurrentCompanyJobs(@ApiParam("招聘会ID") @PathVariable String jobFairId) {
|
||||
return success(publicJobFairService.getCurrentCompanyJobs(jobFairId));
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询招聘会报名列表
|
||||
*/
|
||||
|
||||
@@ -221,6 +221,10 @@ public class Job extends BaseEntity
|
||||
@ApiModelProperty("户外招聘会岗位审核时间")
|
||||
private String fairReviewTime;
|
||||
|
||||
@TableField(exist = false)
|
||||
@ApiModelProperty("公共招聘会岗位关联ID")
|
||||
private String fairRelationId;
|
||||
|
||||
//简历是否被查看
|
||||
@TableField(exist = false)
|
||||
private String isView;
|
||||
|
||||
@@ -123,6 +123,11 @@ public interface IPublicJobFairService {
|
||||
*/
|
||||
AjaxResult removeCurrentCompanyJob(String jobFairId, Long jobId);
|
||||
|
||||
/**
|
||||
* 查询当前企业已报名的岗位,不返回招聘会管理员详情。
|
||||
*/
|
||||
List<Job> getCurrentCompanyJobs(String jobFairId);
|
||||
|
||||
/**
|
||||
* 查询招聘会报名列表
|
||||
*/
|
||||
|
||||
@@ -474,6 +474,17 @@ public class PublicJobFairServiceImpl implements IPublicJobFairService {
|
||||
: AjaxResult.error("岗位移除失败");
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Job> getCurrentCompanyJobs(String jobFairId) {
|
||||
ensureCompanyOperation();
|
||||
if (StringUtils.isBlank(jobFairId)) {
|
||||
throw new ServiceException("招聘会ID不能为空");
|
||||
}
|
||||
Company company = getCurrentCompanyOrThrow();
|
||||
ensureApproved(jobFairId, company.getCompanyId());
|
||||
return publicJobFairMapper.selectJobListByJobFairIdAndCompanyId(jobFairId, company.getCompanyId());
|
||||
}
|
||||
|
||||
/**
|
||||
* 为企业端列表补充报名状态和按钮状态。
|
||||
*/
|
||||
|
||||
@@ -165,9 +165,9 @@
|
||||
</update>
|
||||
|
||||
<select id="selectJobListByJobFairIdAndCompanyId" resultType="com.ruoyi.cms.domain.Job">
|
||||
select j.job_id, j.job_title, j.min_salary, j.max_salary, j.education, j.experience,
|
||||
select pfj.id as fair_relation_id, j.job_id, j.job_title, j.min_salary, j.max_salary, j.education, j.experience,
|
||||
j.company_name, j.job_location, j.job_location_area_code, j.posting_date, j.vacancies,
|
||||
j.company_id, j.description, j.job_category
|
||||
j.company_id, j.description, j.job_category, j.job_address
|
||||
from public_job_fair_job pfj
|
||||
inner join job j on pfj.job_id = j.job_id
|
||||
where pfj.job_fair_id = #{jobFairId} and pfj.company_id = #{companyId} and pfj.del_flag = '0' and j.del_flag = '0'
|
||||
|
||||
Reference in New Issue
Block a user