Compare commits
72 Commits
bdc8a31b61
...
main
Author | SHA1 | Date | |
---|---|---|---|
8b3b7f63f9 | |||
9b9e80dc62 | |||
7752c74063 | |||
f4730c60fb | |||
d57ce9e3fc | |||
8988c52594 | |||
ba3e66a3c4 | |||
aa55276a81 | |||
8c5ec3e0b3 | |||
c795e63e96 | |||
9281eb700b | |||
8cf753ad54 | |||
65487c073f | |||
4c28d07bc3 | |||
a6d43c0bca | |||
070239d1d5 | |||
6680622a85 | |||
0eee50be78 | |||
2616b60283 | |||
be0b432140 | |||
![]() |
fca00d41a2 | ||
![]() |
b4da3c25a5 | ||
b7686c31b1 | |||
a6b5c06e63 | |||
44ec48c49d | |||
e56a8a285d | |||
418c22d78d | |||
d5473d922c | |||
c0aa835d19 | |||
dcc96bf689 | |||
a4cc7d8dbb | |||
7defcb6158 | |||
47351f41eb | |||
da48a9c33a | |||
ac2d427a71 | |||
7994112283 | |||
2502d9726b | |||
![]() |
5e1012a3fb | ||
64e991155d | |||
32424bc404 | |||
fcb421f97d | |||
1181ef0b1c | |||
5a6cfd695b | |||
e3975f557e | |||
1ddb62166a | |||
98f9182d43 | |||
d843197e5b | |||
60a9445e6f | |||
86b28f0071 | |||
73d8bdd402 | |||
7ee0b08b0d | |||
![]() |
db413c57aa | ||
0076eeeb48 | |||
2f28aa9c4d | |||
27746bd727 | |||
439b2b65af | |||
![]() |
9df9b42d20 | ||
![]() |
6d6439fbd9 | ||
![]() |
2ec8ab942a | ||
![]() |
131d6dd84f | ||
![]() |
cb133254b6 | ||
eb99236124 | |||
97fd823178 | |||
3f4558ba51 | |||
10cf0369c4 | |||
22ffa7db9c | |||
70360355a6 | |||
195828d706 | |||
39a5c380dd | |||
![]() |
f8a2ab99e3 | ||
![]() |
c934e29ad1 | ||
![]() |
e8d18b1fe6 |
@@ -11,7 +11,7 @@ MODEL_NAME=${JAR_PATH}
|
||||
PROFILE=dev
|
||||
|
||||
# JVM配置
|
||||
JVM_MEMORY=" -Xms256M -Xmx256M -XX:MaxDirectMemorySize=256M"
|
||||
JVM_MEMORY=" -Xms2048M -Xmx2048M -XX:MaxDirectMemorySize=2048M"
|
||||
# 远程调试
|
||||
JVM_DEBUG=""
|
||||
# JVM_DEBUG=" -agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=6011"
|
||||
|
@@ -2,11 +2,9 @@ package com.ruoyi.web.controller.system;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import com.ruoyi.common.constant.Constants;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.domain.entity.SysMenu;
|
||||
@@ -59,6 +57,15 @@ public class SysLoginController
|
||||
ajax.put(Constants.TOKEN, token);
|
||||
return ajax;
|
||||
}
|
||||
|
||||
@PostMapping("/app/appLogin")
|
||||
public AjaxResult appLogin(@RequestBody LoginBody loginBody)
|
||||
{
|
||||
AjaxResult ajax = AjaxResult.success();
|
||||
ajax=loginService.appLogin(loginBody);
|
||||
return ajax;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取用户信息
|
||||
*
|
||||
@@ -91,4 +98,15 @@ public class SysLoginController
|
||||
List<SysMenu> menus = menuService.selectMenuTreeByUserId(userId);
|
||||
return AjaxResult.success(menuService.buildMenus(menus));
|
||||
}
|
||||
@GetMapping("/sso/callback")
|
||||
public String ssoCallback(@RequestParam("ticket") String ticket) {
|
||||
String frontendIndexUrl = "http://domain.com";
|
||||
|
||||
String ruoyiJwtToken = loginService.loginOss(ticket);
|
||||
|
||||
String redirectUrl = frontendIndexUrl + "/index?token=" + ruoyiJwtToken;
|
||||
|
||||
// 返回 "redirect:" 即可触发 302 重定向
|
||||
return "redirect:" + redirectUrl;
|
||||
}
|
||||
}
|
||||
|
@@ -4,7 +4,8 @@ import java.util.List;
|
||||
import java.util.stream.Collectors;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import io.swagger.annotations.Api;
|
||||
import com.ruoyi.common.core.domain.entity.Company;
|
||||
import com.ruoyi.cms.service.ICompanyService;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.commons.lang3.ArrayUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@@ -56,6 +57,8 @@ public class SysUserController extends BaseController
|
||||
@Autowired
|
||||
private ISysPostService postService;
|
||||
|
||||
@Autowired
|
||||
private ICompanyService companyService;
|
||||
/**
|
||||
* 获取用户列表
|
||||
*/
|
||||
@@ -256,4 +259,34 @@ public class SysUserController extends BaseController
|
||||
{
|
||||
return success(deptService.selectDeptTreeList(dept));
|
||||
}
|
||||
|
||||
@ApiOperation("企业资质审核")
|
||||
@PreAuthorize("@ss.hasPermi('app:company:approval:list')")
|
||||
@PostMapping("/approval")
|
||||
public AjaxResult approval(@RequestBody Company company)
|
||||
{
|
||||
Company company1 = companyService.approval(company);
|
||||
SysUser sysUser = new SysUser();
|
||||
sysUser.setNickName(company1.getContactPerson());
|
||||
sysUser.setDeptId(101L);
|
||||
String contactPersonPhone = company1.getContactPersonPhone();
|
||||
if(StringUtils.isNotEmpty(contactPersonPhone)){
|
||||
String lastSixDigits = contactPersonPhone.substring(contactPersonPhone.length() - 6);
|
||||
sysUser.setPassword(lastSixDigits);
|
||||
sysUser.setUserName(company1.getContactPersonPhone());
|
||||
sysUser.setPhonenumber(company1.getContactPersonPhone());
|
||||
sysUser.setNickName(company1.getContactPersonPhone());
|
||||
}else{
|
||||
sysUser.setPassword("123456");
|
||||
sysUser.setUserName(company1.getName());
|
||||
sysUser.setNickName(company1.getName());
|
||||
}
|
||||
sysUser.setPhonenumber(getUsername());
|
||||
Long[] postIds = {1L};
|
||||
Long[] roleIds = {100L};
|
||||
sysUser.setPostIds(postIds);
|
||||
sysUser.setRoleIds(roleIds);
|
||||
userService.insertUser(sysUser);
|
||||
return AjaxResult.success();
|
||||
}
|
||||
}
|
||||
|
@@ -7,8 +7,10 @@ spring:
|
||||
# 主库数据源
|
||||
master:
|
||||
url: jdbc:highgo://127.0.0.1:5866/highgo?useUnicode=true&characterEncoding=utf8¤tSchema=ks_db4&stringtype=unspecified
|
||||
#username: syssso
|
||||
username: sysdba
|
||||
password: ZKR2024@com
|
||||
password: ZKR2024@comzkr
|
||||
|
||||
# 从库数据源
|
||||
slave:
|
||||
# 从数据源开关/默认关闭
|
||||
@@ -90,3 +92,5 @@ easy-es:
|
||||
process-index-mode: manual
|
||||
db-config:
|
||||
refresh-policy: immediate
|
||||
username: elastic
|
||||
password: zkr2024@@.com
|
@@ -8,7 +8,7 @@ spring:
|
||||
master:
|
||||
url: jdbc:highgo://124.243.245.42:5866/highgo?useUnicode=true&characterEncoding=utf8¤tSchema=ks_db4&stringtype=unspecified
|
||||
username: sysdba
|
||||
password: ZKR2024@com
|
||||
password: ZKR2024@comzkr
|
||||
# 从库数据源
|
||||
slave:
|
||||
# 从数据源开关/默认关闭
|
||||
@@ -89,3 +89,5 @@ easy-es:
|
||||
process-index-mode: manual
|
||||
db-config:
|
||||
refresh-policy: immediate
|
||||
username: elastic
|
||||
password: zkr2024@@.com
|
||||
|
@@ -1,7 +1,7 @@
|
||||
package com.ruoyi.cms.controller.app;
|
||||
|
||||
|
||||
import com.ruoyi.cms.domain.Company;
|
||||
import com.ruoyi.common.core.domain.entity.Company;
|
||||
import com.ruoyi.cms.domain.CompanyCard;
|
||||
import com.ruoyi.cms.domain.query.LabelQuery;
|
||||
import com.ruoyi.cms.mapper.CompanyCardMapper;
|
||||
@@ -12,6 +12,7 @@ import com.ruoyi.common.annotation.BussinessLog;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.annotations.ApiParam;
|
||||
@@ -111,7 +112,7 @@ public class AppCompanyController extends BaseController
|
||||
}
|
||||
@GetMapping("/label")
|
||||
@ApiOperation("公司标签下的公司")
|
||||
public TableDataInfo label(@RequestBody LabelQuery labelQuery)
|
||||
public TableDataInfo label(LabelQuery labelQuery)
|
||||
{
|
||||
CompanyCard companyCard = companyCardMapper.selectById(labelQuery.getCardId());
|
||||
startPage();
|
||||
@@ -133,4 +134,14 @@ public class AppCompanyController extends BaseController
|
||||
Company status = companyService.registerStatus();
|
||||
return AjaxResult.success(status);
|
||||
}
|
||||
|
||||
@GetMapping("/queryCodeCompany")
|
||||
@ApiOperation("根据社会信用代码查询企业")
|
||||
public AjaxResult queryCodeCompany(@RequestParam("code") String code)
|
||||
{
|
||||
if (!StringUtils.hasText(code)) {
|
||||
return AjaxResult.error("社会信用代码不能为空");
|
||||
}
|
||||
return AjaxResult.success(companyService.queryCodeCompany(code));
|
||||
}
|
||||
}
|
||||
|
@@ -1,18 +1,20 @@
|
||||
package com.ruoyi.cms.controller.app;
|
||||
|
||||
import com.ruoyi.cms.domain.File;
|
||||
import com.ruoyi.cms.service.IFileService;
|
||||
import com.ruoyi.common.annotation.BussinessLog;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@RestController
|
||||
@RequestMapping("/app/file")
|
||||
public class AppFileController {
|
||||
public class AppFileController extends BaseController {
|
||||
@Autowired
|
||||
private IFileService fileService;
|
||||
@BussinessLog(title = "上传文件")
|
||||
@@ -20,4 +22,12 @@ public class AppFileController {
|
||||
public AjaxResult uploadFile(@RequestParam("file") MultipartFile file, @RequestParam(value = "bussinessId",required = false) Long bussinessId) {
|
||||
return fileService.uploadFile(file,bussinessId);
|
||||
}
|
||||
|
||||
@BussinessLog(title = "获取附件列表")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(File file)
|
||||
{
|
||||
List<File> results = fileService.selectFileList(file);
|
||||
return getDataTable(results);
|
||||
}
|
||||
}
|
||||
|
@@ -6,6 +6,7 @@ import com.ruoyi.cms.domain.query.ESJobSearch;
|
||||
import com.ruoyi.cms.service.IESJobSearchService;
|
||||
import com.ruoyi.cms.service.IJobCollectionService;
|
||||
import com.ruoyi.cms.service.IJobService;
|
||||
import com.ruoyi.cms.util.sensitiveWord.SensitiveWordChecker;
|
||||
import com.ruoyi.common.annotation.BussinessLog;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
@@ -13,6 +14,7 @@ import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.annotations.ApiParam;
|
||||
import org.apache.commons.lang3.ArrayUtils;
|
||||
import org.dromara.easyes.core.biz.EsPageInfo;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
@@ -36,6 +38,8 @@ public class AppJobController extends BaseController
|
||||
private IJobCollectionService jobCollectionService;
|
||||
@Autowired
|
||||
private IESJobSearchService esJobSearchService;
|
||||
@Autowired
|
||||
private SensitiveWordChecker sensitiveWordChecker;
|
||||
|
||||
/**
|
||||
* 查询岗位列表
|
||||
@@ -192,7 +196,25 @@ public class AppJobController extends BaseController
|
||||
@PostMapping("/publishJob")
|
||||
public AjaxResult fix(@RequestBody Job job)
|
||||
{
|
||||
// 校验描述中的敏感词
|
||||
List<String> sensitiveWords = sensitiveWordChecker.checkSensitiveWords(job.getDescription());
|
||||
if (!sensitiveWords.isEmpty()) {
|
||||
String errorMsg = "描述中包含敏感词:" + String.join("、", sensitiveWords);
|
||||
return AjaxResult.error(errorMsg);
|
||||
}
|
||||
jobService.publishJob(job);
|
||||
return success();
|
||||
}
|
||||
|
||||
@GetMapping("/jobCompare")
|
||||
@ApiOperation("根据多个岗位id查询岗位详情")
|
||||
public AjaxResult jobCompare(@ApiParam("岗位ID数组") @RequestParam("jobIds") Long[] jobIds) {
|
||||
if (ArrayUtils.isEmpty(jobIds)) {
|
||||
return AjaxResult.error("请传递岗位ID参数(jobIds),多个ID用&分隔");
|
||||
}
|
||||
if (jobIds.length > 5) {
|
||||
return AjaxResult.error("最多支持对比5个岗位,请减少参数数量");
|
||||
}
|
||||
return success(esJobSearchService.selectByIds(jobIds));
|
||||
}
|
||||
}
|
||||
|
@@ -0,0 +1,81 @@
|
||||
package com.ruoyi.cms.controller.app;
|
||||
|
||||
|
||||
import com.ruoyi.cms.service.AppSkillService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.domain.entity.AppSkill;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.annotations.ApiParam;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* 用户技能信息
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-10-21 12:22:09
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/appskill/list")
|
||||
@Api(tags = "移动端:用户技能")
|
||||
public class AppSkillController extends BaseController {
|
||||
@Autowired
|
||||
private AppSkillService appSkillService;
|
||||
|
||||
/**
|
||||
* 列表
|
||||
*/
|
||||
@ApiOperation("获取工作经历详细信息")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(AppSkill appSkill){
|
||||
startPage();
|
||||
List<AppSkill> list=appSkillService.getList(appSkill);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 信息
|
||||
*/
|
||||
@ApiOperation("获取工作经历详细信息")
|
||||
@GetMapping(value = "/{id}")
|
||||
public AjaxResult info(@PathVariable("id") Long id){
|
||||
return success(appSkillService.getAppskillById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存
|
||||
*/
|
||||
@ApiOperation("获取工作经历详细信息")
|
||||
@PostMapping("/add")
|
||||
public AjaxResult save(@RequestBody AppSkill appSkill){
|
||||
return toAjax(appSkillService.insertAppskill(appSkill));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改
|
||||
*/
|
||||
@ApiOperation("获取工作经历详细信息")
|
||||
@PutMapping("/edit")
|
||||
public AjaxResult update(@RequestBody AppSkill appSkill){
|
||||
return toAjax(appSkillService.updateAppskillById(appSkill));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除
|
||||
*/
|
||||
@ApiOperation("获取工作经历详细信息")
|
||||
@DeleteMapping("/{id}")
|
||||
public AjaxResult delete(@ApiParam("主键id") @PathVariable Long id){
|
||||
return toAjax(appSkillService.removeAppskillIds(new Long[]{id}));
|
||||
}
|
||||
|
||||
}
|
@@ -1,7 +1,7 @@
|
||||
package com.ruoyi.cms.controller.app;
|
||||
|
||||
import com.ruoyi.cms.domain.AppUser;
|
||||
import com.ruoyi.cms.domain.Company;
|
||||
import com.ruoyi.common.core.domain.entity.AppUser;
|
||||
import com.ruoyi.common.core.domain.entity.Company;
|
||||
import com.ruoyi.cms.domain.Job;
|
||||
import com.ruoyi.cms.domain.JobFair;
|
||||
import com.ruoyi.cms.domain.query.MineJobQuery;
|
||||
@@ -9,8 +9,9 @@ import com.ruoyi.cms.service.*;
|
||||
import com.ruoyi.common.annotation.BussinessLog;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.domain.model.RegisterBody;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.SiteSecurityUtils;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@@ -45,20 +46,30 @@ public class AppUserController extends BaseController
|
||||
/**
|
||||
* 查询岗位列表
|
||||
*/
|
||||
@ApiOperation("保存注册信息")
|
||||
@PostMapping("/registerUser")
|
||||
@BussinessLog(title = "保存简历")
|
||||
public AjaxResult saveResume(@RequestBody RegisterBody registerBody)
|
||||
{
|
||||
appUserService.registerAppUser(registerBody);
|
||||
return AjaxResult.success();
|
||||
}
|
||||
|
||||
@ApiOperation("保存简历")
|
||||
@PostMapping("/resume")
|
||||
@BussinessLog(title = "保存简历")
|
||||
public AjaxResult saveResume(@RequestBody AppUser appUser)
|
||||
{
|
||||
appUser.setUserId(SecurityUtils.getUserId());
|
||||
appUser.setUserId(SiteSecurityUtils.getUserId());
|
||||
appUserService.updateAppUser(appUser);
|
||||
return AjaxResult.success();
|
||||
}
|
||||
|
||||
@ApiOperation("查看简历")
|
||||
@GetMapping("/resume")
|
||||
public AjaxResult getResume()
|
||||
{
|
||||
AppUser appUser = appUserService.selectAppUserByUserId(SecurityUtils.getUserId());
|
||||
AppUser appUser = appUserService.selectAppUserByUserId(SiteSecurityUtils.getUserId());
|
||||
return AjaxResult.success(appUser);
|
||||
}
|
||||
@ApiOperation("我的浏览")
|
||||
@@ -116,4 +127,12 @@ public class AppUserController extends BaseController
|
||||
HashMap<String,Integer> result = jobApplyService.statistics();
|
||||
return AjaxResult.success(result);
|
||||
}
|
||||
|
||||
@ApiOperation("根据条件查询用户信息")
|
||||
@GetMapping("/list")
|
||||
public AjaxResult getUserList(AppUser appUser)
|
||||
{
|
||||
List<AppUser> list = appUserService.selectAppUserList(appUser);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
}
|
||||
|
@@ -0,0 +1,88 @@
|
||||
package com.ruoyi.cms.controller.app;
|
||||
|
||||
import com.ruoyi.common.core.domain.entity.UserWorkExperiences;
|
||||
import com.ruoyi.cms.service.UserWorkExperiencesService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.common.utils.SiteSecurityUtils;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.annotations.ApiParam;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* 用户工作经历表
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-10-10 16:26:26
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/app/userworkexperiences")
|
||||
@Api(tags = "移动端:用户工作经历")
|
||||
public class AppUserWorkExperiencesController extends BaseController {
|
||||
|
||||
@Autowired
|
||||
private UserWorkExperiencesService userWorkExperiencesService;
|
||||
|
||||
/**
|
||||
* 列表
|
||||
*/
|
||||
@ApiOperation("工作经历列表信息")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(UserWorkExperiences userWorkExperiences){
|
||||
if(userWorkExperiences.getUserId()==null){
|
||||
userWorkExperiences.setUserId(SiteSecurityUtils.getUserId());
|
||||
}
|
||||
startPage();
|
||||
List<UserWorkExperiences> list=userWorkExperiencesService.getWorkExperiencesList(userWorkExperiences);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 获取详细信息
|
||||
*/
|
||||
@ApiOperation("获取工作经历详细信息")
|
||||
@GetMapping(value = "/{id}")
|
||||
public AjaxResult query(@PathVariable("id") Long id){
|
||||
return success(userWorkExperiencesService.getWorkExperiencesById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存
|
||||
*/
|
||||
@ApiOperation("新增工作经历")
|
||||
@PostMapping("/add")
|
||||
public AjaxResult add(@RequestBody UserWorkExperiences userWorkExperiences){
|
||||
if(userWorkExperiences.getUserId()==null){
|
||||
userWorkExperiences.setUserId(SiteSecurityUtils.getUserId());
|
||||
}
|
||||
return toAjax(userWorkExperiencesService.insertWorkExperiences(userWorkExperiences));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改
|
||||
*/
|
||||
@ApiOperation("修改工作经历")
|
||||
@PutMapping("/edit")
|
||||
public AjaxResult update(@RequestBody UserWorkExperiences userWorkExperiences){
|
||||
return toAjax(userWorkExperiencesService.updateWorkExperiencesById(userWorkExperiences));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除
|
||||
*/
|
||||
@ApiOperation("删除工作经历")
|
||||
@DeleteMapping("/{id}")
|
||||
public AjaxResult remove(@ApiParam("招聘会id") @PathVariable Long id){
|
||||
|
||||
return toAjax(userWorkExperiencesService.deleteWorkExperiencesIds(new Long[]{id}));
|
||||
}
|
||||
|
||||
}
|
@@ -18,7 +18,7 @@ import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import com.ruoyi.cms.domain.AppUser;
|
||||
import com.ruoyi.common.core.domain.entity.AppUser;
|
||||
import com.ruoyi.cms.service.IAppUserService;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
@@ -41,7 +41,7 @@ public class CmsAppUserController extends BaseController
|
||||
* 查询APP用户列表
|
||||
*/
|
||||
@ApiOperation("查询APP用户列表")
|
||||
@PreAuthorize("@ss.hasPermi('bussiness:user:list')")
|
||||
@PreAuthorize("@ss.hasPermi('cms:appUser:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(AppUser appUser)
|
||||
{
|
||||
@@ -54,7 +54,7 @@ public class CmsAppUserController extends BaseController
|
||||
* 导出APP用户列表
|
||||
*/
|
||||
@ApiOperation("导出APP用户列表")
|
||||
@PreAuthorize("@ss.hasPermi('bussiness:user:export')")
|
||||
@PreAuthorize("@ss.hasPermi('cms:appUser:export')")
|
||||
@Log(title = "APP用户", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, AppUser appUser)
|
||||
|
@@ -3,6 +3,7 @@ package com.ruoyi.cms.controller.cms;
|
||||
import com.ruoyi.cms.domain.Job;
|
||||
import com.ruoyi.cms.domain.vo.CandidateVO;
|
||||
import com.ruoyi.cms.service.IJobService;
|
||||
import com.ruoyi.cms.util.sensitiveWord.SensitiveWordChecker;
|
||||
import com.ruoyi.common.annotation.Anonymous;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
@@ -33,11 +34,13 @@ public class CmsJobController extends BaseController
|
||||
{
|
||||
@Autowired
|
||||
private IJobService jobService;
|
||||
@Autowired
|
||||
SensitiveWordChecker sensitiveWordChecker;
|
||||
/**
|
||||
* 查询岗位列表
|
||||
*/
|
||||
@ApiOperation("查询岗位列表")
|
||||
@PreAuthorize("@ss.hasPermi('bussiness:job:list')")
|
||||
@PreAuthorize("@ss.hasPermi('cms:job:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(Job job)
|
||||
{
|
||||
@@ -79,6 +82,13 @@ public class CmsJobController extends BaseController
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody Job job)
|
||||
{
|
||||
// 校验描述中的敏感词
|
||||
List<String> sensitiveWords = sensitiveWordChecker.checkSensitiveWords(job.getDescription());
|
||||
if (!sensitiveWords.isEmpty()) {
|
||||
String errorMsg = "描述中包含敏感词:" + String.join("、", sensitiveWords);
|
||||
return AjaxResult.error(errorMsg);
|
||||
}
|
||||
// 无敏感词,执行插入
|
||||
return toAjax(jobService.insertJob(job));
|
||||
}
|
||||
|
||||
@@ -91,6 +101,12 @@ public class CmsJobController extends BaseController
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody Job job)
|
||||
{
|
||||
// 校验描述中的敏感词
|
||||
List<String> sensitiveWords = sensitiveWordChecker.checkSensitiveWords(job.getDescription());
|
||||
if (!sensitiveWords.isEmpty()) {
|
||||
String errorMsg = "描述中包含敏感词:" + String.join("、", sensitiveWords);
|
||||
return AjaxResult.error(errorMsg);
|
||||
}
|
||||
return toAjax(jobService.updateJob(job));
|
||||
}
|
||||
|
||||
|
@@ -0,0 +1,42 @@
|
||||
package com.ruoyi.cms.controller.cms;
|
||||
|
||||
|
||||
import com.ruoyi.common.core.domain.entity.CompanyContact;
|
||||
import com.ruoyi.cms.service.CompanyContactService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* 公司联系人
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-09-30 15:57:06
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/cms/companycontact")
|
||||
@Api(tags = "后台:公司联系人")
|
||||
public class CompanyContactController extends BaseController {
|
||||
@Autowired
|
||||
private CompanyContactService companyContactService;
|
||||
|
||||
/**
|
||||
* 列表
|
||||
*/
|
||||
@ApiOperation("公司联系人列表")
|
||||
@PreAuthorize("@ss.hasPermi('cms:companycontact:list')")
|
||||
@RequestMapping("/list")
|
||||
public TableDataInfo list(CompanyContact companyContact){
|
||||
List<CompanyContact> list=companyContactService.getSelectList(companyContact);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
}
|
@@ -1,8 +1,7 @@
|
||||
package com.ruoyi.cms.controller.cms;
|
||||
|
||||
|
||||
import com.ruoyi.cms.domain.Company;
|
||||
import com.ruoyi.cms.service.ICompanyCollectionService;
|
||||
import com.ruoyi.common.core.domain.entity.Company;
|
||||
import com.ruoyi.cms.service.ICompanyService;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
@@ -12,7 +11,6 @@ import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.annotations.ApiParam;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
@@ -38,7 +36,7 @@ public class CompanyController extends BaseController
|
||||
* 查询公司列表
|
||||
*/
|
||||
@ApiOperation("查询公司列表")
|
||||
@PreAuthorize("@ss.hasPermi('app:company:list')")
|
||||
@PreAuthorize("@ss.hasPermi('cms:company:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(Company company)
|
||||
{
|
||||
@@ -107,4 +105,23 @@ public class CompanyController extends BaseController
|
||||
{
|
||||
return toAjax(companyService.deleteCompanyByCompanyIds(companyIds));
|
||||
}
|
||||
|
||||
@ApiOperation("企业资质审核列表")
|
||||
@PreAuthorize("@ss.hasPermi('app:company:approval:list')")
|
||||
@GetMapping("/approval/list")
|
||||
public TableDataInfo approvalList(Company company)
|
||||
{
|
||||
startPage();
|
||||
List<Company> list = companyService.approvalList(company);
|
||||
return getDataTable(list);
|
||||
}
|
||||
@ApiOperation("企业资质修改")
|
||||
@PreAuthorize("@ss.hasPermi('app:company:approval:edit')")
|
||||
@GetMapping("/approval/edit")
|
||||
public AjaxResult approvalEdit(Company company)
|
||||
{
|
||||
startPage();
|
||||
List<Company> list = companyService.approvalList(company);
|
||||
return AjaxResult.success();
|
||||
}
|
||||
}
|
||||
|
@@ -0,0 +1,71 @@
|
||||
package com.ruoyi.cms.controller.cms;
|
||||
|
||||
import com.ruoyi.cms.domain.EmployeeConfirm;
|
||||
import com.ruoyi.cms.service.EmployeeConfirmService;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* 新入职员工确认信息
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-10-10 10:42:16
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/cms/employeeConfirm")
|
||||
@Api(tags = "后台:新入职员工确认信息")
|
||||
public class EmployeeConfirmController extends BaseController {
|
||||
@Autowired
|
||||
private EmployeeConfirmService employeeConfirmService;
|
||||
|
||||
/**
|
||||
* 列表
|
||||
*/
|
||||
@ApiOperation("新入职员工确认信息列表")
|
||||
@PreAuthorize("@ss.hasPermi('cms:employeeConfirm:list')")
|
||||
@RequestMapping("/list")
|
||||
public TableDataInfo list(EmployeeConfirm employeeConfirm){
|
||||
List<EmployeeConfirm> list=employeeConfirmService.getEmployeeConfirmList(employeeConfirm);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存
|
||||
*/
|
||||
@ApiOperation("新增新入职员工确认信息")
|
||||
@PreAuthorize("@ss.hasPermi('cms:employeeConfirm:add')")
|
||||
@Log(title = "职员工确认信息", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody EmployeeConfirm employeeConfirm){
|
||||
return toAjax(employeeConfirmService.insertEmployeeConfirm(employeeConfirm));
|
||||
}
|
||||
|
||||
@ApiOperation("修改新入职员工确认信息")
|
||||
@PreAuthorize("@ss.hasPermi('cms:employeeConfirm:edit')")
|
||||
@Log(title = "职员工确认信息", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody EmployeeConfirm employeeConfirm){
|
||||
return toAjax(employeeConfirmService.updateEmployeeConfirm(employeeConfirm));
|
||||
}
|
||||
|
||||
@ApiOperation("删除新入职员工确认信息")
|
||||
@PreAuthorize("@ss.hasPermi('app:employeeConfirm:remove')")
|
||||
@Log(title = "公司", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{employeeConfirmIds}")
|
||||
public AjaxResult remove(@PathVariable Long[] employeeConfirmIds)
|
||||
{
|
||||
return toAjax(employeeConfirmService.deleteEmployeeConfirmIds(employeeConfirmIds));
|
||||
}
|
||||
}
|
@@ -0,0 +1,50 @@
|
||||
package com.ruoyi.cms.controller.cms;
|
||||
|
||||
import com.ruoyi.cms.domain.Job;
|
||||
import com.ruoyi.cms.domain.JobApply;
|
||||
import com.ruoyi.cms.domain.vo.CandidateVO;
|
||||
import com.ruoyi.cms.service.IJobApplyService;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
|
||||
@RestController
|
||||
@RequestMapping("/cms/jobApply")
|
||||
@Api(tags = "后台:岗位申请")
|
||||
public class JobApplyController extends BaseController {
|
||||
|
||||
@Autowired
|
||||
IJobApplyService iJobApplyService;
|
||||
|
||||
@GetMapping("/trendChart")
|
||||
public AjaxResult trendChart(JobApply jobApply)
|
||||
{
|
||||
HashMap<String,Integer> result = iJobApplyService.trendChart(jobApply);
|
||||
return success(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出APP用户列表
|
||||
*/
|
||||
@ApiOperation("导出岗位申请APP用户")
|
||||
@PreAuthorize("@ss.hasPermi('cms:jobApply:export')")
|
||||
@Log(title = "APP用户", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, Job job)
|
||||
{
|
||||
List<CandidateVO> list = iJobApplyService.selectAppUserList(job);
|
||||
ExcelUtil<CandidateVO> util = new ExcelUtil<CandidateVO>(CandidateVO.class);
|
||||
util.exportExcel(response, list, "APP用户数据");
|
||||
}
|
||||
}
|
@@ -0,0 +1,43 @@
|
||||
package com.ruoyi.cms.controller.cms;
|
||||
|
||||
import com.ruoyi.cms.domain.JobContact;
|
||||
import com.ruoyi.cms.service.JobContactService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* 岗位联系人
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-09-30 15:57:06
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/cms/jobcontact")
|
||||
@Api(tags = "后台:岗位联系人")
|
||||
public class JobContactController extends BaseController {
|
||||
@Autowired
|
||||
private JobContactService jobContactService;
|
||||
|
||||
/**
|
||||
* 列表
|
||||
*/
|
||||
@ApiOperation("岗位联系人列表")
|
||||
@PreAuthorize("@ss.hasPermi('cms:jobcontact:list')")
|
||||
@RequestMapping("/list")
|
||||
public TableDataInfo list(JobContact jobContact){
|
||||
startPage();
|
||||
List<JobContact> list = jobContactService.getSelectList(jobContact);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
}
|
@@ -0,0 +1,114 @@
|
||||
package com.ruoyi.cms.controller.cms;
|
||||
|
||||
import com.ruoyi.cms.domain.SensitiveWordData;
|
||||
import com.ruoyi.cms.service.SensitiveWordDataService;
|
||||
import com.ruoyi.cms.util.EasyExcelUtils;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import java.io.InputStream;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* 敏感词库
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-10-10 10:42:16
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/cms/sensitiveworddata")
|
||||
@Api(tags = "后台:敏感词库")
|
||||
public class SensitiveWordDataController extends BaseController {
|
||||
@Autowired
|
||||
private SensitiveWordDataService sensitiveWordDataService;
|
||||
|
||||
/**
|
||||
* 列表
|
||||
*/
|
||||
@ApiOperation("敏感词库详细信息")
|
||||
@PreAuthorize("@ss.hasPermi('cms:sensitiveworddata:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(SensitiveWordData sensitiveWordData){
|
||||
startPage();
|
||||
List<SensitiveWordData> list = sensitiveWordDataService.selectSensitiveworddataList(sensitiveWordData);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取详细信息
|
||||
*/
|
||||
@ApiOperation("获取敏感词库详细信息")
|
||||
@PreAuthorize("@ss.hasPermi('cms:sensitiveworddata:query')")
|
||||
@GetMapping(value = "/{id}")
|
||||
public AjaxResult list(@PathVariable("id") Long id){
|
||||
return success(sensitiveWordDataService.selectById(id));
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 保存
|
||||
*/
|
||||
@ApiOperation("新增敏感词")
|
||||
@PreAuthorize("@ss.hasPermi('cms:sensitiveworddata:add')")
|
||||
@Log(title = "敏感词", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult save(@RequestBody SensitiveWordData sensitiveWordData){
|
||||
|
||||
return toAjax(sensitiveWordDataService.insertSensitiveworddata(sensitiveWordData));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改
|
||||
*/
|
||||
@ApiOperation("修改敏感词")
|
||||
@PreAuthorize("@ss.hasPermi('cms:sensitiveworddata:edit')")
|
||||
@Log(title = "敏感词", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody SensitiveWordData sensitiveWordData){
|
||||
return toAjax(sensitiveWordDataService.updateSensitiveworddata(sensitiveWordData));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除敏感词
|
||||
*/
|
||||
@ApiOperation("删除敏感词")
|
||||
@PreAuthorize("@ss.hasPermi('cms:sensitiveworddata:remove')")
|
||||
@Log(title = "敏感词", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public AjaxResult remove(@PathVariable Long[] ids)
|
||||
{
|
||||
return toAjax(sensitiveWordDataService.deleteSensitiveworddataIds(ids));
|
||||
}
|
||||
|
||||
/**
|
||||
* 通用上传请求(单个)
|
||||
*/
|
||||
@PostMapping("/exoprt")
|
||||
public AjaxResult uploadFile(@RequestParam("file") MultipartFile file) throws Exception
|
||||
{
|
||||
try
|
||||
{
|
||||
InputStream inputStream = file.getInputStream();
|
||||
EasyExcelUtils.readExcelByBatch(inputStream, SensitiveWordData.class, 100, list -> {
|
||||
// 处理逻辑:如批量保存到数据库
|
||||
sensitiveWordDataService.batchInsert(list);
|
||||
});
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
return AjaxResult.error(e.getMessage());
|
||||
}
|
||||
return AjaxResult.success();
|
||||
}
|
||||
}
|
@@ -85,4 +85,19 @@ public class StaticsController extends BaseController {
|
||||
Map<String,Object> result = service.education(staticsquery);
|
||||
return success(result);
|
||||
}
|
||||
|
||||
//分学历-分薪资
|
||||
@GetMapping("/educationSalaryGen")
|
||||
public AjaxResult educationSalaryGen()
|
||||
{
|
||||
service.educationSalaryGen();
|
||||
return success();
|
||||
}
|
||||
|
||||
@GetMapping("/educationSalary")
|
||||
public AjaxResult educationSalary(Staticsquery staticsquery)
|
||||
{
|
||||
Map<String,Object> result = service.educationSalary(staticsquery);
|
||||
return success(result);
|
||||
}
|
||||
}
|
||||
|
@@ -0,0 +1,93 @@
|
||||
package com.ruoyi.cms.controller.cms;
|
||||
|
||||
import com.ruoyi.common.core.domain.entity.UserWorkExperiences;
|
||||
import com.ruoyi.cms.service.UserWorkExperiencesService;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* 用户工作经历表
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-10-10 16:26:26
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/cms/userworkexperiences")
|
||||
@Api(tags = "后台:用户工作经历")
|
||||
public class UserWorkExperiencesController extends BaseController {
|
||||
|
||||
@Autowired
|
||||
private UserWorkExperiencesService userWorkExperiencesService;
|
||||
|
||||
/**
|
||||
* 列表
|
||||
*/
|
||||
@ApiOperation("工作经历列表信息")
|
||||
@PreAuthorize("@ss.hasPermi('cms:userworkexperiences:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(UserWorkExperiences userWorkExperiences){
|
||||
startPage();
|
||||
List<UserWorkExperiences> list=userWorkExperiencesService.getWorkExperiencesList(userWorkExperiences);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 信息
|
||||
*/
|
||||
/**
|
||||
* 获取详细信息
|
||||
*/
|
||||
@ApiOperation("获取工作经历详细信息")
|
||||
@PreAuthorize("@ss.hasPermi('cms:userworkexperiences:query')")
|
||||
@GetMapping(value = "/{id}")
|
||||
public AjaxResult query(@PathVariable("id") Long id){
|
||||
return success(userWorkExperiencesService.getWorkExperiencesById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存
|
||||
*/
|
||||
@ApiOperation("新增工作经历")
|
||||
@PreAuthorize("@ss.hasPermi('cms:userworkexperiences:add')")
|
||||
@Log(title = "工作经历", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody UserWorkExperiences userWorkExperiences){
|
||||
return toAjax(userWorkExperiencesService.insertWorkExperiences(userWorkExperiences));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改
|
||||
*/
|
||||
@ApiOperation("修改工作经历")
|
||||
@PreAuthorize("@ss.hasPermi('cms:userworkexperiences:edit')")
|
||||
@Log(title = "工作经历", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult update(@RequestBody UserWorkExperiences userWorkExperiences){
|
||||
return toAjax(userWorkExperiencesService.updateWorkExperiencesById(userWorkExperiences));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除
|
||||
*/
|
||||
@ApiOperation("删除工作经历")
|
||||
@PreAuthorize("@ss.hasPermi('cms:sensitiveworddata:remove')")
|
||||
@Log(title = "工作经历", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public AjaxResult remove(Long[] ids){
|
||||
return toAjax(userWorkExperiencesService.deleteWorkExperiencesIds(ids));
|
||||
}
|
||||
|
||||
}
|
@@ -2,6 +2,7 @@ package com.ruoyi.cms.domain;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.fasterxml.jackson.annotation.JsonIgnore;
|
||||
import com.ruoyi.common.core.domain.entity.Company;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.dromara.easyes.annotation.IndexField;
|
||||
@@ -139,4 +140,10 @@ public class ESJobDocument
|
||||
|
||||
@ApiModelProperty("视频封面URL")
|
||||
private String cover;
|
||||
|
||||
@ApiModelProperty("岗位类型 0疆内 1疆外")
|
||||
private String jobType;
|
||||
|
||||
@ApiModelProperty("类型 0常规岗位 1就业见习岗位 2实习实训岗位 3社区实践岗位 对应字段字典position_type")
|
||||
private String type;
|
||||
}
|
||||
|
@@ -0,0 +1,71 @@
|
||||
package com.ruoyi.cms.domain;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
|
||||
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 新入职员工确认信息
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-10-10 10:42:16
|
||||
*/
|
||||
@Data
|
||||
@TableName("employee_confirm")
|
||||
public class EmployeeConfirm extends BaseEntity {
|
||||
@TableField(exist = false)
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@TableId(value = "id",type = IdType.AUTO)
|
||||
@ApiModelProperty("id")
|
||||
private Long id;
|
||||
/**
|
||||
* 企业id
|
||||
*/
|
||||
@ApiModelProperty("企业id")
|
||||
private Long companyId;
|
||||
/**
|
||||
* 姓名
|
||||
*/
|
||||
@ApiModelProperty("姓名")
|
||||
private String contactPerson;
|
||||
/**
|
||||
* 身份证
|
||||
*/
|
||||
@ApiModelProperty("身份证")
|
||||
private String idCard;
|
||||
/**
|
||||
* 入职日期
|
||||
*/
|
||||
@ApiModelProperty("入职日期")
|
||||
private String entryDate;
|
||||
/**
|
||||
* 联系电话
|
||||
*/
|
||||
@ApiModelProperty("联系电话")
|
||||
private String contactPersonPhone;
|
||||
/**
|
||||
* 劳动合同期限
|
||||
*/
|
||||
@ApiModelProperty("劳动合同期限")
|
||||
private String contractTerm;
|
||||
|
||||
@ApiModelProperty("工作id")
|
||||
private Long jobId;
|
||||
|
||||
/**
|
||||
* 申请id
|
||||
*/
|
||||
@TableField(exist = false)
|
||||
private Long applyId;
|
||||
}
|
@@ -8,11 +8,14 @@ import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.fasterxml.jackson.annotation.JsonIgnore;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import com.ruoyi.common.core.domain.entity.Company;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 岗位对象 job
|
||||
* @author lishundong
|
||||
@@ -106,7 +109,7 @@ public class Job extends BaseEntity
|
||||
@ApiModelProperty("是否收藏 0为否 1为是")
|
||||
private Integer isCollection;
|
||||
|
||||
@ApiModelProperty("工作地点")
|
||||
@ApiModelProperty("岗位描述")
|
||||
private String description;
|
||||
|
||||
@ApiModelProperty("是否发布 0未发布 1发布")
|
||||
@@ -148,4 +151,26 @@ public class Job extends BaseEntity
|
||||
|
||||
@ApiModelProperty("视频封面URL")
|
||||
private String cover;
|
||||
|
||||
@TableField(exist = false)
|
||||
@ApiModelProperty("薪酬")
|
||||
private String compensation;
|
||||
|
||||
@TableField(exist = false)
|
||||
@ApiModelProperty("信用代码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty("岗位类型 0疆内 1疆外")
|
||||
private String jobType;
|
||||
|
||||
@ApiModelProperty("类型 0常规岗位 1就业见习岗位 2实习实训岗位 3社区实践岗位 对应字段字典position_type")
|
||||
private String type;
|
||||
|
||||
@TableField(exist = false)
|
||||
@ApiModelProperty("岗位联系人列表")
|
||||
private List<JobContact> jobContactList;
|
||||
|
||||
@TableField(exist = false)
|
||||
@ApiModelProperty("附件列表")
|
||||
private List<File> filesList;
|
||||
}
|
||||
|
@@ -38,4 +38,6 @@ public class JobApply extends BaseEntity
|
||||
@ApiModelProperty("匹配度")
|
||||
private Long matchingDegree;
|
||||
|
||||
@ApiModelProperty("是否录用 0录用 2或null未录用")
|
||||
private String hire;
|
||||
}
|
||||
|
@@ -0,0 +1,53 @@
|
||||
package com.ruoyi.cms.domain;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 岗位联系人
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-09-30 15:57:06
|
||||
*/
|
||||
@Data
|
||||
@ApiModel("岗位联系人")
|
||||
@TableName("job_contact")
|
||||
public class JobContact extends BaseEntity {
|
||||
@TableField(exist = false)
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* id
|
||||
*/
|
||||
@TableId(value = "id",type = IdType.AUTO)
|
||||
@ApiModelProperty("id")
|
||||
private Long id;
|
||||
/**
|
||||
* 岗位id
|
||||
*/
|
||||
@ApiModelProperty("岗位id")
|
||||
private Long jobId;
|
||||
/**
|
||||
* 联系人
|
||||
*/
|
||||
@ApiModelProperty("联系人")
|
||||
private String contactPerson;
|
||||
/**
|
||||
* 联系人电话
|
||||
*/
|
||||
@ApiModelProperty("联系人电话")
|
||||
private String contactPersonPhone;
|
||||
/**
|
||||
* 职务
|
||||
*/
|
||||
@ApiModelProperty("职务")
|
||||
private String position;
|
||||
}
|
@@ -5,6 +5,7 @@ import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.ruoyi.common.core.domain.entity.Company;
|
||||
import lombok.Data;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
|
@@ -0,0 +1,45 @@
|
||||
package com.ruoyi.cms.domain;
|
||||
|
||||
import com.alibaba.excel.annotation.ExcelProperty;
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 敏感词库
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-10-10 10:42:16
|
||||
*/
|
||||
@Data
|
||||
@TableName("sensitive_word_data")
|
||||
public class SensitiveWordData extends BaseEntity {
|
||||
@TableField(exist = false)
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@TableId(value = "id",type = IdType.AUTO)
|
||||
@ApiModelProperty("id")
|
||||
private Long id;
|
||||
/**
|
||||
* 敏感词
|
||||
*/
|
||||
@ExcelProperty(value = "敏感词", index = 0)
|
||||
@ApiModelProperty("敏感词")
|
||||
private String sensitiveWord;
|
||||
/**
|
||||
* 类型
|
||||
*/
|
||||
@ExcelProperty(value = "类型", index = 1)
|
||||
@ApiModelProperty("类型")
|
||||
private String type;
|
||||
|
||||
}
|
@@ -29,7 +29,7 @@ public class ESJobSearch extends Job
|
||||
|
||||
private String radius;
|
||||
|
||||
@ApiModelProperty("排序方式 0:推荐 1:最热 2:最新发布")
|
||||
@ApiModelProperty("排序方式 0:推荐 1:最热 2:最新发布 3:最大薪资")
|
||||
private Integer order;
|
||||
|
||||
//商圈id
|
||||
|
@@ -1,7 +1,8 @@
|
||||
package com.ruoyi.cms.domain.vo;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.ruoyi.cms.domain.AppUser;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.entity.AppUser;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.Date;
|
||||
@@ -11,4 +12,10 @@ public class CandidateVO extends AppUser {
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
private Date applyDate;
|
||||
private Integer matchingDegree;
|
||||
private String applyId;
|
||||
|
||||
@Excel(name = "公司名称", sort = 0)
|
||||
private String companyName;
|
||||
@Excel(name = "岗位名称", sort = 1)
|
||||
private String jobName;
|
||||
}
|
||||
|
@@ -0,0 +1,20 @@
|
||||
package com.ruoyi.cms.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.ruoyi.common.core.domain.entity.AppSkill;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 用户技能信息
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-10-21 12:22:09
|
||||
*/
|
||||
public interface AppSkillMapper extends BaseMapper<AppSkill> {
|
||||
|
||||
List<AppSkill> getList(AppSkill appSkill);
|
||||
|
||||
int batchInsert(List<AppSkill> list);
|
||||
}
|
@@ -2,7 +2,10 @@ package com.ruoyi.cms.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import java.util.List;
|
||||
import com.ruoyi.cms.domain.AppUser;
|
||||
import java.util.Map;
|
||||
|
||||
import com.ruoyi.common.core.domain.entity.AppUser;
|
||||
import com.ruoyi.common.core.domain.entity.SysUser;
|
||||
|
||||
/**
|
||||
* APP用户Mapper接口
|
||||
@@ -20,4 +23,10 @@ public interface AppUserMapper extends BaseMapper<AppUser>
|
||||
public List<AppUser> selectAppUserList(AppUser appUser);
|
||||
|
||||
List<AppUser> selectByJobId(Long jobId);
|
||||
|
||||
AppUser selectByOpenid(String openid);
|
||||
|
||||
int insertSysUserRole(Map<String,Object> map);
|
||||
|
||||
int insertSysUser(SysUser sysUser);
|
||||
}
|
||||
|
@@ -3,7 +3,7 @@ package com.ruoyi.cms.mapper;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import java.util.List;
|
||||
|
||||
import com.ruoyi.cms.domain.Company;
|
||||
import com.ruoyi.common.core.domain.entity.Company;
|
||||
import com.ruoyi.cms.domain.CompanyCollection;
|
||||
|
||||
/**
|
||||
|
@@ -0,0 +1,20 @@
|
||||
package com.ruoyi.cms.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.ruoyi.common.core.domain.entity.CompanyContact;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 公司联系人
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-09-30 15:57:06
|
||||
*/
|
||||
public interface CompanyContactMapper extends BaseMapper<CompanyContact> {
|
||||
|
||||
List<CompanyContact> getSelectList(CompanyContact companyContact);
|
||||
|
||||
int batchInsert(List<CompanyContact> list);
|
||||
}
|
@@ -2,7 +2,7 @@ package com.ruoyi.cms.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import java.util.List;
|
||||
import com.ruoyi.cms.domain.Company;
|
||||
import com.ruoyi.common.core.domain.entity.Company;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
/**
|
||||
|
@@ -0,0 +1,19 @@
|
||||
package com.ruoyi.cms.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.ruoyi.cms.domain.EmployeeConfirm;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* 新入职员工确认信息
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-10-10 10:42:16
|
||||
*/
|
||||
public interface EmployeeConfirmMapper extends BaseMapper<EmployeeConfirm> {
|
||||
|
||||
List<EmployeeConfirm> getEmployeeConfirmList(EmployeeConfirm employeeConfirm);
|
||||
}
|
@@ -1,6 +1,8 @@
|
||||
package com.ruoyi.cms.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
|
||||
import com.ruoyi.cms.domain.Job;
|
||||
@@ -26,4 +28,8 @@ public interface JobApplyMapper extends BaseMapper<JobApply>
|
||||
List<Job> applyJob(Long userId);
|
||||
|
||||
List<CandidateVO> candidates(Long jobId);
|
||||
|
||||
HashMap<String,Integer> trendChart(JobApply jobApply);
|
||||
|
||||
List<CandidateVO> selectAppUserList(Job job);
|
||||
}
|
||||
|
@@ -0,0 +1,20 @@
|
||||
package com.ruoyi.cms.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.ruoyi.cms.domain.JobContact;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 岗位联系人
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-09-30 15:57:06
|
||||
*/
|
||||
public interface JobContactMapper extends BaseMapper<JobContact> {
|
||||
|
||||
List<JobContact> getSelectList(JobContact jobContact);
|
||||
|
||||
int batchInsert(List<JobContact> list);
|
||||
}
|
@@ -4,13 +4,11 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import com.ruoyi.cms.domain.Company;
|
||||
import com.ruoyi.common.core.domain.entity.Company;
|
||||
import com.ruoyi.cms.domain.Job;
|
||||
import com.ruoyi.cms.domain.RowWork;
|
||||
import com.ruoyi.cms.domain.VectorJob;
|
||||
import com.ruoyi.cms.domain.query.ESJobSearch;
|
||||
import org.springframework.beans.factory.annotation.Value;
|
||||
import org.springframework.data.repository.query.Param;
|
||||
|
||||
/**
|
||||
* 岗位Mapper接口
|
||||
|
@@ -0,0 +1,21 @@
|
||||
package com.ruoyi.cms.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.ruoyi.cms.domain.SensitiveWordData;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* 敏感词库
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-10-10 10:42:16
|
||||
*/
|
||||
public interface SensitiveWordDataMapper extends BaseMapper<SensitiveWordData> {
|
||||
|
||||
List<SensitiveWordData> selectSensitiveworddataList(SensitiveWordData sensitiveWordData);
|
||||
|
||||
int batchInsert(List<SensitiveWordData> list);
|
||||
}
|
@@ -0,0 +1,20 @@
|
||||
package com.ruoyi.cms.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.ruoyi.common.core.domain.entity.UserWorkExperiences;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 用户工作经历表
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-10-10 16:26:26
|
||||
*/
|
||||
public interface UserWorkExperiencesMapper extends BaseMapper<UserWorkExperiences> {
|
||||
|
||||
List<UserWorkExperiences> getWorkExperiencesList(UserWorkExperiences userWorkExperiences);
|
||||
|
||||
int batchInsert(List<UserWorkExperiences> list);
|
||||
}
|
@@ -0,0 +1,26 @@
|
||||
package com.ruoyi.cms.service;
|
||||
|
||||
import com.ruoyi.common.core.domain.entity.AppSkill;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 用户技能信息
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-10-21 12:22:09
|
||||
*/
|
||||
public interface AppSkillService{
|
||||
|
||||
List<AppSkill> getList(AppSkill appSkill);
|
||||
|
||||
int insertAppskill(AppSkill appSkill);
|
||||
|
||||
int updateAppskillById(AppSkill appSkill);
|
||||
|
||||
int removeAppskillIds(Long[] ids);
|
||||
|
||||
AppSkill getAppskillById(Long id);
|
||||
}
|
||||
|
@@ -0,0 +1,18 @@
|
||||
package com.ruoyi.cms.service;
|
||||
|
||||
import com.ruoyi.common.core.domain.entity.CompanyContact;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 公司联系人
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-09-30 15:57:06
|
||||
*/
|
||||
public interface CompanyContactService {
|
||||
|
||||
List<CompanyContact> getSelectList(CompanyContact companyContact);
|
||||
}
|
||||
|
@@ -0,0 +1,24 @@
|
||||
package com.ruoyi.cms.service;
|
||||
|
||||
import com.ruoyi.cms.domain.EmployeeConfirm;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 新入职员工确认信息
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-10-10 10:42:16
|
||||
*/
|
||||
public interface EmployeeConfirmService {
|
||||
|
||||
List<EmployeeConfirm> getEmployeeConfirmList(EmployeeConfirm employeeConfirm);
|
||||
|
||||
int insertEmployeeConfirm(EmployeeConfirm employeeConfirm);
|
||||
|
||||
int updateEmployeeConfirm(EmployeeConfirm employeeConfirm);
|
||||
|
||||
int deleteEmployeeConfirmIds(Long[] ids);
|
||||
}
|
||||
|
@@ -1,7 +1,8 @@
|
||||
package com.ruoyi.cms.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.cms.domain.AppUser;
|
||||
import com.ruoyi.common.core.domain.entity.AppUser;
|
||||
import com.ruoyi.common.core.domain.model.RegisterBody;
|
||||
|
||||
/**
|
||||
* APP用户Service接口
|
||||
@@ -51,4 +52,9 @@ public interface IAppUserService
|
||||
*/
|
||||
public int deleteAppUserByUserIds(Long[] userIds);
|
||||
|
||||
public AppUser getPhone(String phone);
|
||||
|
||||
AppUser selectByOpenid(String openid);
|
||||
|
||||
public int registerAppUser(RegisterBody registerBody);
|
||||
}
|
||||
|
@@ -2,7 +2,7 @@ package com.ruoyi.cms.service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.ruoyi.cms.domain.Company;
|
||||
import com.ruoyi.common.core.domain.entity.Company;
|
||||
import com.ruoyi.cms.domain.CompanyCollection;
|
||||
import com.ruoyi.cms.domain.Job;
|
||||
|
||||
|
@@ -1,11 +1,9 @@
|
||||
package com.ruoyi.cms.service;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import com.ruoyi.cms.domain.Company;
|
||||
import com.ruoyi.common.core.domain.entity.Company;
|
||||
import com.ruoyi.cms.domain.CompanyCard;
|
||||
import com.ruoyi.cms.domain.query.LabelQuery;
|
||||
import com.ruoyi.common.core.page.PageDomain;
|
||||
|
||||
/**
|
||||
* 公司Service接口
|
||||
@@ -73,4 +71,10 @@ public interface ICompanyService
|
||||
void register(Company company);
|
||||
|
||||
Company registerStatus();
|
||||
|
||||
List<Company> approvalList(Company company);
|
||||
|
||||
Company approval(Company company);
|
||||
|
||||
Company queryCodeCompany(String code);
|
||||
}
|
||||
|
@@ -67,4 +67,6 @@ public interface IESJobSearchService
|
||||
void updateJob(Long jobId);
|
||||
|
||||
void deleteJob(Long jobId);
|
||||
|
||||
List<ESJobDocument> selectByIds(Long[] jobIds);
|
||||
}
|
||||
|
@@ -1,7 +1,6 @@
|
||||
package com.ruoyi.cms.service;
|
||||
|
||||
|
||||
import com.ruoyi.cms.domain.Company;
|
||||
import com.ruoyi.cms.domain.FairCollection;
|
||||
import com.ruoyi.cms.domain.JobFair;
|
||||
|
||||
|
@@ -5,6 +5,7 @@ import java.util.List;
|
||||
|
||||
import com.ruoyi.cms.domain.Job;
|
||||
import com.ruoyi.cms.domain.JobApply;
|
||||
import com.ruoyi.cms.domain.vo.CandidateVO;
|
||||
|
||||
/**
|
||||
* 岗位申请Service接口
|
||||
@@ -57,4 +58,8 @@ public interface IJobApplyService
|
||||
List<Job> applyJob();
|
||||
|
||||
HashMap<String, Integer> statistics();
|
||||
|
||||
HashMap<String,Integer> trendChart(JobApply jobApply);
|
||||
|
||||
List<CandidateVO> selectAppUserList(Job job);
|
||||
}
|
||||
|
@@ -0,0 +1,18 @@
|
||||
package com.ruoyi.cms.service;
|
||||
|
||||
import com.ruoyi.cms.domain.JobContact;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 岗位联系人
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-09-30 15:57:06
|
||||
*/
|
||||
public interface JobContactService{
|
||||
|
||||
List<JobContact> getSelectList(JobContact jobContact);
|
||||
}
|
||||
|
@@ -0,0 +1,28 @@
|
||||
package com.ruoyi.cms.service;
|
||||
|
||||
import com.ruoyi.cms.domain.SensitiveWordData;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 敏感词库
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-10-10 10:42:16
|
||||
*/
|
||||
public interface SensitiveWordDataService {
|
||||
|
||||
List<SensitiveWordData> selectSensitiveworddataList(SensitiveWordData sensitiveworddata);
|
||||
|
||||
SensitiveWordData selectById(Long id);
|
||||
|
||||
int insertSensitiveworddata(SensitiveWordData sensitiveWordData);
|
||||
|
||||
int updateSensitiveworddata(SensitiveWordData sensitiveWordData);
|
||||
|
||||
int deleteSensitiveworddataIds(Long[] ids);
|
||||
|
||||
int batchInsert(List<SensitiveWordData> list);
|
||||
}
|
||||
|
@@ -23,4 +23,8 @@ public interface StaticsqueryService {
|
||||
void educationGen();
|
||||
|
||||
Map<String, Object> education(Staticsquery staticsquery);
|
||||
|
||||
void educationSalaryGen();
|
||||
|
||||
Map<String, Object> educationSalary(Staticsquery staticsquery);
|
||||
}
|
||||
|
@@ -0,0 +1,26 @@
|
||||
package com.ruoyi.cms.service;
|
||||
|
||||
import com.ruoyi.common.core.domain.entity.UserWorkExperiences;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 用户工作经历表
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-10-10 16:26:26
|
||||
*/
|
||||
public interface UserWorkExperiencesService {
|
||||
|
||||
List<UserWorkExperiences> getWorkExperiencesList(UserWorkExperiences userWorkExperiences);
|
||||
|
||||
int insertWorkExperiences(UserWorkExperiences userWorkExperiences);
|
||||
|
||||
int updateWorkExperiencesById(UserWorkExperiences userWorkExperiences);
|
||||
|
||||
int deleteWorkExperiencesIds(Long[] ids);
|
||||
|
||||
UserWorkExperiences getWorkExperiencesById(Long id);
|
||||
}
|
||||
|
@@ -6,11 +6,11 @@ import com.ruoyi.cms.domain.*;
|
||||
import com.ruoyi.cms.mapper.*;
|
||||
import com.ruoyi.cms.service.IAppNoticeService;
|
||||
import com.ruoyi.cms.util.StringUtil;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.core.domain.entity.AppUser;
|
||||
import com.ruoyi.common.utils.SiteSecurityUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
@@ -154,14 +154,14 @@ public class AppNoticeServiceImpl implements IAppNoticeService
|
||||
@Override
|
||||
public List<Notice> listNotRead(Integer isRead) {
|
||||
|
||||
Long userId = SecurityUtils.getUserId();
|
||||
Long userId = SiteSecurityUtils.getUserId();
|
||||
List<Notice> sysNoticeList = noticeInfoMapper.selectList(Wrappers.<Notice>lambdaQuery().eq(Notice::getUserId, userId).eq(Notice::getRemark,"notice_bar").orderByDesc(Notice::getCreateTime));
|
||||
return sysNoticeList;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Job> recommend(String jobTitle) {
|
||||
return appNoticeMapper.recommend(jobTitle,SecurityUtils.getUserId());
|
||||
return appNoticeMapper.recommend(jobTitle,SiteSecurityUtils.getUserId());
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -172,7 +172,7 @@ public class AppNoticeServiceImpl implements IAppNoticeService
|
||||
notice.setIsRead(1);
|
||||
noticeInfoMapper.updateById(notice);
|
||||
});
|
||||
List<Notice> notices1 = noticeInfoMapper.selectList(Wrappers.<Notice>lambdaQuery().eq(Notice::getUserId, SecurityUtils.getUserId()).eq(Notice::getRemark, "notice_bar").eq(Notice::getTitle, "系统通知").orderByDesc(Notice::getCreateTime).last("limit 1"));
|
||||
List<Notice> notices1 = noticeInfoMapper.selectList(Wrappers.<Notice>lambdaQuery().eq(Notice::getUserId, SiteSecurityUtils.getUserId()).eq(Notice::getRemark, "notice_bar").eq(Notice::getTitle, "系统通知").orderByDesc(Notice::getCreateTime).last("limit 1"));
|
||||
Notice notice = notices1.get(0);
|
||||
notice.setNotReadCount(notice.getNotReadCount() - longs.size());
|
||||
if(notice.getNotReadCount()==0){
|
||||
@@ -194,7 +194,7 @@ public class AppNoticeServiceImpl implements IAppNoticeService
|
||||
|
||||
@Override
|
||||
public List<Notice> sysNoticeList() {
|
||||
Long userId = SecurityUtils.getUserId();
|
||||
Long userId = SiteSecurityUtils.getUserId();
|
||||
List<Notice> sysNoticeList = noticeInfoMapper.selectList(Wrappers.<Notice>lambdaQuery().eq(Notice::getUserId, userId).isNotNull(Notice::getNoticeType).notIn(Notice::getNoticeType,"").orderByDesc(Notice::getCreateTime));
|
||||
return sysNoticeList;
|
||||
}
|
||||
|
@@ -6,7 +6,7 @@ import com.ruoyi.cms.domain.Job;
|
||||
import com.ruoyi.cms.domain.query.MineJobQuery;
|
||||
import com.ruoyi.cms.mapper.AppReviewJobMapper;
|
||||
import com.ruoyi.cms.service.IAppReviewJobService;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.SiteSecurityUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
@@ -91,13 +91,13 @@ public class AppReviewJobServiceImpl extends ServiceImpl<AppReviewJobMapper, App
|
||||
|
||||
@Override
|
||||
public List<Job> review(MineJobQuery jobQuery) {
|
||||
List<Job> jobs = appReviewJobMapper.review(SecurityUtils.getUserId(),jobQuery);
|
||||
List<Job> jobs = appReviewJobMapper.review(SiteSecurityUtils.getUserId(),jobQuery);
|
||||
return jobs;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> reviewArray() {
|
||||
List<AppReviewJob> appReviewJobs = appReviewJobMapper.reviewArray(SecurityUtils.getUserId());
|
||||
List<AppReviewJob> appReviewJobs = appReviewJobMapper.reviewArray(SiteSecurityUtils.getUserId());
|
||||
return appReviewJobs.stream().map(x -> formatter.format(x.getReviewDate())).collect(Collectors.toList());
|
||||
}
|
||||
}
|
@@ -0,0 +1,43 @@
|
||||
package com.ruoyi.cms.service.impl;
|
||||
|
||||
import com.ruoyi.cms.mapper.AppSkillMapper;
|
||||
import com.ruoyi.cms.service.AppSkillService;
|
||||
import com.ruoyi.common.core.domain.entity.AppSkill;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
|
||||
|
||||
@Service
|
||||
public class AppSkillServiceImpl extends ServiceImpl<AppSkillMapper, AppSkill> implements AppSkillService {
|
||||
|
||||
@Autowired
|
||||
AppSkillMapper appSkillMapper;
|
||||
|
||||
public List<AppSkill> getList(AppSkill appSkill){
|
||||
return appSkillMapper.getList(appSkill);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int insertAppskill(AppSkill appSkill) {
|
||||
return appSkillMapper.insert(appSkill);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int updateAppskillById(AppSkill appSkill) {
|
||||
return appSkillMapper.updateById(appSkill);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int removeAppskillIds(Long[] ids) {
|
||||
return appSkillMapper.deleteBatchIds(Arrays.asList(ids));
|
||||
}
|
||||
|
||||
@Override
|
||||
public AppSkill getAppskillById(Long id) {
|
||||
return appSkillMapper.selectById(id);
|
||||
}
|
||||
}
|
@@ -1,19 +1,25 @@
|
||||
package com.ruoyi.cms.service.impl;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Arrays;
|
||||
import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import com.ruoyi.cms.domain.Job;
|
||||
import com.ruoyi.cms.mapper.JobMapper;
|
||||
import com.ruoyi.cms.mapper.JobTitleMapper;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.ruoyi.cms.mapper.*;
|
||||
import com.ruoyi.cms.util.StringUtil;
|
||||
import com.ruoyi.common.core.domain.entity.Company;
|
||||
import com.ruoyi.common.core.domain.entity.JobTitle;
|
||||
import com.ruoyi.common.core.domain.entity.SysUser;
|
||||
import com.ruoyi.common.core.domain.model.RegisterBody;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.SiteSecurityUtils;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.cms.mapper.AppUserMapper;
|
||||
import com.ruoyi.cms.domain.AppUser;
|
||||
import com.ruoyi.common.core.domain.entity.AppUser;
|
||||
import com.ruoyi.cms.service.IAppUserService;
|
||||
|
||||
/**
|
||||
@@ -29,6 +35,14 @@ public class AppUserServiceImpl extends ServiceImpl<AppUserMapper,AppUser> imple
|
||||
private AppUserMapper appUserMapper;
|
||||
@Autowired
|
||||
private JobTitleMapper jobTitleMapper;
|
||||
@Autowired
|
||||
private CompanyContactMapper companyContactMapper;
|
||||
@Autowired
|
||||
private UserWorkExperiencesMapper userWorkExperiencesMapper;
|
||||
@Autowired
|
||||
private AppSkillMapper appSkillMapper;
|
||||
@Autowired
|
||||
private CompanyMapper companyMapper;
|
||||
/**
|
||||
* 查询APP用户
|
||||
*
|
||||
@@ -57,7 +71,14 @@ public class AppUserServiceImpl extends ServiceImpl<AppUserMapper,AppUser> imple
|
||||
@Override
|
||||
public List<AppUser> selectAppUserList(AppUser appUser)
|
||||
{
|
||||
return appUserMapper.selectAppUserList(appUser);
|
||||
List<AppUser> list=appUserMapper.selectAppUserList(appUser);
|
||||
if(list!=null){
|
||||
//身份证脱敏处理
|
||||
list.forEach(x->{
|
||||
x.setIdCard(StringUtil.desensitizeIdCard(x.getIdCard()));
|
||||
});
|
||||
}
|
||||
return list;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -96,4 +117,82 @@ public class AppUserServiceImpl extends ServiceImpl<AppUserMapper,AppUser> imple
|
||||
return appUserMapper.deleteBatchIds(Arrays.asList(userIds));
|
||||
}
|
||||
|
||||
@Override
|
||||
public AppUser getPhone(String phone) {
|
||||
return appUserMapper.selectOne(new LambdaQueryWrapper<AppUser>()
|
||||
.eq(AppUser::getPhone, phone));
|
||||
}
|
||||
|
||||
@Override
|
||||
public AppUser selectByOpenid(String openid) {
|
||||
return appUserMapper.selectByOpenid(openid);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int registerAppUser(RegisterBody registerBody) {
|
||||
AppUser appUser=registerBody.getAppUser();
|
||||
System.out.println("userId================"+SiteSecurityUtils.getUserId());
|
||||
if(SiteSecurityUtils.isLogin()){
|
||||
AppUser appUserResult=appUserMapper.selectById(SiteSecurityUtils.getUserId());
|
||||
if(appUser==null){
|
||||
appUser=appUserResult;
|
||||
}else{
|
||||
appUser.setPhone(appUserResult.getPhone());
|
||||
appUser.setUserId(appUserResult.getUserId());
|
||||
}
|
||||
}
|
||||
//角色集合
|
||||
Map mapUserRole=new HashMap<>();
|
||||
switch (appUser.getIsCompanyUser()){
|
||||
case "0"://企业
|
||||
if(registerBody.getCompany()!=null){
|
||||
Company company=registerBody.getCompany();
|
||||
Long companyId=company.getCompanyId();
|
||||
if(companyId==null){
|
||||
companyMapper.insert(registerBody.getCompany());
|
||||
registerBody.getCompany().getCompanyContactList().forEach(it->{
|
||||
it.setCompanyId(registerBody.getCompany().getCompanyId());
|
||||
});
|
||||
}
|
||||
if(registerBody.getCompany().getCompanyContactList()!=null){
|
||||
companyContactMapper.batchInsert(registerBody.getCompany().getCompanyContactList());
|
||||
}
|
||||
//保存app_user信息
|
||||
appUser.setIdCard(company.getCode());
|
||||
appUser.setName(company.getName());
|
||||
}
|
||||
mapUserRole.put("roleId",100);
|
||||
break;
|
||||
default://求职者
|
||||
if(registerBody.getExperiencesList()!=null){
|
||||
registerBody.getExperiencesList().forEach(it->{
|
||||
it.setUserId(SiteSecurityUtils.getUserId());
|
||||
});
|
||||
userWorkExperiencesMapper.batchInsert(registerBody.getExperiencesList());
|
||||
}
|
||||
if(registerBody.getAppSkillsList()!=null){
|
||||
registerBody.getAppSkillsList().forEach(it->{
|
||||
it.setUserId(SiteSecurityUtils.getUserId());
|
||||
});
|
||||
appSkillMapper.batchInsert(registerBody.getAppSkillsList());
|
||||
}
|
||||
mapUserRole.put("roleId",1);
|
||||
}
|
||||
//保存sys_user
|
||||
SysUser sysUser=new SysUser();
|
||||
sysUser.setUserName(appUser.getPhone());
|
||||
sysUser.setNickName(StringUtils.isEmpty(appUser.getName())?appUser.getPhone():appUser.getName());
|
||||
sysUser.setPassword(SecurityUtils.encryptPassword("123456"));
|
||||
sysUser.setPhonenumber(appUser.getPhone());
|
||||
sysUser.setSex(appUser.getSex());
|
||||
sysUser.setStatus("0");
|
||||
sysUser.setLoginIp(appUser.getLoginIp());
|
||||
sysUser.setLoginDate(appUser.getLoginDate());
|
||||
sysUser.setIdCard(appUser.getIdCard());
|
||||
appUserMapper.insertSysUser(sysUser);
|
||||
//保存sys_user_role
|
||||
mapUserRole.put("userId",appUser.getUserId());
|
||||
appUserMapper.insertSysUserRole(mapUserRole);
|
||||
return appUserMapper.updateById(appUser);
|
||||
}
|
||||
}
|
||||
|
@@ -11,7 +11,7 @@ import com.ruoyi.cms.domain.CompanyCardCollection;
|
||||
import com.ruoyi.cms.domain.vo.CompanyCardVO;
|
||||
import com.ruoyi.cms.mapper.CompanyCardCollectionMapper;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.SiteSecurityUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import org.springframework.stereotype.Service;
|
||||
@@ -100,9 +100,9 @@ public class CompanyCardServiceImpl extends ServiceImpl<CompanyCardMapper,Compan
|
||||
CompanyCard companyCard = new CompanyCard();
|
||||
companyCard.setStatus(1);
|
||||
List<CompanyCardVO> companyCards = companyCardMapper.selectCompanyCardListVO(companyCard);
|
||||
if(SecurityUtils.isLogin()){
|
||||
if(SiteSecurityUtils.isLogin()){
|
||||
CompanyCardCollection companyCardCollection = new CompanyCardCollection();
|
||||
companyCardCollection.setUserId(SecurityUtils.getUserId());
|
||||
companyCardCollection.setUserId(SiteSecurityUtils.getUserId());
|
||||
List<CompanyCardCollection> companyCardCollections = companyCardCollectionMapper.selectCompanyCardCollectionList(companyCardCollection);
|
||||
for (CompanyCardVO item:companyCards){
|
||||
for(CompanyCardCollection collection:companyCardCollections){
|
||||
@@ -119,7 +119,7 @@ public class CompanyCardServiceImpl extends ServiceImpl<CompanyCardMapper,Compan
|
||||
public void cardCollection(Long companyCardId) {
|
||||
CompanyCardCollection companyCardCollection = new CompanyCardCollection();
|
||||
companyCardCollection.setCompanyCardId(companyCardId);
|
||||
companyCardCollection.setUserId(SecurityUtils.getUserId());
|
||||
companyCardCollection.setUserId(SiteSecurityUtils.getUserId());
|
||||
companyCardCollectionService.save(companyCardCollection);
|
||||
}
|
||||
|
||||
@@ -127,8 +127,8 @@ public class CompanyCardServiceImpl extends ServiceImpl<CompanyCardMapper,Compan
|
||||
public void cardCancel(Long companyCardId) {
|
||||
CompanyCardCollection companyCardCollection = new CompanyCardCollection();
|
||||
companyCardCollection.setCompanyCardId(companyCardId);
|
||||
companyCardCollection.setUserId(SecurityUtils.getUserId());
|
||||
List<CompanyCardCollection> companyCardCollections = companyCardCollectionMapper.selectList(Wrappers.<CompanyCardCollection>lambdaQuery().eq(CompanyCardCollection::getCompanyCardId, companyCardId).eq(CompanyCardCollection::getUserId, SecurityUtils.getUserId()));
|
||||
companyCardCollection.setUserId(SiteSecurityUtils.getUserId());
|
||||
List<CompanyCardCollection> companyCardCollections = companyCardCollectionMapper.selectList(Wrappers.<CompanyCardCollection>lambdaQuery().eq(CompanyCardCollection::getCompanyCardId, companyCardId).eq(CompanyCardCollection::getUserId, SiteSecurityUtils.getUserId()));
|
||||
companyCardCollectionMapper.deleteBatchIds(companyCardCollections.stream().map(CompanyCardCollection::getCompanyCardCollectionId).collect(Collectors.toList()));
|
||||
}
|
||||
}
|
@@ -5,10 +5,10 @@ import java.util.Arrays;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||
import com.ruoyi.cms.domain.Company;
|
||||
import com.ruoyi.common.core.domain.entity.Company;
|
||||
import com.ruoyi.cms.domain.Job;
|
||||
import com.ruoyi.cms.mapper.JobMapper;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.SiteSecurityUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import org.springframework.stereotype.Service;
|
||||
@@ -93,7 +93,7 @@ public class CompanyCollectionServiceImpl extends ServiceImpl<CompanyCollectionM
|
||||
*/
|
||||
@Override
|
||||
public int companyCancel(Long companyId) {
|
||||
List<CompanyCollection> companyCollections = companyCollectionMapper.selectList(Wrappers.<CompanyCollection>lambdaQuery().eq(CompanyCollection::getCompanyId, companyId).eq(CompanyCollection::getUserId, SecurityUtils.getUserId()));
|
||||
List<CompanyCollection> companyCollections = companyCollectionMapper.selectList(Wrappers.<CompanyCollection>lambdaQuery().eq(CompanyCollection::getCompanyId, companyId).eq(CompanyCollection::getUserId, SiteSecurityUtils.getUserId()));
|
||||
if(companyCollections.size()>0){
|
||||
companyCollectionMapper.deleteBatchIds(companyCollections.stream().map(CompanyCollection::getId).collect(Collectors.toList()));
|
||||
}
|
||||
@@ -104,7 +104,7 @@ public class CompanyCollectionServiceImpl extends ServiceImpl<CompanyCollectionM
|
||||
*/
|
||||
@Override
|
||||
public int companyCollection(Long companyId) {
|
||||
Long userId = SecurityUtils.getUserId();
|
||||
Long userId = SiteSecurityUtils.getUserId();
|
||||
List<CompanyCollection> companyCollections = companyCollectionMapper.selectList(Wrappers.<CompanyCollection>lambdaQuery().eq(CompanyCollection::getCompanyId, companyId).eq(CompanyCollection::getUserId, userId));
|
||||
if(companyCollections.size()>0){
|
||||
companyCollectionMapper.deleteBatchIds(companyCollections.stream().map(CompanyCollection::getId).collect(Collectors.toList()));
|
||||
@@ -118,7 +118,7 @@ public class CompanyCollectionServiceImpl extends ServiceImpl<CompanyCollectionM
|
||||
|
||||
@Override
|
||||
public List<Company> collectionCompany() {
|
||||
List<Company> companies = companyCollectionMapper.collectionJob(SecurityUtils.getUserId());
|
||||
List<Company> companies = companyCollectionMapper.collectionJob(SiteSecurityUtils.getUserId());
|
||||
return companies;
|
||||
}
|
||||
|
||||
|
@@ -0,0 +1,22 @@
|
||||
package com.ruoyi.cms.service.impl;
|
||||
|
||||
import com.ruoyi.common.core.domain.entity.CompanyContact;
|
||||
import com.ruoyi.cms.mapper.CompanyContactMapper;
|
||||
import com.ruoyi.cms.service.CompanyContactService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import java.util.List;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
|
||||
|
||||
|
||||
@Service
|
||||
public class CompanyContactServiceImpl extends ServiceImpl<CompanyContactMapper, CompanyContact> implements CompanyContactService {
|
||||
|
||||
@Autowired
|
||||
CompanyContactMapper companyContactMapper;
|
||||
|
||||
public List<CompanyContact> getSelectList(CompanyContact companyContact){
|
||||
return companyContactMapper.getSelectList(companyContact);
|
||||
}
|
||||
}
|
@@ -6,14 +6,18 @@ import java.io.InputStream;
|
||||
import java.util.*;
|
||||
|
||||
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.ruoyi.cms.domain.*;
|
||||
import com.ruoyi.cms.domain.query.LabelQuery;
|
||||
import com.ruoyi.cms.mapper.*;
|
||||
import com.ruoyi.cms.service.ICompanyCollectionService;
|
||||
import com.ruoyi.common.core.page.PageDomain;
|
||||
import com.ruoyi.common.constant.Constants;
|
||||
import com.ruoyi.common.core.domain.entity.Company;
|
||||
import com.ruoyi.common.core.domain.entity.CompanyContact;
|
||||
import com.ruoyi.common.core.domain.model.LoginSiteUser;
|
||||
import com.ruoyi.common.core.domain.model.LoginUser;
|
||||
import com.ruoyi.common.exception.ServiceException;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.SiteSecurityUtils;
|
||||
import com.ruoyi.common.utils.bean.BeanUtils;
|
||||
import org.apache.poi.ss.usermodel.Cell;
|
||||
import org.apache.poi.ss.usermodel.Row;
|
||||
import org.apache.poi.ss.usermodel.Sheet;
|
||||
@@ -31,7 +35,7 @@ import com.ruoyi.cms.service.ICompanyService;
|
||||
* @date 2024-09-04
|
||||
*/
|
||||
@Service
|
||||
public class CompanyServiceImpl extends ServiceImpl<CompanyMapper,Company> implements ICompanyService
|
||||
public class CompanyServiceImpl extends ServiceImpl<CompanyMapper, Company> implements ICompanyService
|
||||
{
|
||||
@Autowired
|
||||
private CompanyMapper companyMapper;
|
||||
@@ -43,6 +47,8 @@ public class CompanyServiceImpl extends ServiceImpl<CompanyMapper,Company> imple
|
||||
private CompanyCardMapper companyCardMapper;
|
||||
@Autowired
|
||||
private CompanyLabelMapper companyLabelMapper;
|
||||
@Autowired
|
||||
private CompanyContactMapper companyContactMapper;
|
||||
/**
|
||||
* 查询公司
|
||||
*
|
||||
@@ -53,11 +59,23 @@ public class CompanyServiceImpl extends ServiceImpl<CompanyMapper,Company> imple
|
||||
public Company selectCompanyByCompanyId(Long companyId)
|
||||
{
|
||||
Company company = companyMapper.selectById(companyId);
|
||||
if(SecurityUtils.isLogin()){
|
||||
Long l = companyCollectionMapper.selectCount(Wrappers.<CompanyCollection>lambdaQuery().eq(CompanyCollection::getCompanyId, companyId).eq(CompanyCollection::getUserId, SecurityUtils.getUserId()));
|
||||
company.setIsCollection(l>0?1:0);
|
||||
}else {
|
||||
company.setIsCollection(0);
|
||||
Long userId=null;
|
||||
try {
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
userId = loginUser.getUserId();
|
||||
}catch (Exception ignored){
|
||||
LoginSiteUser siteUser = SiteSecurityUtils.getLoginSiteUser();
|
||||
userId = siteUser.getUserId();
|
||||
}
|
||||
//收藏
|
||||
Long l = companyCollectionMapper.selectCount(Wrappers.<CompanyCollection>lambdaQuery().eq(CompanyCollection::getCompanyId, companyId).eq(CompanyCollection::getUserId, userId));
|
||||
company.setIsCollection(l>0?1:0);
|
||||
//联系人
|
||||
CompanyContact contact=new CompanyContact();
|
||||
contact.setCompanyId(company.getCompanyId());
|
||||
List<CompanyContact> contacts=companyContactMapper.getSelectList(contact);
|
||||
if(contacts!=null){
|
||||
company.setCompanyContactList(contacts);
|
||||
}
|
||||
return company;
|
||||
}
|
||||
@@ -87,7 +105,16 @@ public class CompanyServiceImpl extends ServiceImpl<CompanyMapper,Company> imple
|
||||
if(count>0){
|
||||
throw new ServiceException(company.getName()+",该公司已存在");
|
||||
}
|
||||
return companyMapper.insert(company);
|
||||
int insert =companyMapper.insert(company);
|
||||
if(insert>0){
|
||||
company.getCompanyContactList().forEach(x->{
|
||||
CompanyContact companyContact=new CompanyContact();
|
||||
BeanUtils.copyProperties(x,companyContact);
|
||||
companyContact.setCompanyId(company.getCompanyId());
|
||||
companyContactMapper.insert(companyContact);
|
||||
});
|
||||
}
|
||||
return insert;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -103,7 +130,19 @@ public class CompanyServiceImpl extends ServiceImpl<CompanyMapper,Company> imple
|
||||
if(count>1){
|
||||
throw new ServiceException(company.getName()+",该公司已存在");
|
||||
}
|
||||
return companyMapper.updateById(company);
|
||||
int i=companyMapper.updateById(company);
|
||||
if(i>0){
|
||||
companyContactMapper.update(null,Wrappers.<CompanyContact>lambdaUpdate()
|
||||
.eq(CompanyContact::getCompanyId, company.getCompanyId())
|
||||
.set(CompanyContact::getDelFlag, Constants.Del_FLAG_DELETE));
|
||||
if(Objects.isNull(company.getCompanyContactList())){return i;}
|
||||
company.getCompanyContactList().forEach(x -> {
|
||||
CompanyContact companyContact = new CompanyContact();
|
||||
companyContact.setCompanyId(company.getCompanyId());
|
||||
companyContactMapper.insert(companyContact);
|
||||
});
|
||||
}
|
||||
return i;
|
||||
}
|
||||
|
||||
|
||||
@@ -120,7 +159,13 @@ public class CompanyServiceImpl extends ServiceImpl<CompanyMapper,Company> imple
|
||||
if(aLong>0){
|
||||
throw new ServiceException("该公司下存在职位,不能删除");
|
||||
}
|
||||
return companyMapper.deleteBatchIds(Arrays.asList(companyIds));
|
||||
int i=companyMapper.deleteBatchIds(Arrays.asList(companyIds));
|
||||
if(i>0){
|
||||
companyContactMapper.update(null,Wrappers.<CompanyContact>lambdaUpdate()
|
||||
.in(CompanyContact::getCompanyId, Arrays.asList(companyIds))
|
||||
.set(CompanyContact::getDelFlag, Constants.Del_FLAG_DELETE));
|
||||
}
|
||||
return i;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -215,7 +260,7 @@ public class CompanyServiceImpl extends ServiceImpl<CompanyMapper,Company> imple
|
||||
|
||||
@Override
|
||||
public void register(Company company) {
|
||||
Long userId = SecurityUtils.getUserId();
|
||||
Long userId = SiteSecurityUtils.getUserId();
|
||||
company.setUserId(userId);
|
||||
if(companyMapper.selectCount(Wrappers.<Company>lambdaQuery().eq(Company::getName, company.getName()).in(Company::getStatus,Arrays.asList(0,1)))>0){
|
||||
throw new ServiceException(company.getName()+"已经存在");
|
||||
@@ -225,8 +270,35 @@ public class CompanyServiceImpl extends ServiceImpl<CompanyMapper,Company> imple
|
||||
|
||||
@Override
|
||||
public Company registerStatus() {
|
||||
Long userId = SecurityUtils.getUserId();
|
||||
Long userId = SiteSecurityUtils.getUserId();
|
||||
Company company = companyMapper.selectOne(Wrappers.<Company>lambdaQuery().eq(Company::getUserId, userId).orderByDesc(Company::getUpdateTime));
|
||||
return company;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Company> approvalList(Company company) {
|
||||
return companyMapper.selectList(Wrappers.<Company>lambdaQuery().eq(Company::getName, company.getName()).in(Company::getStatus, Arrays.asList(0, 1, 2)).orderByAsc(Company::getStatus).orderByDesc(Company::getCreateTime));
|
||||
}
|
||||
|
||||
@Override
|
||||
public Company approval(Company company) {
|
||||
Company company1 = companyMapper.selectById(company.getCompanyId());
|
||||
if(company1==null){
|
||||
throw new ServiceException("企业不存在");
|
||||
}
|
||||
if(company1.getStatus()!=null){
|
||||
if(company1.getStatus()!=0){
|
||||
throw new ServiceException("企业已审核");
|
||||
}
|
||||
}
|
||||
companyMapper.updateById(company);
|
||||
//创建账号
|
||||
return company1;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Company queryCodeCompany(String code) {
|
||||
Company companyResult = companyMapper.selectOne(Wrappers.<Company>lambdaQuery().eq(Company::getCode, code).orderByDesc(Company::getUpdateTime).last("LIMIT 1"));
|
||||
return companyResult;
|
||||
}
|
||||
}
|
||||
|
@@ -1,18 +1,16 @@
|
||||
package com.ruoyi.cms.service.impl;
|
||||
|
||||
import com.ruoyi.cms.domain.AppUser;
|
||||
import com.ruoyi.common.core.domain.entity.AppUser;
|
||||
import com.ruoyi.cms.domain.ESJobDocument;
|
||||
import com.ruoyi.cms.domain.Job;
|
||||
import com.ruoyi.cms.domain.query.ESJobSearch;
|
||||
import com.ruoyi.cms.mapper.es.EsJobDocumentMapper;
|
||||
import com.ruoyi.cms.mapper.JobMapper;
|
||||
import com.ruoyi.cms.service.IESJobSearchService;
|
||||
import com.ruoyi.cms.util.Base64Util;
|
||||
import com.ruoyi.cms.util.ListUtil;
|
||||
import com.ruoyi.cms.util.StringUtil;
|
||||
import com.ruoyi.common.core.text.Convert;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.common.utils.SiteSecurityUtils;
|
||||
import com.ruoyi.common.utils.bean.BeanUtils;
|
||||
import org.dromara.easyes.core.biz.EsPageInfo;
|
||||
import org.dromara.easyes.core.conditions.select.LambdaEsQueryWrapper;
|
||||
@@ -51,7 +49,7 @@ public class ESJobSearchImpl implements IESJobSearchService
|
||||
/**
|
||||
* 项目启动时,初始化索引及数据
|
||||
*/
|
||||
// @PostConstruct
|
||||
@PostConstruct
|
||||
public void init()
|
||||
{
|
||||
resetTextCache();
|
||||
@@ -140,8 +138,8 @@ public class ESJobSearchImpl implements IESJobSearchService
|
||||
ESJobSearch newSearch = new ESJobSearch();
|
||||
BeanUtils.copyProperties(esJobSearch,newSearch);
|
||||
//查询
|
||||
if(SecurityUtils.isLogin()){
|
||||
AppUser appUser = appUserService.selectAppUserByUserId(SecurityUtils.getUserId());
|
||||
if(SiteSecurityUtils.isLogin()){
|
||||
AppUser appUser = appUserService.selectAppUserByUserId(SiteSecurityUtils.getUserId());
|
||||
if(!ListUtil.isEmptyOrNull(appUser.getJobTitle())){
|
||||
List<String> jobTitle = appUser.getJobTitle();
|
||||
newSearch.setJobTitle(String.join(",", jobTitle));
|
||||
@@ -174,6 +172,18 @@ public class ESJobSearchImpl implements IESJobSearchService
|
||||
if(!StringUtil.isEmptyOrNull(appUser.getSalaryMin())){
|
||||
newSearch.setMinSalary(Long.valueOf(appUser.getSalaryMin()));
|
||||
}
|
||||
if(!StringUtil.isEmptyOrNull(esJobSearch.getJobType())){
|
||||
newSearch.setJobType(esJobSearch.getJobType());
|
||||
}
|
||||
if(!StringUtil.isEmptyOrNull(esJobSearch.getType())){
|
||||
newSearch.setType(esJobSearch.getType());
|
||||
}
|
||||
if(!StringUtil.isEmptyOrNull(esJobSearch.getDescription())){
|
||||
newSearch.setDescription(esJobSearch.getDescription());
|
||||
}
|
||||
if(!StringUtil.isEmptyOrNull(esJobSearch.getCompanyNature())){
|
||||
newSearch.setCompanyNature(esJobSearch.getCompanyNature());
|
||||
}
|
||||
}
|
||||
|
||||
LambdaEsQueryWrapper<ESJobDocument> wrapper = getWrapper(newSearch,jobIds);
|
||||
@@ -395,6 +405,18 @@ public class ESJobSearchImpl implements IESJobSearchService
|
||||
List<Integer> integers = StringUtil.convertStringToIntegerList(esJobSearch.getArea());
|
||||
wrapper.and(x->x.in(ESJobDocument::getJobLocationAreaCode,integers));
|
||||
}
|
||||
if(!StringUtil.isEmptyOrNull(esJobSearch.getJobType())){
|
||||
wrapper.and(x->x.eq(ESJobDocument::getJobType,esJobSearch.getJobType()));
|
||||
}
|
||||
if(!StringUtil.isEmptyOrNull(esJobSearch.getType())){
|
||||
wrapper.and(x->x.eq(ESJobDocument::getType,esJobSearch.getType()));
|
||||
}
|
||||
if(!StringUtil.isEmptyOrNull(esJobSearch.getDescription())){
|
||||
wrapper.and(x->x.like(ESJobDocument::getDescription,esJobSearch.getDescription()));
|
||||
}
|
||||
if(!StringUtil.isEmptyOrNull(esJobSearch.getCompanyNature())){
|
||||
wrapper.and(x->x.eq(ESJobDocument::getCompanyNature,esJobSearch.getCompanyNature()));
|
||||
}
|
||||
if(Objects.nonNull(esJobSearch.getOrder())){
|
||||
if(esJobSearch.getOrder()==1){
|
||||
wrapper.orderByDesc(ESJobDocument::getIsHot);
|
||||
@@ -402,6 +424,9 @@ public class ESJobSearchImpl implements IESJobSearchService
|
||||
if(esJobSearch.getOrder()==2){
|
||||
wrapper.orderByDesc(ESJobDocument::getPostingDate);
|
||||
}
|
||||
if(esJobSearch.getOrder()==3){
|
||||
wrapper.orderByDesc(ESJobDocument::getMaxSalary);
|
||||
}
|
||||
}
|
||||
if(!ListUtil.isListEmptyOrNull(jobIds)){
|
||||
wrapper.not().in(ESJobDocument::getJobId, jobIds);
|
||||
@@ -415,8 +440,8 @@ public class ESJobSearchImpl implements IESJobSearchService
|
||||
Integer pageNum = jobQuery.getCurrent();
|
||||
Integer pageSize = jobQuery.getPageSize();
|
||||
LambdaEsQueryWrapper<ESJobDocument> wrapper = new LambdaEsQueryWrapper<>();
|
||||
// if(SecurityUtils.isLogin()){
|
||||
// AppUser appUser = appUserService.selectAppUserByUserId(SecurityUtils.getUserId());
|
||||
// if(SiteSecurityUtils.isLogin()){
|
||||
// AppUser appUser = appUserService.selectAppUserByUserId(SiteSecurityUtils.getUserId());
|
||||
// if(!ListUtil.isEmptyOrNull(appUser.getJobTitle())){
|
||||
// List<String> jobTitle = appUser.getJobTitle();
|
||||
// jobQuery.setJobTitle(String.join(",", jobTitle));
|
||||
@@ -540,4 +565,10 @@ public class ESJobSearchImpl implements IESJobSearchService
|
||||
esJobDocumentMapper.delete(lambdaEsQueryWrapper);
|
||||
esJobDocumentMapper.insert(esJobDocument);
|
||||
}
|
||||
|
||||
public List<ESJobDocument> selectByIds(Long[] jobIds) {
|
||||
LambdaEsQueryWrapper<ESJobDocument> wrapper = new LambdaEsQueryWrapper<>();
|
||||
wrapper.in(ESJobDocument::getJobId,jobIds);
|
||||
return esJobDocumentMapper.selectList(wrapper);
|
||||
}
|
||||
}
|
||||
|
@@ -0,0 +1,49 @@
|
||||
package com.ruoyi.cms.service.impl;
|
||||
|
||||
import com.ruoyi.cms.domain.EmployeeConfirm;
|
||||
import com.ruoyi.cms.domain.JobApply;
|
||||
import com.ruoyi.cms.mapper.EmployeeConfirmMapper;
|
||||
import com.ruoyi.cms.mapper.JobApplyMapper;
|
||||
import com.ruoyi.cms.service.EmployeeConfirmService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@Service
|
||||
public class EmployeeConfirmServiceImpl implements EmployeeConfirmService {
|
||||
|
||||
@Autowired
|
||||
EmployeeConfirmMapper employeeConfirmMapper;
|
||||
@Autowired
|
||||
private JobApplyMapper jobApplyMapper;
|
||||
|
||||
@Override
|
||||
public List<EmployeeConfirm> getEmployeeConfirmList(EmployeeConfirm employeeConfirm) {
|
||||
return employeeConfirmMapper.getEmployeeConfirmList(employeeConfirm);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int insertEmployeeConfirm(EmployeeConfirm employeeConfirm) {
|
||||
int t=employeeConfirmMapper.insert(employeeConfirm);
|
||||
if(t>0){
|
||||
JobApply apply=new JobApply();
|
||||
apply.setId(employeeConfirm.getApplyId());
|
||||
apply.setHire("0");
|
||||
jobApplyMapper.updateById(apply);
|
||||
}
|
||||
return t;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int updateEmployeeConfirm(EmployeeConfirm employeeConfirm) {
|
||||
return employeeConfirmMapper.updateById(employeeConfirm);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int deleteEmployeeConfirmIds(Long[] ids) {
|
||||
return employeeConfirmMapper.deleteBatchIds(Arrays.asList(ids));
|
||||
}
|
||||
}
|
@@ -2,13 +2,12 @@ package com.ruoyi.cms.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.ruoyi.cms.domain.Company;
|
||||
import com.ruoyi.cms.domain.FairCollection;
|
||||
import com.ruoyi.cms.domain.JobFair;
|
||||
import com.ruoyi.cms.mapper.FairCollectionMapper;
|
||||
import com.ruoyi.cms.mapper.JobFairMapper;
|
||||
import com.ruoyi.cms.service.IFairCollectionService;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.SiteSecurityUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
@@ -50,7 +49,7 @@ public class FairCollectionServiceImpl extends ServiceImpl<FairCollectionMapper,
|
||||
@Override
|
||||
public List<FairCollection> selectFairCollectionList(FairCollection fairCollection)
|
||||
{
|
||||
List<FairCollection> fairCollections = fairCollectionMapper.selectList(Wrappers.<FairCollection>lambdaQuery().eq(FairCollection::getUserId, SecurityUtils.getUserId()));
|
||||
List<FairCollection> fairCollections = fairCollectionMapper.selectList(Wrappers.<FairCollection>lambdaQuery().eq(FairCollection::getUserId, SiteSecurityUtils.getUserId()));
|
||||
return fairCollections;
|
||||
}
|
||||
|
||||
@@ -95,7 +94,7 @@ public class FairCollectionServiceImpl extends ServiceImpl<FairCollectionMapper,
|
||||
@Override
|
||||
@Transactional
|
||||
public int fairCollection(Long fairId) {
|
||||
Long userId = SecurityUtils.getUserId();
|
||||
Long userId = SiteSecurityUtils.getUserId();
|
||||
List<FairCollection> fairCollections = fairCollectionMapper.selectList(Wrappers.<FairCollection>lambdaQuery().eq(FairCollection::getFairId, fairId).eq(FairCollection::getUserId, userId));
|
||||
if(fairCollections.size()>0){
|
||||
fairCollectionMapper.deleteBatchIds(fairCollections.stream().map(FairCollection::getId).collect(Collectors.toList()));
|
||||
@@ -111,7 +110,7 @@ public class FairCollectionServiceImpl extends ServiceImpl<FairCollectionMapper,
|
||||
*/
|
||||
@Override
|
||||
public int cancel(Long fairId) {
|
||||
Long userId = SecurityUtils.getUserId();
|
||||
Long userId = SiteSecurityUtils.getUserId();
|
||||
List<FairCollection> fairCollections = fairCollectionMapper.selectList(Wrappers.<FairCollection>lambdaQuery().eq(FairCollection::getFairId, fairId).eq(FairCollection::getUserId, userId));
|
||||
if(fairCollections.size()>0){
|
||||
fairCollectionMapper.deleteBatchIds(fairCollections.stream().map(FairCollection::getId).collect(Collectors.toList()));
|
||||
@@ -123,6 +122,6 @@ public class FairCollectionServiceImpl extends ServiceImpl<FairCollectionMapper,
|
||||
*/
|
||||
@Override
|
||||
public List<JobFair> appCollectionFair(Integer type) {
|
||||
return jobFairMapper.selectAppList(SecurityUtils.getUserId(),type);
|
||||
return jobFairMapper.selectAppList(SiteSecurityUtils.getUserId(),type);
|
||||
}
|
||||
}
|
||||
|
@@ -12,7 +12,7 @@ import com.ruoyi.cms.mapper.FileMapper;
|
||||
import com.ruoyi.cms.service.IFileService;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.SiteSecurityUtils;
|
||||
import com.ruoyi.common.utils.uuid.IdUtils;
|
||||
import com.ruoyi.common.utils.uuid.UUID;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
|
@@ -6,9 +6,10 @@ import com.ruoyi.cms.domain.FairCollection;
|
||||
import com.ruoyi.cms.domain.Job;
|
||||
import com.ruoyi.cms.domain.JobApply;
|
||||
import com.ruoyi.cms.domain.query.MineJobQuery;
|
||||
import com.ruoyi.cms.domain.vo.CandidateVO;
|
||||
import com.ruoyi.cms.mapper.*;
|
||||
import com.ruoyi.cms.service.IJobApplyService;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.SiteSecurityUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
@@ -98,17 +99,17 @@ public class JobApplyServiceImpl extends ServiceImpl<JobApplyMapper,JobApply> im
|
||||
|
||||
@Override
|
||||
public List<Job> applyJob() {
|
||||
List<Job> jobs = jobApplyMapper.applyJob(SecurityUtils.getUserId());
|
||||
List<Job> jobs = jobApplyMapper.applyJob(SiteSecurityUtils.getUserId());
|
||||
return jobs;
|
||||
}
|
||||
|
||||
@Override
|
||||
public HashMap<String, Integer> statistics() {
|
||||
Integer applyCount = jobApplyMapper.applyJob(SecurityUtils.getUserId()).size();
|
||||
Integer collectionJobCount = jobCollectionMapper.collectionJob(SecurityUtils.getUserId()).size();
|
||||
Integer collectionCompanyCount = companyCollectionMapper.collectionJob(SecurityUtils.getUserId()).size();
|
||||
Integer jobReviewCount = appReviewJobMapper.review(SecurityUtils.getUserId(),new MineJobQuery()).size();
|
||||
Integer fairCollecitonCount = fairCollectionMapper.selectList(Wrappers.<FairCollection>lambdaQuery().eq(FairCollection::getUserId, SecurityUtils.getUserId())).size();
|
||||
Integer applyCount = jobApplyMapper.applyJob(SiteSecurityUtils.getUserId()).size();
|
||||
Integer collectionJobCount = jobCollectionMapper.collectionJob(SiteSecurityUtils.getUserId()).size();
|
||||
Integer collectionCompanyCount = companyCollectionMapper.collectionJob(SiteSecurityUtils.getUserId()).size();
|
||||
Integer jobReviewCount = appReviewJobMapper.review(SiteSecurityUtils.getUserId(),new MineJobQuery()).size();
|
||||
Integer fairCollecitonCount = fairCollectionMapper.selectList(Wrappers.<FairCollection>lambdaQuery().eq(FairCollection::getUserId, SiteSecurityUtils.getUserId())).size();
|
||||
HashMap<String, Integer> map = new HashMap<>();
|
||||
map.put("applyCount", applyCount);
|
||||
map.put("collectionCount", collectionJobCount+collectionCompanyCount);
|
||||
@@ -116,4 +117,14 @@ public class JobApplyServiceImpl extends ServiceImpl<JobApplyMapper,JobApply> im
|
||||
map.put("fairCollecitonCount", fairCollecitonCount);
|
||||
return map;
|
||||
}
|
||||
|
||||
@Override
|
||||
public HashMap<String, Integer> trendChart(JobApply jobApply) {
|
||||
return jobApplyMapper.trendChart(jobApply);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<CandidateVO> selectAppUserList(Job job) {
|
||||
return jobApplyMapper.selectAppUserList(job);
|
||||
}
|
||||
}
|
||||
|
@@ -14,7 +14,8 @@ import com.ruoyi.cms.mapper.AppUserMapper;
|
||||
import com.ruoyi.cms.mapper.JobApplyMapper;
|
||||
import com.ruoyi.cms.mapper.JobMapper;
|
||||
import com.ruoyi.cms.service.IBussinessDictTypeService;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.core.domain.entity.AppUser;
|
||||
import com.ruoyi.common.utils.SiteSecurityUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import org.springframework.stereotype.Service;
|
||||
@@ -106,7 +107,7 @@ public class JobCollectionServiceImpl extends ServiceImpl<JobCollectionMapper,Jo
|
||||
@Override
|
||||
@Transactional
|
||||
public int jobCollection(Long jobId) {
|
||||
Long userId = SecurityUtils.getUserId();
|
||||
Long userId = SiteSecurityUtils.getUserId();
|
||||
List<JobCollection> jobCollections = jobCollectionMapper.selectList(Wrappers.<JobCollection>lambdaQuery().eq(JobCollection::getJobId, jobId).eq(JobCollection::getUserId, userId));
|
||||
if(jobCollections.size()>0){
|
||||
jobCollectionMapper.deleteBatchIds(jobCollections.stream().map(JobCollection::getId).collect(Collectors.toList()));
|
||||
@@ -122,7 +123,7 @@ public class JobCollectionServiceImpl extends ServiceImpl<JobCollectionMapper,Jo
|
||||
*/
|
||||
@Override
|
||||
public int cancel(Long jobId) {
|
||||
Long userId = SecurityUtils.getUserId();
|
||||
Long userId = SiteSecurityUtils.getUserId();
|
||||
List<JobCollection> jobCollections = jobCollectionMapper.selectList(Wrappers.<JobCollection>lambdaQuery().eq(JobCollection::getJobId, jobId).eq(JobCollection::getUserId, userId));
|
||||
if(jobCollections.size()>0){
|
||||
jobCollectionMapper.deleteBatchIds(jobCollections.stream().map(JobCollection::getId).collect(Collectors.toList()));
|
||||
@@ -132,7 +133,7 @@ public class JobCollectionServiceImpl extends ServiceImpl<JobCollectionMapper,Jo
|
||||
|
||||
@Override
|
||||
public int apply(Long jobId) {
|
||||
Long userId = SecurityUtils.getUserId();
|
||||
Long userId = SiteSecurityUtils.getUserId();
|
||||
JobApply jobApply = new JobApply();
|
||||
jobApply.setJobId(jobId);
|
||||
jobApply.setUserId(userId);
|
||||
@@ -149,7 +150,7 @@ public class JobCollectionServiceImpl extends ServiceImpl<JobCollectionMapper,Jo
|
||||
|
||||
@Override
|
||||
public List<Job> collectionJob() {
|
||||
List<Job> jobs = jobCollectionMapper.collectionJob(SecurityUtils.getUserId());
|
||||
List<Job> jobs = jobCollectionMapper.collectionJob(SiteSecurityUtils.getUserId());
|
||||
return jobs;
|
||||
}
|
||||
|
||||
|
@@ -0,0 +1,21 @@
|
||||
package com.ruoyi.cms.service.impl;
|
||||
|
||||
import com.ruoyi.cms.domain.JobContact;
|
||||
import com.ruoyi.cms.mapper.JobContactMapper;
|
||||
import com.ruoyi.cms.service.JobContactService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import java.util.List;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
|
||||
|
||||
@Service
|
||||
public class JobContactServiceImpl extends ServiceImpl<JobContactMapper, JobContact> implements JobContactService {
|
||||
|
||||
@Autowired
|
||||
JobContactMapper jobContactMapper;
|
||||
|
||||
public List<JobContact> getSelectList(JobContact jobContact){
|
||||
return jobContactMapper.getSelectList(jobContact);
|
||||
}
|
||||
}
|
@@ -9,8 +9,9 @@ import com.ruoyi.cms.mapper.CompanyMapper;
|
||||
import com.ruoyi.cms.mapper.FairCollectionMapper;
|
||||
import com.ruoyi.cms.mapper.FairCompanyMapper;
|
||||
import com.ruoyi.common.constant.Constants;
|
||||
import com.ruoyi.common.core.domain.entity.Company;
|
||||
import com.ruoyi.common.exception.ServiceException;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.SiteSecurityUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import org.springframework.stereotype.Service;
|
||||
@@ -148,8 +149,8 @@ public class JobFairServiceImpl extends ServiceImpl<JobFairMapper,JobFair> imple
|
||||
List<Company> companyList = companyMapper.selectBatchIds(companyIds);
|
||||
jobFair.setCompanyList(companyList);
|
||||
}
|
||||
if(SecurityUtils.isLogin()){
|
||||
Long count = fairCollectionMapper.selectCount(Wrappers.<FairCollection>lambdaQuery().eq(FairCollection::getFairId, fairId).eq(FairCollection::getUserId, SecurityUtils.getUserId()));
|
||||
if(SiteSecurityUtils.isLogin()){
|
||||
Long count = fairCollectionMapper.selectCount(Wrappers.<FairCollection>lambdaQuery().eq(FairCollection::getFairId, fairId).eq(FairCollection::getUserId, SiteSecurityUtils.getUserId()));
|
||||
jobFair.setIsCollection(count>0?1:null);
|
||||
}
|
||||
return jobFair;
|
||||
@@ -159,10 +160,10 @@ public class JobFairServiceImpl extends ServiceImpl<JobFairMapper,JobFair> imple
|
||||
public List<JobFair> appList(JobFair jobFair) {
|
||||
List<JobFair> fairCompanies = jobFairMapper.appList(jobFair);
|
||||
if(fairCompanies.isEmpty()){return new ArrayList<>();}
|
||||
if(SecurityUtils.isLogin()){
|
||||
if(SiteSecurityUtils.isLogin()){
|
||||
//收藏
|
||||
Set<Long> collectionIds = fairCollectionMapper.selectList(Wrappers.<FairCollection>lambdaQuery()
|
||||
.eq(FairCollection::getUserId, SecurityUtils.getUserId())
|
||||
.eq(FairCollection::getUserId, SiteSecurityUtils.getUserId())
|
||||
.in(FairCollection::getFairId, fairCompanies.stream().map(JobFair::getJobFairId).collect(Collectors.toList())))
|
||||
.stream().map(FairCollection::getFairId).collect(Collectors.toSet());
|
||||
for (JobFair j : fairCompanies) {
|
||||
|
@@ -2,16 +2,15 @@ package com.ruoyi.cms.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.ruoyi.cms.domain.AppUser;
|
||||
import com.ruoyi.common.core.domain.entity.AppUser;
|
||||
import com.ruoyi.cms.domain.Job;
|
||||
import com.ruoyi.cms.domain.JobApply;
|
||||
import com.ruoyi.cms.domain.JobCollection;
|
||||
import com.ruoyi.cms.mapper.AppUserMapper;
|
||||
import com.ruoyi.cms.mapper.JobApplyMapper;
|
||||
import com.ruoyi.cms.mapper.JobCollectionMapper;
|
||||
import com.ruoyi.cms.service.IJobCollectionService;
|
||||
import com.ruoyi.cms.service.IJobRecommentService;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.SiteSecurityUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
@@ -100,7 +99,7 @@ public class JobRecommentServiceImpl extends ServiceImpl<JobCollectionMapper,Job
|
||||
@Override
|
||||
@Transactional
|
||||
public int jobCollection(Long jobId) {
|
||||
Long userId = SecurityUtils.getUserId();
|
||||
Long userId = SiteSecurityUtils.getUserId();
|
||||
List<JobCollection> jobCollections = jobCollectionMapper.selectList(Wrappers.<JobCollection>lambdaQuery().eq(JobCollection::getJobId, jobId).eq(JobCollection::getUserId, userId));
|
||||
if(jobCollections.size()>0){
|
||||
jobCollectionMapper.deleteBatchIds(jobCollections.stream().map(JobCollection::getId).collect(Collectors.toList()));
|
||||
@@ -116,7 +115,7 @@ public class JobRecommentServiceImpl extends ServiceImpl<JobCollectionMapper,Job
|
||||
*/
|
||||
@Override
|
||||
public int cancel(Long jobId) {
|
||||
Long userId = SecurityUtils.getUserId();
|
||||
Long userId = SiteSecurityUtils.getUserId();
|
||||
List<JobCollection> jobCollections = jobCollectionMapper.selectList(Wrappers.<JobCollection>lambdaQuery().eq(JobCollection::getJobId, jobId).eq(JobCollection::getUserId, userId));
|
||||
if(jobCollections.size()>0){
|
||||
jobCollectionMapper.deleteBatchIds(jobCollections.stream().map(JobCollection::getId).collect(Collectors.toList()));
|
||||
@@ -126,7 +125,7 @@ public class JobRecommentServiceImpl extends ServiceImpl<JobCollectionMapper,Job
|
||||
|
||||
@Override
|
||||
public int apply(Long jobId) {
|
||||
Long userId = SecurityUtils.getUserId();
|
||||
Long userId = SiteSecurityUtils.getUserId();
|
||||
JobApply jobApply = new JobApply();
|
||||
jobApply.setJobId(jobId);
|
||||
jobApply.setUserId(userId);
|
||||
@@ -143,13 +142,13 @@ public class JobRecommentServiceImpl extends ServiceImpl<JobCollectionMapper,Job
|
||||
|
||||
@Override
|
||||
public List<Job> collectionJob() {
|
||||
List<Job> jobs = jobCollectionMapper.collectionJob(SecurityUtils.getUserId());
|
||||
List<Job> jobs = jobCollectionMapper.collectionJob(SiteSecurityUtils.getUserId());
|
||||
return jobs;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String competitiveness(Long jobId) {
|
||||
AppUser appUser = appUserMapper.selectById(SecurityUtils.getUserId());
|
||||
AppUser appUser = appUserMapper.selectById(SiteSecurityUtils.getUserId());
|
||||
String education = appUser.getEducation();
|
||||
return "90.5";
|
||||
}
|
||||
|
@@ -9,16 +9,19 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.fasterxml.jackson.core.type.TypeReference;
|
||||
import com.fasterxml.jackson.databind.ObjectMapper;
|
||||
import com.ruoyi.cms.domain.*;
|
||||
import com.ruoyi.cms.domain.File;
|
||||
import com.ruoyi.cms.domain.query.ESJobSearch;
|
||||
import com.ruoyi.cms.domain.vo.CandidateVO;
|
||||
import com.ruoyi.cms.mapper.*;
|
||||
import com.ruoyi.cms.service.*;
|
||||
import com.ruoyi.cms.util.*;
|
||||
import com.ruoyi.common.constant.Constants;
|
||||
import com.ruoyi.common.core.domain.TreeSelect;
|
||||
import com.ruoyi.common.core.domain.entity.Company;
|
||||
import com.ruoyi.common.core.domain.entity.JobTitle;
|
||||
import com.ruoyi.common.core.redis.RedisCache;
|
||||
import com.ruoyi.common.exception.ServiceException;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.SiteSecurityUtils;
|
||||
import com.ruoyi.common.utils.bean.BeanUtils;
|
||||
import com.ruoyi.common.utils.spring.SpringUtils;
|
||||
import org.dromara.easyes.core.biz.EsPageInfo;
|
||||
@@ -28,11 +31,9 @@ import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.io.*;
|
||||
import java.io.File;
|
||||
import java.math.BigDecimal;
|
||||
import java.net.HttpURLConnection;
|
||||
import java.net.URL;
|
||||
import java.nio.charset.StandardCharsets;
|
||||
import java.time.LocalDateTime;
|
||||
import java.time.format.DateTimeFormatter;
|
||||
import java.util.*;
|
||||
@@ -73,6 +74,10 @@ public class JobServiceImpl extends ServiceImpl<JobMapper,Job> implements IJobSe
|
||||
private static final String AMAP_URL = "https://restapi.amap.com/v3/place/text";
|
||||
@Autowired
|
||||
private RedisCache redisCache;
|
||||
@Autowired
|
||||
private JobContactMapper jobContactMapper;
|
||||
@Autowired
|
||||
private FileMapper fileMapper;
|
||||
|
||||
/**
|
||||
* 更新工作地址的经纬度信息
|
||||
@@ -197,6 +202,21 @@ public class JobServiceImpl extends ServiceImpl<JobMapper,Job> implements IJobSe
|
||||
Company company = companyMapper.selectById(job.getCompanyId());
|
||||
job.setCompany(company);
|
||||
}
|
||||
//查询联系人
|
||||
JobContact contact=new JobContact();
|
||||
contact.setJobId(job.getJobId());
|
||||
List<JobContact> contacts=jobContactMapper.getSelectList(contact);
|
||||
if(contacts!=null){
|
||||
job.setJobContactList(contacts);
|
||||
}
|
||||
//查询附件
|
||||
File file=new File();
|
||||
file.setBussinessId(jobId);
|
||||
List<File> filesList=fileMapper.selectFileList(file);
|
||||
if(filesList!=null){
|
||||
job.setFilesList(filesList);
|
||||
}
|
||||
|
||||
return job;
|
||||
}
|
||||
|
||||
@@ -242,6 +262,14 @@ public class JobServiceImpl extends ServiceImpl<JobMapper,Job> implements IJobSe
|
||||
HttpUtil.post("http://39.98.44.136:6004/insert_vector", jsonBody);
|
||||
});
|
||||
thread.start();
|
||||
if(insert>0){
|
||||
job.getJobContactList().forEach(x->{
|
||||
JobContact jobContact=new JobContact();
|
||||
BeanUtils.copyProperties(x,jobContact);
|
||||
jobContact.setJobId(job.getJobId());
|
||||
jobContactMapper.insert(jobContact);
|
||||
});
|
||||
}
|
||||
return insert;
|
||||
}
|
||||
|
||||
@@ -268,7 +296,20 @@ public class JobServiceImpl extends ServiceImpl<JobMapper,Job> implements IJobSe
|
||||
iesJobSearchService.deleteJob(job.getJobId());
|
||||
}
|
||||
}
|
||||
return jobMapper.updateById(job);
|
||||
int i=jobMapper.updateById(job);
|
||||
//修改岗位联系人列表
|
||||
if(i>0){
|
||||
jobContactMapper.update(null,Wrappers.<JobContact>lambdaUpdate()
|
||||
.eq(JobContact::getJobId, job.getJobId())
|
||||
.set(JobContact::getDelFlag, Constants.Del_FLAG_DELETE));
|
||||
if(Objects.isNull(job.getJobContactList())){return i;}
|
||||
job.getJobContactList().forEach(x -> {
|
||||
JobContact jobContact = new JobContact();
|
||||
jobContact.setJobId(job.getJobId());
|
||||
jobContactMapper.insert(jobContact);
|
||||
});
|
||||
}
|
||||
return i;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -280,7 +321,13 @@ public class JobServiceImpl extends ServiceImpl<JobMapper,Job> implements IJobSe
|
||||
@Override
|
||||
public int deleteJobByJobIds(Long[] jobIds)
|
||||
{
|
||||
return jobMapper.deleteBatchIds(Arrays.asList(jobIds));
|
||||
int i=jobMapper.deleteBatchIds(Arrays.asList(jobIds));
|
||||
if(i>0){
|
||||
jobContactMapper.update(null,Wrappers.<JobContact>lambdaUpdate()
|
||||
.in(JobContact::getJobId, Arrays.asList(jobIds))
|
||||
.set(JobContact::getDelFlag, Constants.Del_FLAG_DELETE));
|
||||
}
|
||||
return i;
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -343,22 +390,22 @@ public class JobServiceImpl extends ServiceImpl<JobMapper,Job> implements IJobSe
|
||||
Company company = companyMapper.selectById(job.getCompanyId());
|
||||
job.setCompany(company);
|
||||
}
|
||||
if(SecurityUtils.isLogin()){
|
||||
if(SiteSecurityUtils.isLogin()){
|
||||
//查询申请信息
|
||||
Long applyCount = jobApplyMapper.selectCount(Wrappers.<JobApply>lambdaQuery().eq(JobApply::getJobId, jobId).eq(JobApply::getUserId, SecurityUtils.getUserId()));
|
||||
Long applyCount = jobApplyMapper.selectCount(Wrappers.<JobApply>lambdaQuery().eq(JobApply::getJobId, jobId).eq(JobApply::getUserId, SiteSecurityUtils.getUserId()));
|
||||
job.setIsApply(applyCount>0?1:0);
|
||||
//查询收藏信息
|
||||
Long collectionCount = jobCollectionMapper.selectCount(Wrappers.<JobCollection>lambdaQuery().eq(JobCollection::getJobId, jobId).eq(JobCollection::getUserId, SecurityUtils.getUserId()));
|
||||
Long collectionCount = jobCollectionMapper.selectCount(Wrappers.<JobCollection>lambdaQuery().eq(JobCollection::getJobId, jobId).eq(JobCollection::getUserId, SiteSecurityUtils.getUserId()));
|
||||
job.setIsCollection(collectionCount>0?1:0);
|
||||
//todo asyn
|
||||
//保存浏览记录
|
||||
List<AppReviewJob> appReviewJobs = appReviewJobMapper.selectList(Wrappers.<AppReviewJob>lambdaQuery().eq(AppReviewJob::getUserId, SecurityUtils.getUserId()).eq(AppReviewJob::getJobId, jobId));
|
||||
List<AppReviewJob> appReviewJobs = appReviewJobMapper.selectList(Wrappers.<AppReviewJob>lambdaQuery().eq(AppReviewJob::getUserId, SiteSecurityUtils.getUserId()).eq(AppReviewJob::getJobId, jobId));
|
||||
//之前相同岗位的记录删除 保存最新的浏览记录
|
||||
if(!appReviewJobs.isEmpty()){
|
||||
appReviewJobMapper.deleteBatchIds(appReviewJobs.stream().map(AppReviewJob::getId).collect(Collectors.toList()));
|
||||
}
|
||||
AppReviewJob appReviewJob = new AppReviewJob();
|
||||
appReviewJob.setUserId(SecurityUtils.getUserId());
|
||||
appReviewJob.setUserId(SiteSecurityUtils.getUserId());
|
||||
LocalDateTime now = LocalDateTime.now();
|
||||
String formattedDate = now.format(DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss"));
|
||||
appReviewJob.setReviewDate(formattedDate);
|
||||
@@ -659,6 +706,7 @@ public class JobServiceImpl extends ServiceImpl<JobMapper,Job> implements IJobSe
|
||||
logger.error("导入数据过程中发生异常: {}", e.getMessage(), e);
|
||||
throw new RuntimeException(e);
|
||||
}
|
||||
iesJobSearchService.resetTextCache();
|
||||
}
|
||||
|
||||
private Long getCompanyId(List<Company> allCompany, String aab004) {
|
||||
@@ -722,10 +770,10 @@ public class JobServiceImpl extends ServiceImpl<JobMapper,Job> implements IJobSe
|
||||
|
||||
private List<ESJobDocument> userCollection(List<ESJobDocument> jobs){
|
||||
if(jobs.isEmpty()){return new ArrayList<>();}
|
||||
if(SecurityUtils.isLogin()){
|
||||
if(SiteSecurityUtils.isLogin()){
|
||||
//收藏
|
||||
Set<Long> collectionIds = jobCollectionMapper.selectList(Wrappers.<JobCollection>lambdaQuery()
|
||||
.eq(JobCollection::getUserId, SecurityUtils.getUserId())
|
||||
.eq(JobCollection::getUserId, SiteSecurityUtils.getUserId())
|
||||
.in(JobCollection::getJobId, jobs.stream().map(ESJobDocument::getJobId).collect(Collectors.toList())))
|
||||
.stream().map(JobCollection::getJobId).collect(Collectors.toSet());
|
||||
for (ESJobDocument j : jobs) {
|
||||
@@ -740,12 +788,19 @@ public class JobServiceImpl extends ServiceImpl<JobMapper,Job> implements IJobSe
|
||||
@Override
|
||||
public void publishJob(Job job) {
|
||||
job.setIsPublish(0);
|
||||
Long userId = SecurityUtils.getUserId();
|
||||
Company company = companyMapper.selectOne(Wrappers.<Company>lambdaQuery().eq(Company::getUserId, userId).eq(Company::getStatus, 1));
|
||||
if(Objects.isNull(company)){
|
||||
throw new ServiceException("请先完成招聘企业登记");
|
||||
}
|
||||
job.setCompanyId(company.getCompanyId());
|
||||
// Long userId = SiteSecurityUtils.getUserId();
|
||||
// Company company = companyMapper.selectOne(Wrappers.<Company>lambdaQuery().eq(Company::getUserId, userId).eq(Company::getStatus, 1));
|
||||
// if(Objects.isNull(company)){
|
||||
// throw new ServiceException("请先完成招聘企业登记");
|
||||
// }
|
||||
// job.setCompanyId(company.getCompanyId());
|
||||
jobMapper.insert(job);
|
||||
if(job.getJobContactList()!=null){
|
||||
job.getJobContactList().forEach(it->{
|
||||
it.setJobId(job.getJobId());
|
||||
});
|
||||
jobContactMapper.batchInsert(job.getJobContactList());
|
||||
}
|
||||
iesJobSearchService.updateJob(job.getJobId());
|
||||
}
|
||||
}
|
||||
|
@@ -0,0 +1,48 @@
|
||||
package com.ruoyi.cms.service.impl;
|
||||
|
||||
import com.ruoyi.cms.domain.SensitiveWordData;
|
||||
import com.ruoyi.cms.mapper.SensitiveWordDataMapper;
|
||||
import com.ruoyi.cms.service.SensitiveWordDataService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@Service
|
||||
public class SensitiveWordDataServiceImpl implements SensitiveWordDataService {
|
||||
|
||||
@Autowired
|
||||
SensitiveWordDataMapper sensitiveWordDataMapper;
|
||||
|
||||
@Override
|
||||
public List<SensitiveWordData> selectSensitiveworddataList(SensitiveWordData sensitiveworddata) {
|
||||
return sensitiveWordDataMapper.selectSensitiveworddataList(sensitiveworddata);
|
||||
}
|
||||
|
||||
@Override
|
||||
public SensitiveWordData selectById(Long id) {
|
||||
return sensitiveWordDataMapper.selectById(id);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int insertSensitiveworddata(SensitiveWordData sensitiveWordData) {
|
||||
return sensitiveWordDataMapper.insert(sensitiveWordData);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int updateSensitiveworddata(SensitiveWordData sensitiveWordData) {
|
||||
return sensitiveWordDataMapper.updateById(sensitiveWordData);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int deleteSensitiveworddataIds(Long[] ids) {
|
||||
return sensitiveWordDataMapper.deleteBatchIds(Arrays.asList(ids));
|
||||
}
|
||||
|
||||
@Override
|
||||
public int batchInsert(List<SensitiveWordData> list) {
|
||||
return sensitiveWordDataMapper.batchInsert(list);
|
||||
}
|
||||
}
|
@@ -457,4 +457,98 @@ public class StaticsqueryServiceImpl extends ServiceImpl<StaticsMapper, Statics>
|
||||
}
|
||||
|
||||
|
||||
public void educationSalaryGen() {
|
||||
// 定义岗位分类
|
||||
String[] jobCategories = {
|
||||
"初中及以下",
|
||||
"中专/中技",
|
||||
"高中",
|
||||
"大专",
|
||||
"本科",
|
||||
"硕士",
|
||||
"博士",
|
||||
"MBA/EMBA",
|
||||
"留学-学士",
|
||||
"留学-硕士",
|
||||
"留学-博士",
|
||||
"不限"
|
||||
};
|
||||
//薪资类型
|
||||
String[] salarys = {
|
||||
"3k-5k",
|
||||
"5k-8k",
|
||||
"10k-15K",
|
||||
"15k-20k",
|
||||
"20k+"
|
||||
};
|
||||
|
||||
// 定义时间周期
|
||||
String[] timePeriods = {
|
||||
"2025-01", "2025-02", "2025-03", "2025-04", "2025-05",
|
||||
"2024-11", "2024-12"
|
||||
};
|
||||
|
||||
// 所有支持的类型
|
||||
Map<String, List<String>> typeMap = new HashMap<>();
|
||||
typeMap.put("month", Arrays.asList(
|
||||
"分学历/分薪资/月/岗位发布数量"
|
||||
));
|
||||
|
||||
|
||||
for (String time : timePeriods) {
|
||||
String granularity;
|
||||
|
||||
// 判断时间粒度:月、季度、年
|
||||
if (time.matches("\\d{4}-\\d{2}")) {
|
||||
granularity = "month"; // 如 "2025-01"
|
||||
} else if (time.matches("\\d{4}-第[一二三四]季度")) {
|
||||
granularity = "quarter"; // 如 "2024-第一季度"
|
||||
} else if (time.matches("\\d{4}")) {
|
||||
granularity = "year"; // 如 "2025"
|
||||
} else {
|
||||
continue; // 非法格式跳过
|
||||
}
|
||||
|
||||
List<String> applicableTypes = typeMap.get(granularity);
|
||||
|
||||
for (String type : applicableTypes) {
|
||||
for (String category : jobCategories) {
|
||||
for(String salary:salarys){
|
||||
Statics stat = new Statics();
|
||||
stat.setTime(time);
|
||||
stat.setType(type);
|
||||
stat.setName(category+"/"+salary);
|
||||
|
||||
// 设置数据值
|
||||
if (type.contains("岗位发布数量")) {
|
||||
int baseValue = 1000;
|
||||
if (granularity.equals("quarter")) baseValue = 300;
|
||||
if (granularity.equals("year")) baseValue = 1200;
|
||||
|
||||
int variation = (int)(baseValue * 0.2 * (Math.random() - 0.5));
|
||||
stat.setData(String.valueOf(baseValue + variation));
|
||||
} else {
|
||||
double baseRate = 0.05;
|
||||
double variation = 0.01 * (Math.random() - 0.5);
|
||||
stat.setData(String.format("%.2f", baseRate + variation));
|
||||
}
|
||||
|
||||
stat.setDelFlag("0");
|
||||
staticsMapper.insert(stat);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<String, Object> educationSalary(Staticsquery staticsquery) {
|
||||
HashMap<String, Object> result = new HashMap<>();
|
||||
List<String> query = staticsquery.generateTimeRange();
|
||||
for (String time : query) {
|
||||
List<Statics> statics = staticsMapper.selectList(Wrappers.<Statics>lambdaQuery().eq(Statics::getType, "分学历/分薪资/" + staticsquery.getTimeDimension()+"/"+staticsquery.getType()).eq(Statics::getTime, time));
|
||||
result.put(time, statics);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
}
|
||||
|
@@ -0,0 +1,42 @@
|
||||
package com.ruoyi.cms.service.impl;
|
||||
|
||||
import com.ruoyi.common.core.domain.entity.UserWorkExperiences;
|
||||
import com.ruoyi.cms.mapper.UserWorkExperiencesMapper;
|
||||
import com.ruoyi.cms.service.UserWorkExperiencesService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@Service
|
||||
public class UserWorkExperiencesServiceImpl implements UserWorkExperiencesService {
|
||||
|
||||
@Autowired
|
||||
UserWorkExperiencesMapper userWorkExperiencesMapper;
|
||||
|
||||
public List<UserWorkExperiences> getWorkExperiencesList(UserWorkExperiences userWorkExperiences){
|
||||
return userWorkExperiencesMapper.getWorkExperiencesList(userWorkExperiences);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int insertWorkExperiences(UserWorkExperiences userWorkExperiences) {
|
||||
return userWorkExperiencesMapper.insert(userWorkExperiences);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int updateWorkExperiencesById(UserWorkExperiences userWorkExperiences) {
|
||||
return userWorkExperiencesMapper.updateById(userWorkExperiences);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int deleteWorkExperiencesIds(Long[] ids) {
|
||||
return userWorkExperiencesMapper.deleteBatchIds(Arrays.asList(ids));
|
||||
}
|
||||
|
||||
@Override
|
||||
public UserWorkExperiences getWorkExperiencesById(Long id) {
|
||||
return userWorkExperiencesMapper.selectById(id);
|
||||
}
|
||||
}
|
@@ -0,0 +1,198 @@
|
||||
package com.ruoyi.cms.util;
|
||||
|
||||
import com.alibaba.excel.EasyExcel;
|
||||
import com.alibaba.excel.context.AnalysisContext;
|
||||
import com.alibaba.excel.event.AnalysisEventListener;
|
||||
import com.alibaba.excel.write.builder.ExcelWriterSheetBuilder;
|
||||
import com.alibaba.excel.write.metadata.style.WriteCellStyle;
|
||||
import com.alibaba.excel.write.metadata.style.WriteFont;
|
||||
import com.alibaba.excel.write.style.HorizontalCellStyleStrategy;
|
||||
import org.apache.poi.ss.usermodel.HorizontalAlignment;
|
||||
import org.apache.poi.ss.usermodel.VerticalAlignment;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.io.*;
|
||||
import java.net.URLEncoder;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Objects;
|
||||
import java.util.function.Consumer;
|
||||
|
||||
/**
|
||||
* EasyExcel 工具类(基于 alibaba easyexcel 3.x+)
|
||||
*/
|
||||
public class EasyExcelUtils {
|
||||
|
||||
/**
|
||||
* 读取 Excel 文件(一次性读取所有数据)
|
||||
*
|
||||
* @param file 上传的 Excel 文件
|
||||
* @param head 实体类字节码(需使用 @ExcelProperty 注解映射表头)
|
||||
* @param <T> 实体类泛型
|
||||
* @return 解析后的数据集
|
||||
*/
|
||||
public static <T> List<T> readExcel(File file, Class<T> head) {
|
||||
return EasyExcel.read(file)
|
||||
.head(head)
|
||||
.sheet()
|
||||
.doReadSync();
|
||||
}
|
||||
|
||||
/**
|
||||
* 读取 Excel 输入流(一次性读取所有数据)
|
||||
*
|
||||
* @param inputStream Excel 输入流(如 MultipartFile 的 getInputStream())
|
||||
* @param head 实体类字节码
|
||||
* @param <T> 实体类泛型
|
||||
* @return 解析后的数据集
|
||||
*/
|
||||
public static <T> List<T> readExcel(InputStream inputStream, Class<T> head) {
|
||||
return EasyExcel.read(inputStream)
|
||||
.head(head)
|
||||
.sheet()
|
||||
.doReadSync();
|
||||
}
|
||||
|
||||
/**
|
||||
* 分批读取 Excel(适用于大数据量,避免内存溢出)
|
||||
*
|
||||
* @param inputStream Excel 输入流
|
||||
* @param head 实体类字节码
|
||||
* @param batchSize 每批处理的数据量
|
||||
* @param consumer 数据处理函数(如批量保存到数据库)
|
||||
* @param <T> 实体类泛型
|
||||
*/
|
||||
public static <T> void readExcelByBatch(InputStream inputStream, Class<T> head, int batchSize, Consumer<List<T>> consumer) {
|
||||
EasyExcel.read(inputStream)
|
||||
.head(head)
|
||||
.sheet()
|
||||
.registerReadListener(new AnalysisEventListener<T>() {
|
||||
private List<T> batchList; // 临时存储批数据
|
||||
|
||||
@Override
|
||||
public void invoke(T data, AnalysisContext context) {
|
||||
if (batchList == null) {
|
||||
batchList = new java.util.ArrayList<>(batchSize);
|
||||
}
|
||||
batchList.add(data);
|
||||
// 达到批处理量时执行消费逻辑
|
||||
if (batchList.size() >= batchSize) {
|
||||
consumer.accept(batchList);
|
||||
batchList.clear(); // 清空集合,释放内存
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void doAfterAllAnalysed(AnalysisContext context) {
|
||||
// 处理剩余不足一批的数据
|
||||
if (batchList != null && !batchList.isEmpty()) {
|
||||
consumer.accept(batchList);
|
||||
}
|
||||
}
|
||||
})
|
||||
.doRead();
|
||||
}
|
||||
|
||||
/**
|
||||
* 生成 Excel 并写入到输出流(通用样式)
|
||||
*
|
||||
* @param outputStream 输出流(如 HttpServletResponse 的 getOutputStream())
|
||||
* @param data 数据集
|
||||
* @param head 实体类字节码
|
||||
* @param sheetName 工作表名称
|
||||
* @param <T> 实体类泛型
|
||||
*/
|
||||
public static <T> void writeExcel(OutputStream outputStream, List<T> data, Class<T> head, String sheetName) {
|
||||
// 构建通用样式策略(表头居中加粗,内容居中)
|
||||
HorizontalCellStyleStrategy styleStrategy = getDefaultStyleStrategy();
|
||||
|
||||
ExcelWriterSheetBuilder writerBuilder = EasyExcel.write(outputStream, head)
|
||||
.sheet(sheetName)
|
||||
.registerWriteHandler(styleStrategy);
|
||||
|
||||
writerBuilder.doWrite(data);
|
||||
}
|
||||
|
||||
/**
|
||||
* 生成 Excel 并通过 HttpServletResponse 下载(前端直接触发下载)
|
||||
*
|
||||
* @param response HttpServletResponse
|
||||
* @param data 数据集
|
||||
* @param head 实体类字节码
|
||||
* @param sheetName 工作表名称
|
||||
* @param fileName 下载的文件名(不带后缀)
|
||||
* @param <T> 实体类泛型
|
||||
* @throws IOException IO异常
|
||||
*/
|
||||
public static <T> void downloadExcel(HttpServletResponse response, List<T> data, Class<T> head,
|
||||
String sheetName, String fileName) throws IOException {
|
||||
// 设置响应头,触发前端下载
|
||||
response.setContentType("application/vnd.openxmlformats-officedocument.spreadsheetml.sheet");
|
||||
response.setCharacterEncoding("UTF-8");
|
||||
// 文件名编码,避免中文乱码
|
||||
String encodedFileName = URLEncoder.encode(fileName, "UTF-8").replaceAll("\\+", "%20");
|
||||
response.setHeader("Content-disposition", "attachment;filename*=UTF-8''" + encodedFileName + ".xlsx");
|
||||
|
||||
// 写入数据到响应流
|
||||
writeExcel(response.getOutputStream(), data, head, sheetName);
|
||||
}
|
||||
|
||||
/**
|
||||
* 填充 Excel 模板(适用于带固定格式的模板文件)
|
||||
*
|
||||
* @param templateInputStream 模板文件输入流
|
||||
* @param outputStream 输出流(如响应流或文件流)
|
||||
* @param dataMap 填充数据(key为模板中的占位符,value为填充值)
|
||||
* @param sheetName 工作表名称
|
||||
*/
|
||||
public static void fillTemplate(InputStream templateInputStream, OutputStream outputStream,
|
||||
Map<String, Object> dataMap, String sheetName) {
|
||||
EasyExcel.write(outputStream)
|
||||
.withTemplate(templateInputStream)
|
||||
.sheet(sheetName)
|
||||
.doFill(dataMap);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取默认单元格样式策略(表头加粗居中,内容居中)
|
||||
*/
|
||||
private static HorizontalCellStyleStrategy getDefaultStyleStrategy() {
|
||||
// 表头样式
|
||||
WriteCellStyle headStyle = new WriteCellStyle();
|
||||
WriteFont headFont = new WriteFont();
|
||||
headFont.setBold(true); // 加粗
|
||||
headFont.setFontHeightInPoints((short) 11);
|
||||
headStyle.setWriteFont(headFont);
|
||||
headStyle.setHorizontalAlignment(HorizontalAlignment.CENTER); // 水平居中
|
||||
headStyle.setVerticalAlignment(VerticalAlignment.CENTER); // 垂直居中
|
||||
|
||||
// 内容样式
|
||||
WriteCellStyle contentStyle = new WriteCellStyle();
|
||||
WriteFont contentFont = new WriteFont();
|
||||
contentFont.setFontHeightInPoints((short) 11);
|
||||
contentStyle.setWriteFont(contentFont);
|
||||
contentStyle.setHorizontalAlignment(HorizontalAlignment.CENTER);
|
||||
contentStyle.setVerticalAlignment(VerticalAlignment.CENTER);
|
||||
|
||||
// 返回样式策略
|
||||
return new HorizontalCellStyleStrategy(headStyle, contentStyle);
|
||||
}
|
||||
|
||||
/**
|
||||
* 关闭流(工具类内部使用)
|
||||
*/
|
||||
private static void closeStream(Closeable... closeables) {
|
||||
if (closeables != null) {
|
||||
for (Closeable closeable : closeables) {
|
||||
if (Objects.nonNull(closeable)) {
|
||||
try {
|
||||
closeable.close();
|
||||
} catch (IOException e) {
|
||||
// 日志记录(建议替换为实际项目的日志框架)
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@@ -58,4 +58,16 @@ public class StringUtil {
|
||||
.map(String::trim) // 去除每个部分的前后空格
|
||||
.collect(Collectors.toList()); // 收集为List
|
||||
}
|
||||
|
||||
/**
|
||||
* 脱敏逻辑:前4位 + ***+ 后4位
|
||||
* @param idCard
|
||||
* @return
|
||||
*/
|
||||
public static String desensitizeIdCard(String idCard) {
|
||||
if (idCard == null || idCard.length() != 18) {
|
||||
return idCard; // 非标准身份证号不脱敏(或按规则处理)
|
||||
}
|
||||
return idCard.substring(0, 4) + "***" + idCard.substring(14);
|
||||
}
|
||||
}
|
||||
|
@@ -11,10 +11,14 @@ import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.commons.io.FileUtils;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
import javax.crypto.Cipher;
|
||||
import javax.crypto.spec.IvParameterSpec;
|
||||
import javax.crypto.spec.SecretKeySpec;
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.nio.charset.StandardCharsets;
|
||||
import java.security.MessageDigest;
|
||||
import java.util.Base64;
|
||||
import java.util.Formatter;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
@@ -24,8 +28,8 @@ public class WechatUtil {
|
||||
/**
|
||||
* 生成signature
|
||||
**/
|
||||
private static String appid = "wx7cab1155e849fe18";
|
||||
private static String secret = "0263f34d422d24588d6c2df8f09500ab";
|
||||
private static String appid = "wx9d1cbc11c8c40ba7";
|
||||
private static String secret = "38e87cf6251945446e8ac091a0ba9ab2";
|
||||
public AppWechatEntity sign(String url) {
|
||||
Map<String, String> ret = new HashMap();
|
||||
String nonceStr = create_nonce_str();
|
||||
@@ -168,6 +172,7 @@ public class WechatUtil {
|
||||
private String getAccessTokenData(String url) {
|
||||
String str = "";
|
||||
String result = HttpUtil.get(url, CharsetUtil.CHARSET_UTF_8);
|
||||
System.out.println("result=============="+result);
|
||||
if (StringUtils.isEmpty(result))
|
||||
return str;
|
||||
str = parseData("access_token", "expires_in", result);
|
||||
@@ -200,6 +205,20 @@ public class WechatUtil {
|
||||
return tokenConent;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取appid和session_key
|
||||
* @param url
|
||||
* @return
|
||||
*/
|
||||
private String getAccessData(String url) {
|
||||
String str = "";
|
||||
String result = HttpUtil.get(url, CharsetUtil.CHARSET_UTF_8);
|
||||
System.out.println("result=============="+result);
|
||||
if (StringUtils.isEmpty(result))
|
||||
return str;
|
||||
return result;
|
||||
}
|
||||
|
||||
private String byteToHex(final byte[] hash) {
|
||||
Formatter formatter = new Formatter();
|
||||
for (byte b : hash) {
|
||||
@@ -210,6 +229,69 @@ public class WechatUtil {
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过code获取微信用户的openid和session_key
|
||||
*
|
||||
* @param code 登录凭证code
|
||||
* @return 包含openid、session_key、unionid的JSON对象
|
||||
*/
|
||||
public JSONObject code2Session(String code) {
|
||||
try {
|
||||
System.out.println("appid==============="+appid);
|
||||
System.out.println("secret================"+secret);
|
||||
String response = getAccessData("https://api.weixin.qq.com/sns/jscode2session?appid="+appid+"&secret="+secret+"&js_code="+code+"&grant_type=authorization_code");
|
||||
JSONObject result = JSONObject.parseObject(response);
|
||||
// 微信返回错误码处理
|
||||
if (result.containsKey("errcode") && result.getInteger("errcode") != 0) {
|
||||
throw new RuntimeException("微信授权失败:" + result.getString("errmsg"));
|
||||
}
|
||||
return result;
|
||||
} catch (Exception e) {
|
||||
throw new RuntimeException("调用微信接口失败:" + e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 解密微信用户手机号(用户通过 getPhoneNumber 组件授权后返回的加密数据)
|
||||
* @param encryptedData 微信返回的加密手机号数据
|
||||
* @param sessionKey 从 code2Session 接口获取的会话密钥
|
||||
* @param iv 微信返回的加密向量(与 encryptedData 配套)
|
||||
* @return 解密后的 JSON 对象(包含 phoneNumber、purePhoneNumber 等字段)
|
||||
* @throws RuntimeException 解密失败时抛出
|
||||
*/
|
||||
public JSONObject decryptPhoneNumber(String encryptedData, String sessionKey, String iv) {
|
||||
try {
|
||||
// 1. Base64 解码(encryptedData、sessionKey、iv 均为 Base64 编码)
|
||||
byte[] encryptedDataBytes = Base64.getDecoder().decode(encryptedData);
|
||||
byte[] sessionKeyBytes = Base64.getDecoder().decode(sessionKey);
|
||||
byte[] ivBytes = Base64.getDecoder().decode(iv);
|
||||
|
||||
// 2. 验证session_key长度(AES-128要求密钥长度为16字节)
|
||||
if (sessionKeyBytes.length != 16) {
|
||||
throw new RuntimeException("session_key长度错误,应为16字节");
|
||||
}
|
||||
// 验证iv长度(CBC模式下iv长度必须与块大小一致,AES为16字节)
|
||||
if (ivBytes.length != 16) {
|
||||
throw new RuntimeException("iv长度错误,应为16字节");
|
||||
}
|
||||
|
||||
// 2. 初始化 AES-128-CBC 解密器(使用PKCS5Padding替换PKCS7Padding,两者在AES中效果一致)
|
||||
Cipher cipher = Cipher.getInstance("AES/CBC/PKCS5Padding");
|
||||
SecretKeySpec keySpec = new SecretKeySpec(sessionKeyBytes, "AES");
|
||||
IvParameterSpec ivSpec = new IvParameterSpec(ivBytes);
|
||||
cipher.init(Cipher.DECRYPT_MODE, keySpec, ivSpec);
|
||||
|
||||
// 3. 执行解密并转换为字符串
|
||||
byte[] decryptedBytes = cipher.doFinal(encryptedDataBytes);
|
||||
String decryptedStr = new String(decryptedBytes, StandardCharsets.UTF_8);
|
||||
|
||||
// 4. 解析为 JSON 并返回(包含手机号等信息)
|
||||
return JSONObject.parseObject(decryptedStr);
|
||||
} catch (Exception e) {
|
||||
throw new RuntimeException("解密用户手机号失败:" + e.getMessage(), e);
|
||||
}
|
||||
}
|
||||
|
||||
private String create_nonce_str() {
|
||||
return IdUtil.simpleUUID();
|
||||
}
|
||||
|
@@ -0,0 +1,105 @@
|
||||
package com.ruoyi.cms.util.sensitiveWord;
|
||||
|
||||
import com.ruoyi.cms.domain.SensitiveWordData;
|
||||
import com.ruoyi.cms.mapper.SensitiveWordDataMapper;
|
||||
import com.ruoyi.common.core.redis.RedisCache;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.cache.annotation.CacheEvict;
|
||||
import org.springframework.cache.annotation.Cacheable;
|
||||
import org.springframework.stereotype.Component;
|
||||
import javax.annotation.PostConstruct;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
import java.util.concurrent.TimeUnit;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
@Component
|
||||
public class SensitiveWordChecker {
|
||||
|
||||
@Autowired
|
||||
private SensitiveWordDataMapper sensitiveWordDataMapper;
|
||||
|
||||
@Autowired
|
||||
private SensitiveWordTrie trie; // 注入前缀树
|
||||
// 缓存键常量
|
||||
private static final String SENSITIVE_WORD_CACHE_KEY = "sensitive:words";
|
||||
@Autowired
|
||||
private RedisCache redisCache;
|
||||
|
||||
/**
|
||||
* 项目启动时初始化敏感词库到前缀树
|
||||
*/
|
||||
@PostConstruct
|
||||
public void init() {
|
||||
List<String> sensitiveWords = getSensitiveWordsFromCache();
|
||||
if (sensitiveWords.isEmpty()) {
|
||||
// 缓存未命中,从数据库加载
|
||||
sensitiveWords = loadSensitiveWordsFromDbAndCache();
|
||||
}
|
||||
// 初始化前缀树
|
||||
trie.batchAddWords(sensitiveWords);
|
||||
}
|
||||
|
||||
/**
|
||||
* 检测文本中的敏感词
|
||||
* @param text 待检测文本(如job.getDescription())
|
||||
* @return 敏感词列表(空列表表示无敏感词)
|
||||
*/
|
||||
public List<String> checkSensitiveWords(String text) {
|
||||
return trie.findAllSensitiveWords(text);
|
||||
}
|
||||
|
||||
/**
|
||||
* 从缓存获取敏感词列表
|
||||
*/
|
||||
@Cacheable(value = SENSITIVE_WORD_CACHE_KEY)
|
||||
public List<String> getSensitiveWordsFromCache() {
|
||||
// 从Redis获取
|
||||
Object cachedWords = redisCache.getCacheObject(SENSITIVE_WORD_CACHE_KEY);
|
||||
if (cachedWords instanceof List<?>) {
|
||||
return ((List<?>) cachedWords).stream()
|
||||
.filter(obj -> obj instanceof String)
|
||||
.map(obj -> (String) obj)
|
||||
.collect(Collectors.toList());
|
||||
}
|
||||
return Collections.emptyList();
|
||||
}
|
||||
|
||||
/**
|
||||
* 从数据库加载敏感词并更新缓存
|
||||
*/
|
||||
public List<String> loadSensitiveWordsFromDbAndCache() {
|
||||
List<SensitiveWordData> wordList = sensitiveWordDataMapper.selectSensitiveworddataList(new SensitiveWordData());
|
||||
List<String> sensitiveWords = wordList.stream()
|
||||
.map(SensitiveWordData::getSensitiveWord)
|
||||
.collect(Collectors.toList());
|
||||
// 缓存有效期设置为24小时,可根据实际需求调整
|
||||
redisCache.setCacheObject(SENSITIVE_WORD_CACHE_KEY, sensitiveWords, 24, TimeUnit.HOURS);
|
||||
return sensitiveWords;
|
||||
}
|
||||
|
||||
/**
|
||||
* 敏感词更新时清除缓存(需在敏感词管理服务中调用)
|
||||
*/
|
||||
@CacheEvict(value = SENSITIVE_WORD_CACHE_KEY, allEntries = true)
|
||||
public void clearSensitiveWordCache() {
|
||||
// 清除缓存后可重新加载
|
||||
loadSensitiveWordsFromDbAndCache();
|
||||
// 重新初始化前缀树
|
||||
trie.clear();
|
||||
init();
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增/修改敏感词后更新缓存和前缀树
|
||||
*/
|
||||
public void updateCacheAfterModify() {
|
||||
// 1. 清除旧缓存
|
||||
redisCache.deleteObject(SENSITIVE_WORD_CACHE_KEY);
|
||||
// 2. 从数据库重新加载最新数据并更新缓存
|
||||
List<String> latestWords = loadSensitiveWordsFromDbAndCache();
|
||||
// 3. 重建前缀树
|
||||
trie.clear();
|
||||
trie.batchAddWords(latestWords);
|
||||
}
|
||||
}
|
@@ -0,0 +1,97 @@
|
||||
package com.ruoyi.cms.util.sensitiveWord;
|
||||
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
import java.util.*;
|
||||
|
||||
/**
|
||||
* 前缀树(Trie树)节点
|
||||
*/
|
||||
|
||||
|
||||
/**
|
||||
* 前缀树(Trie树)工具类
|
||||
*/
|
||||
@Component
|
||||
public class SensitiveWordTrie {
|
||||
// 根节点(无实际字符)
|
||||
private final TrieNode root = new TrieNode();
|
||||
|
||||
/**
|
||||
* 向前缀树中添加敏感词
|
||||
*/
|
||||
public void addWord(String word) {
|
||||
if (word == null || word.isEmpty()) {
|
||||
return;
|
||||
}
|
||||
TrieNode current = root;
|
||||
for (char c : word.toCharArray()) {
|
||||
// 若子节点中不存在该字符,则创建新节点
|
||||
current.getChildren().putIfAbsent(c, new TrieNode());
|
||||
// 移动到子节点
|
||||
current = current.getChildren().get(c);
|
||||
}
|
||||
// 标记当前节点为敏感词结尾
|
||||
current.setEnd(true);
|
||||
}
|
||||
|
||||
/**
|
||||
* 检测文本中所有敏感词(去重)
|
||||
* @param text 待检测文本
|
||||
* @return 敏感词列表
|
||||
*/
|
||||
public List<String> findAllSensitiveWords(String text) {
|
||||
if (text == null || text.isEmpty()) {
|
||||
return new ArrayList<>();
|
||||
}
|
||||
|
||||
Set<String> sensitiveWords = new HashSet<>();
|
||||
TrieNode current = root;
|
||||
StringBuilder currentWord = new StringBuilder(); // 记录当前匹配的字符
|
||||
|
||||
for (int i = 0; i < text.length(); i++) {
|
||||
char c = text.charAt(i);
|
||||
|
||||
// 若当前字符不在子节点中,重置匹配状态
|
||||
if (!current.getChildren().containsKey(c)) {
|
||||
current = root; // 回到根节点
|
||||
currentWord.setLength(0); // 清空当前匹配的字符
|
||||
continue;
|
||||
}
|
||||
|
||||
// 匹配到字符,移动到子节点
|
||||
current = current.getChildren().get(c);
|
||||
currentWord.append(c);
|
||||
|
||||
// 若当前节点是敏感词结尾,记录该敏感词
|
||||
if (current.isEnd()) {
|
||||
sensitiveWords.add(currentWord.toString());
|
||||
}
|
||||
}
|
||||
|
||||
return new ArrayList<>(sensitiveWords);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量添加敏感词到前缀树
|
||||
* @param words 敏感词列表
|
||||
*/
|
||||
public void batchAddWords(List<String> words) {
|
||||
if (words == null || words.isEmpty()) {
|
||||
return;
|
||||
}
|
||||
// 批量处理比循环单次添加更高效,减少重复判断
|
||||
for (String word : words) {
|
||||
addWord(word);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 清空前缀树所有节点
|
||||
*/
|
||||
public void clear() {
|
||||
// 清空根节点的子节点映射,达到清空整个前缀树的效果
|
||||
root.getChildren().clear();
|
||||
}
|
||||
|
||||
}
|
@@ -0,0 +1,23 @@
|
||||
package com.ruoyi.cms.util.sensitiveWord;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
class TrieNode {
|
||||
// 子节点:key=字符,value=子节点
|
||||
private final Map<Character, TrieNode> children = new HashMap<>();
|
||||
// 标记当前节点是否为敏感词的结尾
|
||||
private boolean isEnd = false;
|
||||
|
||||
public Map<Character, TrieNode> getChildren() {
|
||||
return children;
|
||||
}
|
||||
|
||||
public boolean isEnd() {
|
||||
return isEnd;
|
||||
}
|
||||
|
||||
public void setEnd(boolean end) {
|
||||
isEnd = end;
|
||||
}
|
||||
}
|
@@ -0,0 +1,45 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
|
||||
<mapper namespace="com.ruoyi.cms.mapper.AppSkillMapper">
|
||||
|
||||
<!-- 可根据自己的需求,是否要使用 -->
|
||||
<resultMap type="AppSkill" id="AppSkillResult">
|
||||
<result property="id" column="id"/>
|
||||
<result property="userId" column="user_id"/>
|
||||
<result property="name" column="name"/>
|
||||
<result property="levels" column="levels"/>
|
||||
<result property="delFlag" column="del_flag"/>
|
||||
<result property="createBy" column="create_by"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="updateBy" column="update_by"/>
|
||||
<result property="updateTime" column="update_time"/>
|
||||
<result property="remark" column="remark"/>
|
||||
</resultMap>
|
||||
|
||||
|
||||
<sql id="selectAppSkillVo">
|
||||
select id, user_id, name, levels, del_flag, create_by, create_time, update_by, update_time, remark from app_skill
|
||||
</sql>
|
||||
|
||||
<select id="getList" resultType="AppSkill" resultMap="AppSkillResult">
|
||||
<include refid="selectAppSkillVo"/>
|
||||
<where> del_flag = '0'
|
||||
<if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
|
||||
<if test="levels != null and levels != ''"> and levels = #{levels}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<insert id="batchInsert" parameterType="java.util.List">
|
||||
INSERT INTO app_skill (
|
||||
user_id, name, levels, create_by, create_time, del_flag
|
||||
) VALUES
|
||||
<foreach collection="list" item="item" separator=",">
|
||||
(
|
||||
#{item.userId}, #{item.name}, #{item.levels},
|
||||
#{item.createBy}, #{item.createTime}, #{item.delFlag}
|
||||
)
|
||||
</foreach>
|
||||
</insert>
|
||||
|
||||
</mapper>
|
@@ -28,10 +28,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<result property="remark" column="remark" />
|
||||
<result property="jobTitleId" column="job_title_id" />
|
||||
<result property="isRecommend" column="is_recommend" />
|
||||
<result property="idCard" column="id_card" />
|
||||
<result property="workExperience" column="work_experience" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectAppUserVo">
|
||||
select user_id, name, age, sex, birth_date, education, political_affiliation, phone, avatar, salary_min, salary_max, area, status, del_flag, login_ip, login_date, create_by, create_time, update_by, update_time, remark,job_title_id,is_recommend from app_user
|
||||
select user_id, name, age, sex, birth_date, education, political_affiliation, phone, avatar, salary_min, salary_max, area, status, del_flag, login_ip, login_date, create_by, create_time, update_by, update_time, remark,job_title_id,is_recommend,id_card,work_experience from app_user
|
||||
</sql>
|
||||
|
||||
<select id="selectAppUserList" parameterType="AppUser" resultMap="AppUserResult">
|
||||
@@ -52,12 +54,54 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<if test="loginIp != null and loginIp != ''"> and login_ip = #{loginIp}</if>
|
||||
<if test="loginDate != null "> and login_date = #{loginDate}</if>
|
||||
<if test="experience != null "> and experience = #{experience}</if>
|
||||
<if test="idCard != null and idCard != ''"> and id_card like concat('%', CAST(#{idCard} AS VARCHAR), '%')</if>
|
||||
</where>
|
||||
</select>
|
||||
<select id="selectByJobId" resultType="com.ruoyi.cms.domain.AppUser" parameterType="java.lang.Long">
|
||||
<select id="selectByJobId" resultType="com.ruoyi.common.core.domain.entity.AppUser" parameterType="java.lang.Long">
|
||||
SELECT * FROM app_user WHERE user_id IN (
|
||||
select DISTINCT au.USER_ID from APP_USER au
|
||||
INNER JOIN JOB_APPLY ja ON ja.USER_ID = au.USER_ID
|
||||
WHERE au.DEL_FLAG = '0' AND ja.DEL_FLAG = '0' AND ja.JOB_Id = #{jobId})
|
||||
</select>
|
||||
|
||||
<select id="selectByOpenid" resultType="com.ruoyi.common.core.domain.entity.AppUser">
|
||||
<include refid="selectAppUserVo"/> WHERE DEL_FLAG = '0' and openid=#{openid} LIMIT 1
|
||||
</select>
|
||||
|
||||
<insert id="insertSysUserRole" parameterType="java.util.Map">
|
||||
insert into sys_user_role (user_id,role_id) values (#{userId},#{roleId})
|
||||
</insert>
|
||||
|
||||
<insert id="insertSysUser" parameterType="com.ruoyi.common.core.domain.entity.SysUser" useGeneratedKeys="true" keyProperty="userId">
|
||||
insert into sys_user(
|
||||
<if test="userId != null and userId != 0">user_id,</if>
|
||||
<if test="deptId != null and deptId != 0">dept_id,</if>
|
||||
<if test="userName != null and userName != ''">user_name,</if>
|
||||
<if test="nickName != null and nickName != ''">nick_name,</if>
|
||||
<if test="email != null and email != ''">email,</if>
|
||||
<if test="avatar != null and avatar != ''">avatar,</if>
|
||||
<if test="phonenumber != null and phonenumber != ''">phonenumber,</if>
|
||||
<if test="sex != null and sex != ''">sex,</if>
|
||||
<if test="password != null and password != ''">password,</if>
|
||||
<if test="status != null and status != ''">status,</if>
|
||||
<if test="createBy != null and createBy != ''">create_by,</if>
|
||||
<if test="remark != null and remark != ''">remark,</if>
|
||||
create_time
|
||||
)values(
|
||||
<if test="userId != null and userId != ''">#{userId},</if>
|
||||
<if test="deptId != null and deptId != ''">#{deptId},</if>
|
||||
<if test="userName != null and userName != ''">#{userName},</if>
|
||||
<if test="nickName != null and nickName != ''">#{nickName},</if>
|
||||
<if test="email != null and email != ''">#{email},</if>
|
||||
<if test="avatar != null and avatar != ''">#{avatar},</if>
|
||||
<if test="phonenumber != null and phonenumber != ''">#{phonenumber},</if>
|
||||
<if test="sex != null and sex != ''">#{sex},</if>
|
||||
<if test="password != null and password != ''">#{password},</if>
|
||||
<if test="status != null and status != ''">#{status},</if>
|
||||
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
||||
<if test="remark != null and remark != ''">#{remark},</if>
|
||||
sysdate()
|
||||
)
|
||||
</insert>
|
||||
|
||||
</mapper>
|
@@ -27,7 +27,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<if test="userId != null "> and user_id = #{userId}</if>
|
||||
</where>
|
||||
</select>
|
||||
<select id="collectionJob" resultType="com.ruoyi.cms.domain.Company">
|
||||
<select id="collectionJob" resultType="com.ruoyi.common.core.domain.entity.Company">
|
||||
select *
|
||||
from company
|
||||
where del_flag = '0'
|
||||
|
@@ -0,0 +1,52 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
|
||||
<mapper namespace="com.ruoyi.cms.mapper.CompanyContactMapper">
|
||||
|
||||
<!-- 可根据自己的需求,是否要使用 -->
|
||||
<resultMap type="CompanyContact" id="CompanyContactResult">
|
||||
<result property="id" column="id"/>
|
||||
<result property="companyId" column="company_id"/>
|
||||
<result property="contactPerson" column="contact_person"/>
|
||||
<result property="contactPersonPhone" column="contact_person_phone"/>
|
||||
<result property="delFlag" column="del_flag"/>
|
||||
<result property="createBy" column="create_by"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="updateBy" column="update_by"/>
|
||||
<result property="updateTime" column="update_time"/>
|
||||
<result property="remark" column="remark"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectCompanyContactVo">
|
||||
select id, company_id, contact_person, contact_person_phone, del_flag, create_by, create_time, update_by, update_time, remark from company_contact
|
||||
</sql>
|
||||
|
||||
<select id="getSelectList" resultMap="CompanyContactResult" parameterType="CompanyContact">
|
||||
<include refid="selectCompanyContactVo"/>
|
||||
<where> del_flag = '0'
|
||||
<if test="companyId!=null and companyId!='' ">
|
||||
and company_id=#{companyId}
|
||||
</if>
|
||||
<if test="contactPerson!=null and contactPerson!='' ">
|
||||
and contact_person=#{contactPerson}
|
||||
</if>
|
||||
<if test="contactPersonPhone!=null and contactPersonPhone!='' ">
|
||||
and contact_person_phone=#{contactPersonPhone}
|
||||
</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<insert id="batchInsert" parameterType="java.util.List">
|
||||
INSERT INTO company_contact (
|
||||
company_id, contact_person, contact_person_phone,
|
||||
create_by, create_time, del_flag,remark
|
||||
) VALUES
|
||||
<foreach collection="list" item="item" separator=",">
|
||||
(
|
||||
#{item.companyId}, #{item.contactPerson}, #{item.contactPersonPhone},
|
||||
#{item.createBy}, #{item.createTime}, #{item.delFlag},#{item.remark}
|
||||
)
|
||||
</foreach>
|
||||
</insert>
|
||||
|
||||
</mapper>
|
@@ -29,10 +29,19 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<result property="contactPersonPhone" column="contact_person_phone" />
|
||||
<result property="status" column="status" />
|
||||
<result property="notPassReason" column="not_pass_reason" />
|
||||
<result property="registeredAddress" column="registered_address" />
|
||||
<result property="isAbnormal" column="is_abnormal" />
|
||||
<result property="enterpriseType" column="enterprise_type" />
|
||||
<result property="isImpCompany" column="is_imp_company" />
|
||||
<result property="impCompanyType" column="imp_company_type" />
|
||||
<result property="legalPerson" column="legal_person" />
|
||||
<result property="legalIdCard" column="legal_id_card" />
|
||||
<result property="legalPhone" column="legal_phone" />
|
||||
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectCompanyVo">
|
||||
select company_id, name, location, industry, scale, del_flag, create_by, create_time, update_by, update_time, remark,code,description,nature,total_recruitment from company
|
||||
select company_id, name, location, industry, scale, del_flag, create_by, create_time, update_by, update_time, remark,code,description,nature,total_recruitment,registered_address,contact_person,contact_person_phone,is_abnormal,not_pass_reason,status,case when status='2' then update_time else null end reject_time,is_imp_company,imp_company_type,enterprise_type,legal_person,legal_id_card,legal_phone from company
|
||||
</sql>
|
||||
<insert id="batchInsert" parameterType="java.util.List">
|
||||
INSERT INTO company (
|
||||
@@ -59,12 +68,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<select id="selectCompanyList" parameterType="Company" resultMap="CompanyResult">
|
||||
<include refid="selectCompanyVo"/>
|
||||
<where> del_flag = '0'
|
||||
<if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
|
||||
<if test="name != null and name != ''"> and name like concat('%', cast(#{name, jdbcType=VARCHAR} as varchar), '%')</if>
|
||||
<if test="location != null and location != ''"> and location = #{location}</if>
|
||||
<if test="industry != null and industry != ''"> and industry = #{industry}</if>
|
||||
<if test="scale != null and scale != ''"> and scale = #{scale}</if>
|
||||
<if test="nature != null and nature != ''"> and nature = #{nature}</if>
|
||||
<if test="code != null and code != ''"> and code = #{code}</if>
|
||||
<if test="status != null and status != ''"> and status = #{status}</if>
|
||||
</where>
|
||||
</select>
|
||||
<select id="label" resultMap="CompanyResult">
|
||||
|
@@ -0,0 +1,38 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
|
||||
<mapper namespace="com.ruoyi.cms.mapper.EmployeeConfirmMapper">
|
||||
|
||||
<!-- 可根据自己的需求,是否要使用 -->
|
||||
<resultMap type="EmployeeConfirm" id="EmployeeConfirmResult">
|
||||
<result property="id" column="id"/>
|
||||
<result property="companyId" column="company_id"/>
|
||||
<result property="contactPerson" column="contact_person"/>
|
||||
<result property="idCard" column="id_card"/>
|
||||
<result property="entryDate" column="entry_date"/>
|
||||
<result property="contactPersonPhone" column="contact_person_phone"/>
|
||||
<result property="contractTerm" column="contract_term"/>
|
||||
<result property="delFlag" column="del_flag"/>
|
||||
<result property="createBy" column="create_by"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="updateBy" column="update_by"/>
|
||||
<result property="updateTime" column="update_time"/>
|
||||
<result property="remark" column="remark"/>
|
||||
</resultMap>
|
||||
|
||||
|
||||
<sql id="selectsinosoftVo">
|
||||
select id, company_id, contact_person, id_card, entry_date, contact_person_phone, contract_term, del_flag, create_by, create_time, update_by, update_time, remark from employee_confirm
|
||||
</sql>
|
||||
|
||||
<select id="getEmployeeConfirmList" resultMap="EmployeeConfirmResult" parameterType="EmployeeConfirm">
|
||||
<include refid="selectsinosoftVo"/>
|
||||
<where> del_flag = '0'
|
||||
<if test="contactPerson != null and contactPerson != ''"> and contact_person like concat('%', #{contactPerson}, '%')</if>
|
||||
<if test="idCard != null and idCard != ''"> and id_card = #{idCard}</if>
|
||||
<if test="contactPersonPhone != null and contactPersonPhone != ''"> and contact_person_phone = #{contactPersonPhone}</if>
|
||||
<if test="companyId != null and companyId != ''"> and company_id = #{companyId}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
</mapper>
|
@@ -40,10 +40,65 @@
|
||||
ORDER BY ja.create_time DESC
|
||||
</select>
|
||||
<select id="candidates" resultType="com.ruoyi.cms.domain.vo.CandidateVO">
|
||||
SELECT au.*,jc.create_time as apply_date,jc.matching_degree
|
||||
SELECT au.*,jc.create_time as apply_date,jc.matching_degree,jc.id as applyId
|
||||
from job_apply as jc
|
||||
inner join app_user as au on jc.user_id = au.user_id
|
||||
where jc.job_id = #{jobId} and jc.del_flag = '0' and au.del_flag ='0'
|
||||
</select>
|
||||
|
||||
<select id="trendChart" resultType="java.util.HashMap" parameterType="JobApply">
|
||||
select a.job_title as name,count(b.job_id) sl from job a left join job_apply b
|
||||
on a.job_id=b.job_id where a.del_flag='0' and b.del_flag='0'
|
||||
<if test="jobId!=null and jobId!=''">
|
||||
and a.job_id=#{jobId}
|
||||
</if>
|
||||
group by a.job_title
|
||||
</select>
|
||||
|
||||
<sql id="selectAppUserVo">
|
||||
select user_id, name, age, sex, birth_date, education, political_affiliation, phone, avatar, salary_min, salary_max, area, status, del_flag, login_ip, login_date, create_by, create_time, update_by, update_time, remark,job_title_id,is_recommend,id_card,hire from app_user
|
||||
</sql>
|
||||
|
||||
<select id="selectAppUserList" parameterType="com.ruoyi.cms.domain.Job" resultType="com.ruoyi.cms.domain.vo.CandidateVO">
|
||||
select b.job_title jobName,l.name companyName,e.* from job_apply a
|
||||
INNER join job b on a.job_id=b.job_id and b.del_flag='0'
|
||||
INNER join app_user e on a.user_id =e.user_id and e.del_flag='0'
|
||||
INNER join company l on b.company_id =l.company_id and l.del_flag='0'
|
||||
where a.del_flag='0' and a.hire='0'
|
||||
<if test="jobTitle != null and jobTitle != ''"> and b.job_title like concat('%', cast(#{jobTitle, jdbcType=VARCHAR} as varchar), '%')</if>
|
||||
<if test="education != null and education != ''"> and b.education = #{education}</if>
|
||||
<if test="experience != null and experience != ''"> and b.experience = #{experience}</if>
|
||||
<if test="companyName != null and companyName != ''"> and b.company_name like concat('%', cast(#{companyName, jdbcType=VARCHAR} as varchar), '%')</if>
|
||||
<if test="jobLocation != null and jobLocation != ''"> and b.job_location = #{jobLocation}</if>
|
||||
<if test="postingDate != null and postingDate!=''"> and b.posting_date = #{postingDate}</if>
|
||||
<if test="vacancies != null "> and b.vacancies = #{vacancies}</if>
|
||||
<if test="latitude != null "> and b.latitude = #{latitude}</if>
|
||||
<if test="longitude != null "> and b.longitude = #{longitude}</if>
|
||||
<if test="view != null "> and b."view" = #{view}</if>
|
||||
<if test="companyId != null "> and b.company_id = #{companyId}</if>
|
||||
<if test="isHot != null "> and b.is_hot = #{isHot}</if>
|
||||
<if test="applyNum != null "> and b.apply_num = #{applyNum}</if>
|
||||
<if test="code != null "> and b.company_id in(select company_id from company where code=#{code})</if>
|
||||
<if test="compensation!=null ">
|
||||
<if test="compensation==0 ">
|
||||
and b.min_salary < 1750
|
||||
</if>
|
||||
<if test="compensation==1 ">
|
||||
and b.max_salary < 2000 and b.min_salary >= 1750
|
||||
</if>
|
||||
<if test="compensation==2 ">
|
||||
and b.max_salary < 3000 and b.min_salary >= 2000
|
||||
</if>
|
||||
<if test="compensation==3 ">
|
||||
and b.max_salary < 4000 and b.min_salary >= 3000
|
||||
</if>
|
||||
<if test="compensation==4 ">
|
||||
and b.max_salary < 5000 and b.min_salary >= 4000
|
||||
</if>
|
||||
<if test="compensation==5 ">
|
||||
and b.min_salary > 5000
|
||||
</if>
|
||||
</if>
|
||||
</select>
|
||||
|
||||
</mapper>
|
@@ -0,0 +1,58 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
|
||||
<mapper namespace="com.ruoyi.cms.mapper.JobContactMapper">
|
||||
|
||||
<!-- 可根据自己的需求,是否要使用 -->
|
||||
<resultMap type="JobContact" id="jobContactResult">
|
||||
<result property="id" column="id"/>
|
||||
<result property="jobId" column="job_id"/>
|
||||
<result property="contactPerson" column="contact_person"/>
|
||||
<result property="contactPersonPhone" column="contact_person_phone"/>
|
||||
<result property="position" column="position"/>
|
||||
<result property="delFlag" column="del_flag"/>
|
||||
<result property="createBy" column="create_by"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="updateBy" column="update_by"/>
|
||||
<result property="updateTime" column="update_time"/>
|
||||
<result property="remark" column="remark"/>
|
||||
</resultMap>
|
||||
|
||||
|
||||
<sql id="JobContactVo">
|
||||
select id, job_id, contact_person, contact_person_phone, position, del_flag, create_by, create_time, update_by, update_time, remark from job_contact
|
||||
</sql>
|
||||
|
||||
|
||||
<select id="getSelectList" resultMap="jobContactResult" parameterType="JobContact">
|
||||
<include refid="JobContactVo"/>
|
||||
<where> del_flag = '0'
|
||||
<if test="jobId!=null and jobId!='' ">
|
||||
and job_id=#{jobId}
|
||||
</if>
|
||||
<if test="contactPerson!=null and contactPerson!='' ">
|
||||
and contact_person=#{contactPerson}
|
||||
</if>
|
||||
<if test="contactPersonPhone!=null and contactPersonPhone!='' ">
|
||||
and contact_person_phone=#{contactPersonPhone}
|
||||
</if>
|
||||
<if test="position!=null and position!='' ">
|
||||
and position=#{position}
|
||||
</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<insert id="batchInsert" parameterType="java.util.List">
|
||||
INSERT INTO job_contact (
|
||||
job_id, contact_person, contact_person_phone,position,
|
||||
create_by, create_time, del_flag,remark
|
||||
) VALUES
|
||||
<foreach collection="list" item="item" separator=",">
|
||||
(
|
||||
#{item.jobId}, #{item.contactPerson}, #{item.contactPersonPhone},#{item.position},
|
||||
#{item.createBy}, #{item.createTime}, #{item.delFlag},#{item.remark}
|
||||
)
|
||||
</foreach>
|
||||
</insert>
|
||||
|
||||
</mapper>
|
@@ -33,10 +33,11 @@
|
||||
<result property="isExplain" column="is_explain" />
|
||||
<result property="explainUrl" column="explain_url" />
|
||||
<result property="cover" column="cover" />
|
||||
<result property="jobType" column="job_type" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectJobVo">
|
||||
select job_id, job_title, min_salary, max_salary, education, experience, company_name, job_location, posting_date, vacancies, del_flag, create_by, create_time, update_by, update_time, remark, latitude, longitude, "view", company_id , is_hot ,apply_num,is_publish, description,job_location_area_code,data_source,job_url,job_category,is_explain,explain_url,cover from job
|
||||
select job_id, job_title, min_salary, max_salary, education, experience, company_name, job_location, posting_date, vacancies, del_flag, create_by, create_time, update_by, update_time, remark, latitude, longitude, "view", company_id , is_hot ,apply_num,is_publish, description,job_location_area_code,data_source,job_url,job_category,is_explain,explain_url,cover,job_type from job
|
||||
</sql>
|
||||
<insert id="insertBatchRowWork">
|
||||
INSERT INTO row_work (
|
||||
@@ -66,7 +67,7 @@
|
||||
job_title, min_salary, max_salary, education, experience, company_name, job_location,
|
||||
job_location_area_code, posting_date, vacancies, latitude, longitude, "view", company_id,
|
||||
is_hot, apply_num, description, is_publish, data_source, job_url, remark, del_flag,
|
||||
create_by, create_time, row_id, job_category
|
||||
create_by, create_time, row_id, job_category,jobType
|
||||
) VALUES
|
||||
<foreach collection="list" item="job" separator=",">
|
||||
(
|
||||
@@ -75,7 +76,7 @@
|
||||
#{job.vacancies}, #{job.latitude}, #{job.longitude}, #{job.view}, #{job.companyId},
|
||||
#{job.isHot}, #{job.applyNum}, #{job.description}, #{job.isPublish}, #{job.dataSource},
|
||||
#{job.jobUrl}, #{job.remark}, #{job.delFlag}, #{job.createBy}, #{job.createTime},
|
||||
#{job.rowId}, #{job.jobCategory}
|
||||
#{job.rowId}, #{job.jobCategory},#{job.jobType}
|
||||
)
|
||||
</foreach>
|
||||
</insert>
|
||||
@@ -124,7 +125,7 @@
|
||||
<if test="maxSalary != null "> and max_salary = #{maxSalary}</if>
|
||||
<if test="education != null and education != ''"> and education = #{education}</if>
|
||||
<if test="experience != null and experience != ''"> and experience = #{experience}</if>
|
||||
<if test="companyName != null and companyName != ''"> and company_name like concat('%', #{companyName}, '%')</if>
|
||||
<if test="companyName != null and companyName != ''"> and company_name like concat('%', cast(#{companyName, jdbcType=VARCHAR} as varchar), '%')</if>
|
||||
<if test="jobLocation != null and jobLocation != ''"> and job_location = #{jobLocation}</if>
|
||||
<if test="postingDate != null and postingDate!=''"> and posting_date = #{postingDate}</if>
|
||||
<if test="vacancies != null "> and vacancies = #{vacancies}</if>
|
||||
@@ -134,6 +135,27 @@
|
||||
<if test="companyId != null "> and company_id = #{companyId}</if>
|
||||
<if test="isHot != null "> and is_hot = #{isHot}</if>
|
||||
<if test="applyNum != null "> and apply_num = #{applyNum}</if>
|
||||
<if test="code != null "> and company_id in(select company_id from company where code=#{code})</if>
|
||||
<if test="compensation!=null ">
|
||||
<if test="compensation==0 ">
|
||||
and min_salary < 1750
|
||||
</if>
|
||||
<if test="compensation==1 ">
|
||||
and max_salary < 2000 and min_salary >= 1750
|
||||
</if>
|
||||
<if test="compensation==2 ">
|
||||
and max_salary < 3000 and min_salary >= 2000
|
||||
</if>
|
||||
<if test="compensation==3 ">
|
||||
and max_salary < 4000 and min_salary >= 3000
|
||||
</if>
|
||||
<if test="compensation==4 ">
|
||||
and max_salary < 5000 and min_salary >= 4000
|
||||
</if>
|
||||
<if test="compensation==5 ">
|
||||
and min_salary > 5000
|
||||
</if>
|
||||
</if>
|
||||
</where>
|
||||
order by is_explain desc
|
||||
</select>
|
||||
@@ -145,7 +167,7 @@
|
||||
<if test="maxSalary != null "> and max_salary = #{maxSalary}</if>
|
||||
<if test="education != null and education != ''"> and education = #{education}</if>
|
||||
<if test="experience != null and experience != ''"> and experience = #{experience}</if>
|
||||
<if test="companyName != null and companyName != ''"> and company_name like concat('%', #{companyName}, '%')</if>
|
||||
<if test="companyName != null and companyName != ''"> and company_name like concat('%', cast(#{companyName, jdbcType=VARCHAR} as varchar), '%')</if>
|
||||
<if test="jobLocation != null and jobLocation != ''"> and job_location = #{jobLocation}</if>
|
||||
<if test="postingDate != null and postingDate!='' "> and posting_date = #{postingDate}</if>
|
||||
<if test="vacancies != null "> and vacancies = #{vacancies}</if>
|
||||
@@ -172,17 +194,25 @@
|
||||
Collect_time, ClearFlag, Province, City, County, importdate, YearMonth,
|
||||
IsRepeat, latitude, longitude,Std_class as JobCategory from row_work
|
||||
</select>
|
||||
<select id="selectRowCompany" resultType="com.ruoyi.cms.domain.Company">
|
||||
<select id="selectRowCompany" resultType="com.ruoyi.common.core.domain.entity.Company">
|
||||
SELECT *
|
||||
FROM (select AAB004 AS name,ANY_VALUE(AAE006) AS location,ANY_VALUE(IndustryType)
|
||||
as remark,ANY_VALUE(IndustrySub) as industry,ANY_VALUE(Num_OK) as scale,ANY_VALUE(AAB092) as description,ANY_VALUE(AAB019_OK) as nature from row_work
|
||||
group by AAB004
|
||||
)AS b
|
||||
where not exists (
|
||||
select 1
|
||||
from company
|
||||
where b.name = company.name
|
||||
)
|
||||
FROM (
|
||||
SELECT
|
||||
AAB004 AS name,
|
||||
MIN(AAE006) AS location,
|
||||
MIN(IndustryType) as remark,
|
||||
MIN(IndustrySub) as industry,
|
||||
MIN(Num_OK) as scale,
|
||||
MIN(AAB092) as description,
|
||||
MIN(AAB019_OK) as nature
|
||||
FROM row_work
|
||||
GROUP BY AAB004
|
||||
) AS b
|
||||
WHERE NOT EXISTS (
|
||||
SELECT 1
|
||||
FROM company
|
||||
WHERE b.name = company.name
|
||||
)
|
||||
</select>
|
||||
<select id="selectAllJob" resultType="com.ruoyi.cms.domain.Job">
|
||||
SELECT j.*,c.industry,c.scale,c.nature as company_nature FROM job as j
|
||||
|
@@ -0,0 +1,40 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
|
||||
<mapper namespace="com.ruoyi.cms.mapper.SensitiveWordDataMapper">
|
||||
|
||||
<!-- 可根据自己的需求,是否要使用 -->
|
||||
<resultMap type="SensitiveWordData" id="sensitiveWordDataResult">
|
||||
<result property="id" column="id"/>
|
||||
<result property="sensitiveWord" column="sensitive_word"/>
|
||||
<result property="type" column="type"/>
|
||||
<result property="delFlag" column="del_flag"/>
|
||||
<result property="createBy" column="create_by"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="updateBy" column="update_by"/>
|
||||
<result property="updateTime" column="update_time"/>
|
||||
<result property="remark" column="remark"/>
|
||||
</resultMap>
|
||||
|
||||
|
||||
<sql id="sensitiveWordDataVo">
|
||||
select id, sensitive_word, type, del_flag, create_by, create_time, update_by, update_time, remark from sensitive_word_data
|
||||
</sql>
|
||||
|
||||
<select id="selectSensitiveworddataList" resultMap="sensitiveWordDataResult" parameterType="SensitiveWordData">
|
||||
<include refid="sensitiveWordDataVo"/>
|
||||
<where> del_flag = '0'
|
||||
<if test="sensitiveWord != null and sensitiveWord != ''"> and sensitive_word like concat('%', #{sensitiveWord}, '%')</if>
|
||||
<if test="type != null and type != ''"> and type = #{type}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<insert id="batchInsert" parameterType="java.util.List">
|
||||
INSERT INTO sensitive_word_data (sensitive_word, type, create_time,create_by,del_flag,remark)
|
||||
VALUES
|
||||
<foreach collection="list" item="item" separator=",">
|
||||
(#{item.sensitiveWord}, #{item.type}, #{item.createTime},#{item.createBy},#{item.delFlag},#{item.remark})
|
||||
</foreach>
|
||||
</insert>
|
||||
|
||||
</mapper>
|
@@ -0,0 +1,51 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
|
||||
<mapper namespace="com.ruoyi.cms.mapper.UserWorkExperiencesMapper">
|
||||
|
||||
<!-- 可根据自己的需求,是否要使用 -->
|
||||
<resultMap type="userWorkExperiences" id="userWorkExperiencesResult">
|
||||
<result property="id" column="id"/>
|
||||
<result property="companyName" column="company_name"/>
|
||||
<result property="position" column="position"/>
|
||||
<result property="userId" column="user_id"/>
|
||||
<result property="startDate" column="start_date"/>
|
||||
<result property="endDate" column="end_date"/>
|
||||
<result property="description" column="description"/>
|
||||
<result property="delFlag" column="del_flag"/>
|
||||
<result property="createBy" column="create_by"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="updateBy" column="update_by"/>
|
||||
<result property="updateTime" column="update_time"/>
|
||||
<result property="remark" column="remark"/>
|
||||
</resultMap>
|
||||
|
||||
|
||||
<sql id="selectWorkExperiencesVo">
|
||||
select id, company_name, position, user_id, start_date, end_date, description, del_flag, create_by, create_time, update_by, update_time, remark from user_work_experiences
|
||||
</sql>
|
||||
|
||||
<select id="getWorkExperiencesList" resultMap="userWorkExperiencesResult" parameterType="userWorkExperiences">
|
||||
<include refid="selectWorkExperiencesVo"/>
|
||||
<where> del_flag = '0'
|
||||
<if test="companyName != null and companyName != ''"> and company_name like concat('%', #{companyName}, '%')</if>
|
||||
<if test="position != null and position != ''"> and position = #{position}</if>
|
||||
<if test="description != null and description != ''"> and description = #{description}</if>
|
||||
<if test="userId != null and userId != ''"> and user_id = #{userId}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<insert id="batchInsert" parameterType="java.util.List">
|
||||
INSERT INTO user_work_experiences (
|
||||
company_name, position, user_id, start_date, end_date, description,
|
||||
create_by, create_time, del_flag,remark
|
||||
) VALUES
|
||||
<foreach collection="list" item="item" separator=",">
|
||||
(
|
||||
#{item.companyName}, #{item.position}, #{item.userId},#{item.startDate},#{item.endDate},
|
||||
#{item.description},#{item.createBy}, #{item.createTime}, #{item.delFlag},#{item.remark}
|
||||
)
|
||||
</foreach>
|
||||
</insert>
|
||||
|
||||
</mapper>
|
@@ -2,7 +2,7 @@ package com.ruoyi.common.constant;
|
||||
|
||||
/**
|
||||
* 缓存的key 常量
|
||||
*
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public class CacheConstants
|
||||
@@ -11,11 +11,12 @@ public class CacheConstants
|
||||
* 登录用户 redis key
|
||||
*/
|
||||
public static final String LOGIN_TOKEN_KEY = "login_tokens:";
|
||||
|
||||
public static final String SITE_LOGIN_TOKEN_KEY = "site_login_tokens:";
|
||||
/**
|
||||
* 验证码 redis key
|
||||
*/
|
||||
public static final String CAPTCHA_CODE_KEY = "captcha_codes:";
|
||||
public static final String SMG_CODE_KEY = "smg_codes:";
|
||||
|
||||
/**
|
||||
* 参数管理 cache key
|
||||
@@ -42,4 +43,5 @@ public class CacheConstants
|
||||
* 登录账户密码错误次数 redis key
|
||||
*/
|
||||
public static final String PWD_ERR_CNT_KEY = "pwd_err_cnt:";
|
||||
public static final String PWD_ERR_CNT_KEY_SITE = "site:pwd_err_cnt:";
|
||||
}
|
||||
|
@@ -5,7 +5,7 @@ import io.jsonwebtoken.Claims;
|
||||
|
||||
/**
|
||||
* 通用常量信息
|
||||
*
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public class Constants
|
||||
@@ -109,6 +109,10 @@ public class Constants
|
||||
* 令牌前缀
|
||||
*/
|
||||
public static final String LOGIN_USER_KEY = "login_user_key";
|
||||
public static final String APP_LOGIN_USER_KEY = "app_login_user_key";
|
||||
public static final String LOGIN_USER_ID = "login_user_id";
|
||||
public static final String APP_LOGIN_USER_ID = "login_user_id";
|
||||
public static final String EXP = "exp";
|
||||
|
||||
/**
|
||||
* 用户ID
|
||||
|
@@ -50,7 +50,7 @@ public class BaseEntity implements Serializable
|
||||
/** 更新时间 */
|
||||
// @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@TableField(fill = FieldFill.INSERT_UPDATE)
|
||||
@JsonIgnore
|
||||
// @JsonIgnore
|
||||
@ApiModelProperty(hidden = true)
|
||||
private String updateTime;
|
||||
|
||||
|
@@ -0,0 +1,46 @@
|
||||
package com.ruoyi.common.core.domain.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 用户技能信息
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-10-21 12:22:09
|
||||
*/
|
||||
@Data
|
||||
@TableName("app_skill")
|
||||
public class AppSkill extends BaseEntity {
|
||||
@TableField(exist = false)
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键id
|
||||
*/
|
||||
@TableId(value = "id",type = IdType.AUTO)
|
||||
@ApiModelProperty("用户ID")
|
||||
private Long id;
|
||||
/**
|
||||
* 用户id
|
||||
*/
|
||||
@ApiModelProperty("用户id")
|
||||
private Long userId;
|
||||
/**
|
||||
* 技能名称
|
||||
*/
|
||||
@ApiModelProperty("技能名称")
|
||||
private String name;
|
||||
/**
|
||||
* 技能等级
|
||||
*/
|
||||
@ApiModelProperty("技能等级")
|
||||
private String levels;
|
||||
}
|
@@ -1,4 +1,4 @@
|
||||
package com.ruoyi.cms.domain;
|
||||
package com.ruoyi.common.core.domain.entity;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
@@ -100,4 +100,34 @@ public class AppUser extends BaseEntity
|
||||
@TableField(exist = false)
|
||||
@ApiModelProperty("期望岗位列表")
|
||||
private List<String> jobTitle;
|
||||
|
||||
@ApiModelProperty("身份证")
|
||||
private String idCard;
|
||||
|
||||
/**
|
||||
* 是否企业用户 0是,1否改为(0企业,1求职者,2网格员)
|
||||
*/
|
||||
@ApiModelProperty("app角色:0企业,1求职者,2网格员 3内部政府人员")
|
||||
private String isCompanyUser;
|
||||
|
||||
@TableField(exist = false)
|
||||
@ApiModelProperty("密码")
|
||||
private String password;
|
||||
|
||||
/**
|
||||
* 微信小程序用户唯一标识
|
||||
*/
|
||||
@ApiModelProperty("微信小程序用户唯一标识")
|
||||
private String openid;
|
||||
/**
|
||||
* 微信开放平台全局标识
|
||||
*/
|
||||
@ApiModelProperty("微信开放平台全局标识")
|
||||
private String unionid;
|
||||
|
||||
@ApiModelProperty("民族")
|
||||
private String nation;
|
||||
|
||||
@ApiModelProperty("工作经验")
|
||||
private String workExperience;
|
||||
}
|
@@ -1,14 +1,14 @@
|
||||
package com.ruoyi.cms.domain;
|
||||
package com.ruoyi.common.core.domain.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 公司对象 company
|
||||
* @author lishundong
|
||||
@@ -50,7 +50,7 @@ public class Company extends BaseEntity
|
||||
@ApiModelProperty("单位介绍")
|
||||
private String description;
|
||||
|
||||
@Excel(name = "性质")
|
||||
@Excel(name = "性质-已改为企业类型")
|
||||
@ApiModelProperty("性质")
|
||||
private String nature;
|
||||
|
||||
@@ -87,4 +87,40 @@ public class Company extends BaseEntity
|
||||
|
||||
@ApiModelProperty("审核未通过原因")
|
||||
private String notPassReason;
|
||||
|
||||
// @TableField(exist = false)
|
||||
// @ApiModelProperty("qiye")
|
||||
// private Integer isCollection;
|
||||
|
||||
@TableField(exist = false)
|
||||
@ApiModelProperty("企业联系人列表")
|
||||
private List<CompanyContact> companyContactList;
|
||||
|
||||
@ApiModelProperty("注册地址")
|
||||
private String registeredAddress;
|
||||
|
||||
@ApiModelProperty("是否异常")
|
||||
private String isAbnormal;
|
||||
|
||||
@TableField(exist = false)
|
||||
@ApiModelProperty("驳回时间")
|
||||
private String rejectTime;
|
||||
|
||||
@ApiModelProperty("是否本地重点企业")
|
||||
private String isImpCompany;
|
||||
|
||||
@ApiModelProperty("本地重点发展产业")
|
||||
private String impCompanyType;
|
||||
|
||||
@ApiModelProperty("是否是就业见习基地 0是 1否")
|
||||
private String enterpriseType;
|
||||
|
||||
@ApiModelProperty("法人姓名")
|
||||
private String legalPerson;
|
||||
|
||||
@ApiModelProperty("法人身份证")
|
||||
private String legalIdCard;
|
||||
|
||||
@ApiModelProperty("法人联系方式")
|
||||
private String legalPhone;
|
||||
}
|
@@ -0,0 +1,48 @@
|
||||
package com.ruoyi.common.core.domain.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 公司联系人
|
||||
*
|
||||
* @author
|
||||
* @email
|
||||
* @date 2025-09-30 15:57:06
|
||||
*/
|
||||
@Data
|
||||
@ApiModel("公司联系人")
|
||||
@TableName("company_contact")
|
||||
public class CompanyContact extends BaseEntity {
|
||||
@TableField(exist = false)
|
||||
private static final long serialVersionUID = 1L;
|
||||
/**
|
||||
* id
|
||||
*/
|
||||
@TableId(value = "id",type = IdType.AUTO)
|
||||
@ApiModelProperty("id")
|
||||
private Long id;
|
||||
/**
|
||||
* 公司id
|
||||
*/
|
||||
@ApiModelProperty("岗位id")
|
||||
private Long companyId;
|
||||
/**
|
||||
* 联系人
|
||||
*/
|
||||
@ApiModelProperty("联系人")
|
||||
private String contactPerson;
|
||||
/**
|
||||
* 联系人电话
|
||||
*/
|
||||
@ApiModelProperty("联系人电话")
|
||||
private String contactPersonPhone;
|
||||
|
||||
}
|
@@ -70,6 +70,9 @@ public class SysUser extends BaseEntity
|
||||
@Excel(name = "最后登录时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss", type = Type.EXPORT)
|
||||
private Date loginDate;
|
||||
|
||||
@Excel(name = "身份证/信用代码")
|
||||
private String idCard;
|
||||
|
||||
/** 部门对象 */
|
||||
@Excels({
|
||||
@Excel(name = "部门名称", targetAttr = "deptName", type = Type.EXPORT),
|
||||
@@ -297,6 +300,14 @@ public class SysUser extends BaseEntity
|
||||
this.roleId = roleId;
|
||||
}
|
||||
|
||||
public String getIdCard() {
|
||||
return idCard;
|
||||
}
|
||||
|
||||
public void setIdCard(String idCard) {
|
||||
this.idCard = idCard;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
@@ -319,6 +330,7 @@ public class SysUser extends BaseEntity
|
||||
.append("updateTime", getUpdateTime())
|
||||
.append("remark", getRemark())
|
||||
.append("dept", getDept())
|
||||
.append("idCard", getIdCard())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user