parent
fce631eb3c
commit
082e0631ce
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,232 @@
|
|||||||
|
package edu.ahbvc.recruit.controller;
|
||||||
|
|
||||||
|
import edu.ahbvc.recruit.aspect.MethodSwitch;
|
||||||
|
import edu.ahbvc.recruit.model.*;
|
||||||
|
import edu.ahbvc.recruit.model.page.*;
|
||||||
|
import edu.ahbvc.recruit.model.token.Token;
|
||||||
|
import edu.ahbvc.recruit.service.ThingServiceImpl;
|
||||||
|
import edu.ahbvc.recruit.service.UserServiceImpl;
|
||||||
|
import edu.ahbvc.recruit.util.JwtUtil;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import java.util.HashMap;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Restful API接口
|
||||||
|
* <p>
|
||||||
|
* 用于提供前端页面所需的接口
|
||||||
|
* </p>
|
||||||
|
* @author c215
|
||||||
|
*/
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("api")
|
||||||
|
public class RestFulController {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 开发环境下为true, 生产环境下为false
|
||||||
|
* 本地开发环境下, 为了方便测试, 所有接口都返回模拟数据
|
||||||
|
* 生产环境下, 所有接口都返回真实数据
|
||||||
|
* 为了避免在生产环境下, 出现错误, 导致数据泄露, 请在生产环境下, 关闭该功能
|
||||||
|
* 关闭方法: 将下方isDev的值改为false
|
||||||
|
*/
|
||||||
|
private final boolean isDev = false;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 注入UserService和ThingService
|
||||||
|
* 用于获取用户信息和批次信息
|
||||||
|
*/
|
||||||
|
private UserServiceImpl userService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 注入ThingService
|
||||||
|
* 用于获取批次信息
|
||||||
|
*/
|
||||||
|
private ThingServiceImpl thingService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 注入UserService
|
||||||
|
* 用于获取用户信息
|
||||||
|
*
|
||||||
|
* @param userService 用户服务
|
||||||
|
*/
|
||||||
|
@Autowired
|
||||||
|
public void setUserService(UserServiceImpl userService) {
|
||||||
|
this.userService = userService;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 注入ThingService
|
||||||
|
* 用于获取批次信息
|
||||||
|
*
|
||||||
|
* @param thingService 批次服务
|
||||||
|
*/
|
||||||
|
@Autowired
|
||||||
|
public void setThingService(ThingServiceImpl thingService) {
|
||||||
|
this.thingService = thingService;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取所有批次的{名称-id}以供前端下拉框使用
|
||||||
|
*
|
||||||
|
* @return 批次集合{名称-id}
|
||||||
|
*/
|
||||||
|
@GetMapping("tableBatchOption")
|
||||||
|
public ApiResponseData<HashMap<String, Object>> getBatcheOption() {
|
||||||
|
// 获取所有批次信息
|
||||||
|
List<Batch> batches = thingService.getBatchOption();
|
||||||
|
// 封装返回数据
|
||||||
|
HashMap<String, Object> map = new HashMap<>();
|
||||||
|
// 将批次信息存入map中
|
||||||
|
map.put("list", batches);
|
||||||
|
// 创建ApiResponseData对象, 用于封装返回数据
|
||||||
|
ApiResponseData<HashMap<String, Object>> responseData = new ApiResponseData<>();
|
||||||
|
// 设置返回数据的状态码和消息
|
||||||
|
responseData.setCode("0");
|
||||||
|
// 设置返回数据的消息
|
||||||
|
responseData.setMessage("获取批次数据");
|
||||||
|
// 设置返回数据
|
||||||
|
responseData.setData(map);
|
||||||
|
// 返回ApiResponseData对象
|
||||||
|
return responseData;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取岗位下拉框内容
|
||||||
|
*
|
||||||
|
* @return 岗位集合{岗位名-id}
|
||||||
|
*/
|
||||||
|
@GetMapping("getPositionOption")
|
||||||
|
public ApiResponseData<HashMap<String, Object>> getPositionOption() {
|
||||||
|
// 获取所有岗位信息
|
||||||
|
List<Position> list = thingService.getPositionOption();
|
||||||
|
// 封装返回数据
|
||||||
|
ApiResponseData<HashMap<String, Object>> responseData = new ApiResponseData<>();
|
||||||
|
// 设置返回数据的状态码和消息
|
||||||
|
HashMap<String, Object> map = new HashMap<>();
|
||||||
|
// 将岗位信息存入map中
|
||||||
|
map.put("list", list);
|
||||||
|
|
||||||
|
if (list != null) {
|
||||||
|
// 设置返回数据的状态码和消息
|
||||||
|
responseData.setCode("0");
|
||||||
|
// 设置返回数据的消息
|
||||||
|
responseData.setMessage("获取信息成功");
|
||||||
|
// 设置返回数据
|
||||||
|
responseData.setData(map);
|
||||||
|
|
||||||
|
} else {
|
||||||
|
// 设置返回数据的状态码和消息
|
||||||
|
responseData.setCode("500");
|
||||||
|
// 设置返回数据的消息
|
||||||
|
responseData.setMessage("获取信息失败");
|
||||||
|
|
||||||
|
}
|
||||||
|
// 返回ApiResponseData对象
|
||||||
|
return responseData;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param authorizationHeader 请求头Token
|
||||||
|
* @return 用户前台获取当前批次
|
||||||
|
*/
|
||||||
|
@GetMapping("batchs")
|
||||||
|
public ApiResponseData<HashMap<String, Object>> getBatches(
|
||||||
|
@RequestHeader("Authorization") String authorizationHeader) {
|
||||||
|
// 解析Token
|
||||||
|
Token user;
|
||||||
|
// 判断Token是否为空
|
||||||
|
user = JwtUtil.parseJWT(authorizationHeader);
|
||||||
|
if (user == null) {
|
||||||
|
// 返回ApiResponseData对象
|
||||||
|
return new ApiResponseData<>("401", null, "登录失效,请重新登录");
|
||||||
|
}
|
||||||
|
// 获取当前批次信息
|
||||||
|
int infoIntegrity = 0;
|
||||||
|
// 获取当前批次信息
|
||||||
|
Batch batch = thingService.getCurrentBatches();
|
||||||
|
// 获取当前用户信息
|
||||||
|
User one = userService.getOne(user.getUserId());
|
||||||
|
// 判断当前用户是否已经报名
|
||||||
|
boolean alreadyRecruit = userService.alreadyRecruit(String.valueOf(user.getUserId()));
|
||||||
|
if (one.getIdNum() != null) {
|
||||||
|
// 判断当前用户是否已经填写过信息
|
||||||
|
infoIntegrity = 1;
|
||||||
|
}
|
||||||
|
// 判断当前批次是否已经结束
|
||||||
|
boolean disableSubmit = !MethodSwitch.isEnabled(MethodSwitch.SUBMIT);
|
||||||
|
// 封装返回数据
|
||||||
|
HashMap<String, Object> map = new HashMap<>(10);
|
||||||
|
// 将批次信息存入map中
|
||||||
|
map.put("oneBatch", batch);
|
||||||
|
// 将信息完整性存入map中
|
||||||
|
map.put("infoIntegrity", infoIntegrity);
|
||||||
|
// 将是否已经报名存入map中
|
||||||
|
map.put("disableRecruit", disableSubmit);
|
||||||
|
// 将是否已经报名存入map中
|
||||||
|
map.put("alreadyRecruit", alreadyRecruit);
|
||||||
|
// 创建ApiResponseData对象, 用于封装返回数据
|
||||||
|
ApiResponseData<HashMap<String, Object>> responseData = new ApiResponseData<>();
|
||||||
|
// 设置返回数据的状态码和消息
|
||||||
|
responseData.setCode("0");
|
||||||
|
// 设置返回数据的消息
|
||||||
|
responseData.setMessage("获取批次数据");
|
||||||
|
// 设置返回数据
|
||||||
|
responseData.setData(map);
|
||||||
|
// 返回ApiResponseData对象
|
||||||
|
return responseData;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 搜索岗位
|
||||||
|
*
|
||||||
|
* @param authorizationHeader 请求头Token
|
||||||
|
* @param requestBody 请求体
|
||||||
|
* @return 岗位集合
|
||||||
|
*/
|
||||||
|
@PostMapping("searchPositions")
|
||||||
|
public ApiResponseData<HashMap<String, Object>> getPositions(@RequestBody SearchAndPageOfPositionByUser requestBody,
|
||||||
|
@RequestHeader("Authorization") String authorizationHeader) {
|
||||||
|
|
||||||
|
// 解析Token
|
||||||
|
Token token;
|
||||||
|
token = JwtUtil.parseJWT(authorizationHeader);
|
||||||
|
if (token == null) {
|
||||||
|
// 返回ApiResponseData对象
|
||||||
|
return new ApiResponseData<>("401", null, "登录失效,请重新登录");
|
||||||
|
}
|
||||||
|
// 获取当前批次信息
|
||||||
|
int batchId = requestBody.getBatchId();
|
||||||
|
// 获取当前批次信息
|
||||||
|
int offset = 0;
|
||||||
|
// 获取当前批次信息
|
||||||
|
int size = Integer.MAX_VALUE;
|
||||||
|
// String code = requestBody.getCode();
|
||||||
|
// 获取当前批次信息
|
||||||
|
int positionsNum = thingService.getPositionsNum();
|
||||||
|
// 判断当前批次是否已经结束
|
||||||
|
if (requestBody.getCurrentPage() >= positionsNum) {
|
||||||
|
// 返回ApiResponseData对象
|
||||||
|
return new ApiResponseData<>("500", null, "参数异常");
|
||||||
|
}
|
||||||
|
// 获取当前批次信息
|
||||||
|
List<Position> positionList = thingService.getSomePosition(batchId, offset, size);
|
||||||
|
// 封装返回数据
|
||||||
|
HashMap<String, Object> map = new HashMap<>();
|
||||||
|
// 将批次信息存入map中
|
||||||
|
map.put("list", positionList);
|
||||||
|
// 创建ApiResponseData对象, 用于封装返回数据
|
||||||
|
ApiResponseData<HashMap<String, Object>> responseData = new ApiResponseData<>();
|
||||||
|
// 设置返回数据的状态码和消息
|
||||||
|
responseData.setCode("0");
|
||||||
|
// 设置返回数据的消息
|
||||||
|
responseData.setMessage("获取部门数据");
|
||||||
|
// 设置返回数据
|
||||||
|
responseData.setData(map);
|
||||||
|
// 返回ApiResponseData对象
|
||||||
|
return responseData;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,435 @@
|
|||||||
|
package edu.ahbvc.recruit.mapper;
|
||||||
|
|
||||||
|
import edu.ahbvc.recruit.model.Batch;
|
||||||
|
import edu.ahbvc.recruit.model.Position;
|
||||||
|
import edu.ahbvc.recruit.model.Thing;
|
||||||
|
import edu.ahbvc.recruit.model.ThingWithUser;
|
||||||
|
import edu.ahbvc.recruit.model.export.Excel;
|
||||||
|
import edu.ahbvc.recruit.model.export.Ticket;
|
||||||
|
import org.apache.ibatis.annotations.*;
|
||||||
|
import org.mybatis.spring.annotation.MapperScan;
|
||||||
|
import org.springframework.stereotype.Repository;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
package edu.ahbvc.recruit.mapper;
|
||||||
|
|
||||||
|
// 导入必要的模型类和注解
|
||||||
|
import edu.ahbvc.recruit.model.Batch;
|
||||||
|
import edu.ahbvc.recruit.model.Position;
|
||||||
|
import edu.ahbvc.recruit.model.Thing;
|
||||||
|
import edu.ahbvc.recruit.model.ThingWithUser;
|
||||||
|
import edu.ahbvc.recruit.model.export.Excel;
|
||||||
|
import edu.ahbvc.recruit.model.export.Ticket;
|
||||||
|
import org.apache.ibatis.annotations.*;
|
||||||
|
import org.mybatis.spring.annotation.MapperScan;
|
||||||
|
import org.springframework.stereotype.Repository;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author c215
|
||||||
|
*
|
||||||
|
* ThingInter 接口 - 招聘事务相关的数据库操作接口
|
||||||
|
* 提供对招聘批次、岗位、用户投递关系等数据的CRUD操作
|
||||||
|
*/
|
||||||
|
@Repository // 标识为Spring的Repository组件
|
||||||
|
@Mapper // MyBatis的Mapper接口
|
||||||
|
public interface ThingInter {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取准考证数据
|
||||||
|
* @param recruitId 招聘ID
|
||||||
|
* @param id 投递记录ID
|
||||||
|
* @return 包含准考证数据的Ticket对象
|
||||||
|
*/
|
||||||
|
@Select("SELECT `u`.idnum, `u`.`name`, `u`.phone tel, p.`code`, "
|
||||||
|
+ "CASE WHEN p.jobTitle LIKE '管%' THEN "
|
||||||
|
+ "'行政部门' " + "WHEN p.jobTitle LIKE '专业%' THEN "
|
||||||
|
+ "'二级学院' ELSE '其他部门'" + " END AS department ,"
|
||||||
|
+ "(CASE WHEN ut.ticket_num = 0 THEN "
|
||||||
|
+ "(SELECT MAX(ut2.ticket_num)+1 FROM `USER-thing` AS ut2 WHERE `thingid` = #{recruitId}) "
|
||||||
|
+ "ELSE ut.ticket_num END) AS ticketNumber "
|
||||||
|
+ "FROM "
|
||||||
|
+ "`USER-thing` AS ut " + "LEFT JOIN `batch-position` AS `bp` ON `bp`.id = ut.thingid "
|
||||||
|
+ "LEFT JOIN `positions` AS p ON `p`.id = bp.positionid "
|
||||||
|
+ "LEFT JOIN `USER` AS u ON ut.userid = u.id "
|
||||||
|
+ "LEFT JOIN batchs ON batchs.id = bp.batchid" + " WHERE "
|
||||||
|
+ "ut.id = #{id}")
|
||||||
|
Ticket getTicketData(@Param("recruitId")Integer recruitId, @Param("id")Integer id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取指定招聘的最大准考证号
|
||||||
|
* @param recruitId 招聘ID
|
||||||
|
* @return 最大准考证号
|
||||||
|
*/
|
||||||
|
@Select("SELECT MAX(ticket_num) FROM `user-thing` WHERE `thingid` = #{recruitId}")
|
||||||
|
int getTicketNum(Integer recruitId);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 检查准考证是否已打印
|
||||||
|
* @param thingid 投递记录ID
|
||||||
|
* @return 准考证号(0表示未打印)
|
||||||
|
*/
|
||||||
|
@Select("SELECT `ticket_num` FROM `user-thing` where `id`=#{thingid}")
|
||||||
|
int isPrintedTicket(Integer thingid);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 设置准考证已打印
|
||||||
|
* @param ticketNum 准考证号
|
||||||
|
* @param thingId 投递记录ID
|
||||||
|
* @return 影响的行数
|
||||||
|
*/
|
||||||
|
@Update("UPDATE `user-thing` "
|
||||||
|
+ "SET `ticket_num` = #{arg0} WHERE `id` = #{arg1}")
|
||||||
|
int setTicketPrinted(Integer ticketNum, Integer thingId);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取用户可投递的招聘批次信息
|
||||||
|
* @param userid 用户ID
|
||||||
|
* @param batch 批次ID(0表示全部)
|
||||||
|
* @return 批次列表
|
||||||
|
*/
|
||||||
|
List<Batch> getthingForuser(@Param("userid") int userid, @Param("batch") int batch);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取用户已投递的招聘信息
|
||||||
|
* @param userid 用户ID
|
||||||
|
* @return 招聘信息列表
|
||||||
|
*/
|
||||||
|
List<Thing> getThingAboutUser(@Param("userid") int userid);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页获取招聘信息(管理员用)
|
||||||
|
* @param currentPage 当前页
|
||||||
|
* @param size 每页大小
|
||||||
|
* @param jobTitles 岗位名称列表
|
||||||
|
* @param batches 批次列表
|
||||||
|
* @param status 状态列表
|
||||||
|
* @param name 名称
|
||||||
|
* @return 招聘信息列表
|
||||||
|
*/
|
||||||
|
List<ThingWithUser> getThings(@Param("currentPage") int currentPage, @Param("size") int size,
|
||||||
|
@Param("jobTitles") List<Integer> jobTitles, @Param("batches") List<Integer> batches,
|
||||||
|
@Param("status") List<Integer> status, @Param("name") String name);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页获取待审核招聘信息(超级管理员用)
|
||||||
|
* @param currentPage 当前页
|
||||||
|
* @param size 每页大小
|
||||||
|
* @param jobTitles 岗位名称列表
|
||||||
|
* @param batches 批次列表
|
||||||
|
* @return 招聘信息列表
|
||||||
|
*/
|
||||||
|
List<ThingWithUser> getAuditThings(@Param("currentPage") int currentPage, @Param("size") int size,
|
||||||
|
@Param("jobTitles") List<Integer> jobTitles, @Param("batches") List<Integer> batches);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 根据ID列表获取招聘信息
|
||||||
|
* @param id ID列表
|
||||||
|
* @return 招聘信息列表
|
||||||
|
*/
|
||||||
|
List<ThingWithUser> getThingsById(@Param("thingId") List<Integer> id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取单个招聘详细信息
|
||||||
|
* @param thingId 招聘ID
|
||||||
|
* @return 招聘详细信息
|
||||||
|
*/
|
||||||
|
@Select("SELECT `ut`.`id` thingId, `ut`.`status`,bp.id recruitId,"
|
||||||
|
+ "`ut`.`awardsAndPunishments`, `ut`.`note`, `ut`.`qualificationResult`,"
|
||||||
|
+ "batchs.id batchid,batchs.`name` batchname,p.id positionId, p.code, p.jobTitle,"
|
||||||
|
+ "u.id userId, u.`name` username" + " FROM `user-thing` AS ut"
|
||||||
|
+ " LEFT JOIN `batch-position` AS `bp` ON `bp`.id = ut.thingid "
|
||||||
|
+ " LEFT JOIN `positions` AS p ON `p`.id = bp.positionid" + " LEFT JOIN `user` AS u ON ut.userid = u.id "
|
||||||
|
+ " LEFT JOIN batchs ON batchs.id=bp.batchid" + " WHERE ut.id = #{id}")
|
||||||
|
ThingWithUser getOneThing(@Param("id") int thingId);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取未处理的招聘数量
|
||||||
|
* @return 未处理数量
|
||||||
|
*/
|
||||||
|
@Select("SELECT count(id) FROM `user-thing` WHERE `status` = '0' LIMIT 0,1000")
|
||||||
|
int getUnsettledThingsNum();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取招聘信息数量
|
||||||
|
* @param jobTitles 岗位名称列表
|
||||||
|
* @param batches 批次列表
|
||||||
|
* @param status 状态列表
|
||||||
|
* @param name 名称
|
||||||
|
* @return 数量
|
||||||
|
*/
|
||||||
|
Integer getThingsNum(@Param("jobTitles") List<Integer> jobTitles, @Param("batches") List<Integer> batches,
|
||||||
|
@Param("status") List<Integer> status, @Param("name") String name);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 更新招聘状态
|
||||||
|
* @param thingid 招聘ID
|
||||||
|
* @param status 状态
|
||||||
|
* @return 影响的行数
|
||||||
|
*/
|
||||||
|
@Update("UPDATE `user-thing` SET `user-thing`.`status`= ${status} WHERE `user-thing`.id=${thingid}")
|
||||||
|
int updateThingStatus(@Param("thingid") int thingid, @Param("status") int status);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 拒绝招聘申请
|
||||||
|
* @param thingid 招聘ID
|
||||||
|
* @param status 状态
|
||||||
|
* @param qualificationResult 资格审查结果
|
||||||
|
* @return 影响的行数
|
||||||
|
*/
|
||||||
|
@Update("UPDATE `user-thing` SET `user-thing`.`status`= ${status},`user-thing`.`qualificationResult` = #{qualificationResult} WHERE `user-thing`.id=${thingid}")
|
||||||
|
int refuseThing(@Param("thingid") int thingid, @Param("status") int status,
|
||||||
|
@Param("qualificationResult") String qualificationResult);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 更新招聘信息
|
||||||
|
* @param thingid 招聘ID
|
||||||
|
* @param awardsAndPunishments 奖惩信息
|
||||||
|
* @param note 备注
|
||||||
|
* @param qualificationResult 资格审查结果
|
||||||
|
* @return 影响的行数
|
||||||
|
*/
|
||||||
|
@Update("UPDATE `user-thing` SET " + "`user-thing`.`awardsAndPunishments`= IFNULL(#{awardsAndPunishments}, ''),"
|
||||||
|
+ "`user-thing`.`note`= IFNULL(#{note}, ''),"
|
||||||
|
+ "`user-thing`.`qualificationResult`= IFNULL(#{qualificationResult}, '')"
|
||||||
|
+ "WHERE `user-thing`.id = #{thingid}")
|
||||||
|
int updateThingInfo(@Param("thingid") int thingid,
|
||||||
|
@Param("awardsAndPunishments") String awardsAndPunishments, @Param("note") String note,
|
||||||
|
@Param("qualificationResult") String qualificationResult);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 更新资格审查结果
|
||||||
|
* @param thingid 招聘ID
|
||||||
|
* @param qualificationResult 资格审查结果
|
||||||
|
* @return 影响的行数
|
||||||
|
*/
|
||||||
|
@Update("UPDATE `user-thing` SET "
|
||||||
|
+ "`user-thing`.`qualificationResult`= IFNULL(#{qualificationResult}, '')"
|
||||||
|
+ "WHERE `user-thing`.id = #{thingid}")
|
||||||
|
int updateThingQualification(@Param("thingid") int thingid,
|
||||||
|
@Param("qualificationResult") String qualificationResult);
|
||||||
|
|
||||||
|
// 批次相关操作
|
||||||
|
/**
|
||||||
|
* 获取所有批次选项
|
||||||
|
* @return 批次列表
|
||||||
|
*/
|
||||||
|
@Select("SELECT batchs.id,batchs.name FROM `batchs`")
|
||||||
|
List<Batch> getBatchOption();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取单个批次信息
|
||||||
|
* @param id 批次ID
|
||||||
|
* @return 批次信息
|
||||||
|
*/
|
||||||
|
@Select("SELECT batchs.*, COUNT(positions.id) num " + "FROM `batchs` "
|
||||||
|
+ "LEFT JOIN `batch-position` ON `batch-position`.batchid = batchs.id "
|
||||||
|
+ "LEFT JOIN positions ON positions.id=`batch-position`.positionid "
|
||||||
|
+ "GROUP BY batchs.id having batchs.id=#{id}")
|
||||||
|
Batch getBatch(int id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页获取批次列表
|
||||||
|
* @param currentPage 当前页
|
||||||
|
* @param size 每页大小
|
||||||
|
* @param key 关键字
|
||||||
|
* @param state 状态
|
||||||
|
* @return 批次列表
|
||||||
|
*/
|
||||||
|
List<Batch> getBatches(@Param("currentPage") int currentPage, @Param("size") int size,
|
||||||
|
@Param("key") String key, @Param("state") Integer state);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取当前开放的批次
|
||||||
|
* @return 批次信息
|
||||||
|
*/
|
||||||
|
@Select("SELECT batchs.*, COUNT(positions.id) positionNum " + "FROM `batchs` "
|
||||||
|
+ "LEFT JOIN `batch-position` ON `batch-position`.batchid = batchs.id "
|
||||||
|
+ "LEFT JOIN positions ON positions.id=`batch-position`.positionid "
|
||||||
|
+ "GROUP BY batchs.id having batchs.open=1 LIMIT 1")
|
||||||
|
Batch getCurrentBatch();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取批次数量
|
||||||
|
* @param key 关键字
|
||||||
|
* @param state 状态
|
||||||
|
* @return 数量
|
||||||
|
*/
|
||||||
|
int getBatchesNum(@Param("key") String key, @Param("state") Integer state);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 更新批次信息
|
||||||
|
* @param batch 批次对象
|
||||||
|
* @return 影响的行数
|
||||||
|
*/
|
||||||
|
@Update("UPDATE batchs SET name = #{name},startime = #{startime},"
|
||||||
|
+ "deadline = #{deadline},open = #{open}, `disableAutoUpdate`=#{disableAutoUpdate} where id = #{id}")
|
||||||
|
int updateBatch(Batch batch);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 开启批次
|
||||||
|
* @param id 批次ID
|
||||||
|
* @return 影响的行数
|
||||||
|
*/
|
||||||
|
@Update("UPDATE batchs SET open = 1 where id = #{id}")
|
||||||
|
int updateBatchOpen(int id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 关闭所有批次
|
||||||
|
* @return 影响的行数
|
||||||
|
*/
|
||||||
|
@Update("UPDATE batchs SET open = 0")
|
||||||
|
int updateBatchClose();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 添加批次
|
||||||
|
* @param batch 批次对象
|
||||||
|
* @return 影响的行数
|
||||||
|
*/
|
||||||
|
@Insert("INSERT INTO `batchs` (`open`, `name`, `disableAutoUpdate`) VALUES (#{open}, #{name}, #{disableAutoUpdate})")
|
||||||
|
int addBatch(Batch batch);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除批次
|
||||||
|
* @param id 批次ID
|
||||||
|
* @return 影响的行数
|
||||||
|
*/
|
||||||
|
@Delete("DELETE FROM `batchs` WHERE `id` = #{id}")
|
||||||
|
int delBatch(int id);
|
||||||
|
|
||||||
|
// 岗位相关操作
|
||||||
|
/**
|
||||||
|
* 分页获取岗位列表
|
||||||
|
* @param currentPage 当前页
|
||||||
|
* @param size 每页大小
|
||||||
|
* @return 岗位列表
|
||||||
|
*/
|
||||||
|
List<Position> getPositions(@Param("currentPage") int currentPage, @Param("size") int size);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取岗位数量
|
||||||
|
* @return 数量
|
||||||
|
*/
|
||||||
|
int getPositionsNum();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取岗位选项
|
||||||
|
* @return 岗位选项列表
|
||||||
|
*/
|
||||||
|
@Select("SELECT positions.id, CONCAT(positions.code, ' - ', positions.jobTitle) AS jobTitle FROM positions")
|
||||||
|
List<Position> getPositionOption();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页获取指定批次的岗位
|
||||||
|
* @param batchid 批次ID
|
||||||
|
* @param offset 偏移量
|
||||||
|
* @param size 每页大小
|
||||||
|
* @return 岗位列表
|
||||||
|
*/
|
||||||
|
List<Position> getSomePosition(@Param("batchid") int batchid, @Param("offset") int offset,
|
||||||
|
@Param("size") int size);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取单个岗位详情
|
||||||
|
* @param id 岗位ID
|
||||||
|
* @return 岗位详情
|
||||||
|
*/
|
||||||
|
@Select("SELECT positions.*, COUNT(`user-thing`.userid) toll,"
|
||||||
|
+ " batchs.id bid,batchs.`open`, batchs.`name`, batchs.startime bstart"
|
||||||
|
+ " FROM positions "
|
||||||
|
+ " LEFT JOIN `user-thing` ON `user-thing`.thingid = positions.id"
|
||||||
|
+ " LEFT JOIN batchs ON batchs.id = positions.batch WHERE positions.id = ${id}"
|
||||||
|
+ " GROUP BY positions.id")
|
||||||
|
Position getOnePosition(int id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 添加岗位
|
||||||
|
* @param p 岗位对象
|
||||||
|
* @return 影响的行数
|
||||||
|
*/
|
||||||
|
@Insert("INSERT INTO positions (`jobTitle`, `code`, `type`, `specialty`, `education`, `degree`, `maxAge`, `sex`, `zzmm`, `info`, `toll`, `require`) "
|
||||||
|
+ "VALUES (#{jobTitle}, #{code}, #{type}, #{specialty}, #{education}, #{degree}, #{maxAge}, #{sex}, #{zzmm}, #{info}, #{toll}, #{require})")
|
||||||
|
int addPosition(Position p);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除岗位
|
||||||
|
* @param id 岗位ID
|
||||||
|
* @return 影响的行数
|
||||||
|
*/
|
||||||
|
@Delete("DELETE FROM `positions` WHERE `id` = #{id}")
|
||||||
|
int delPosition(int id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除岗位
|
||||||
|
* @param id 岗位ID列表
|
||||||
|
* @return 影响的行数
|
||||||
|
*/
|
||||||
|
int delPositions(@Param("id") List<Integer> id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 更新岗位信息
|
||||||
|
* @param p 岗位对象
|
||||||
|
* @return 影响的行数
|
||||||
|
*/
|
||||||
|
@Update("UPDATE `positions` SET `jobTitle` = #{jobTitle}, `code` = #{code}, `type` = #{type}, `specialty` = #{specialty}, `education` = #{education}, `degree` = #{degree}, `maxAge` = #{maxAge}, `sex` = #{sex}, `zzmm` = #{zzmm}, `info` = #{info}, `toll` = #{toll}, `require` = #{require} WHERE `id` = #{id}")
|
||||||
|
int updatePosition(Position p);
|
||||||
|
|
||||||
|
// 招聘岗位相关操作
|
||||||
|
/**
|
||||||
|
* 分页获取招聘岗位列表
|
||||||
|
* @param currentPage 当前页
|
||||||
|
* @param size 每页大小
|
||||||
|
* @param jobTitle 岗位名称列表
|
||||||
|
* @param batchs 批次列表
|
||||||
|
* @return 招聘岗位列表
|
||||||
|
*/
|
||||||
|
List<Thing> getRecruits(@Param("currentPage") int currentPage, @Param("size") int size,
|
||||||
|
@Param("jobTitle") List<Integer> jobTitle, @Param("batch") List<Integer> batchs);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取招聘岗位数量
|
||||||
|
* @param jobTitle 岗位名称列表
|
||||||
|
* @param batch 批次列表
|
||||||
|
* @return 数量
|
||||||
|
*/
|
||||||
|
int getRecruitNum(@Param("jobTitle") List<Integer> jobTitle, @Param("batch") List<Integer> batch);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 添加招聘岗位
|
||||||
|
* @param batchid 批次ID
|
||||||
|
* @param positionid 岗位ID
|
||||||
|
* @return 影响的行数
|
||||||
|
*/
|
||||||
|
@Insert("INSERT INTO `batch-position` (`batchid`, `positionid`) VALUES (#{batchid}, #{positionid})")
|
||||||
|
int addRecruit(@Param("batchid") Integer batchid, @Param("positionid") Integer positionid);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 更新招聘岗位
|
||||||
|
* @param id IDm
|
||||||
|
* @param batchid 批次ID
|
||||||
|
* @param positionid 岗位ID
|
||||||
|
* @return 影响的行数
|
||||||
|
*/
|
||||||
|
@Update("UPDATE `batch-position` SET `batchid` = #{batchid}, `positionid` = #{positionid} WHERE id = #{id}")
|
||||||
|
int updateRecruit(@Param("id") Integer id, @Param("batchid") Integer batchid,
|
||||||
|
@Param("positionid") Integer positionid);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除招聘岗位
|
||||||
|
* @param id ID
|
||||||
|
* @return 影响的行数
|
||||||
|
*/
|
||||||
|
@Delete("DELETE FROM `batch-position` WHERE id = #{id}")
|
||||||
|
int deleteRecruit(int id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取导出总表的数据
|
||||||
|
* @return 准备导出的Excel数据
|
||||||
|
*/
|
||||||
|
ArrayList<Excel> getPrintData();
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,67 @@
|
|||||||
|
package edu.ahbvc.recruit.model;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author c215
|
||||||
|
*/
|
||||||
|
public class Admin {
|
||||||
|
|
||||||
|
private int id;
|
||||||
|
private String name;
|
||||||
|
private String account;
|
||||||
|
private String pwd;
|
||||||
|
private String phone;
|
||||||
|
private Integer promise;
|
||||||
|
public Admin() {
|
||||||
|
super();
|
||||||
|
}
|
||||||
|
public Admin(int id, String name, String num, String pwd, String tel, Integer viewOnly) {
|
||||||
|
super();
|
||||||
|
this.id = id;
|
||||||
|
this.name = name;
|
||||||
|
this.account = num;
|
||||||
|
this.pwd = pwd;
|
||||||
|
this.phone = tel;
|
||||||
|
this.promise = viewOnly;
|
||||||
|
}
|
||||||
|
public int getId() {
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
public void setId(int id) {
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
public String getName() {
|
||||||
|
return name;
|
||||||
|
}
|
||||||
|
public void setName(String name) {
|
||||||
|
this.name = name;
|
||||||
|
}
|
||||||
|
public String getAccount() {
|
||||||
|
return account;
|
||||||
|
}
|
||||||
|
public void setAccount(String num) {
|
||||||
|
this.account = num;
|
||||||
|
}
|
||||||
|
public String getPwd() {
|
||||||
|
return pwd;
|
||||||
|
}
|
||||||
|
public void setPwd(String pwd) {
|
||||||
|
this.pwd = pwd;
|
||||||
|
}
|
||||||
|
public String getPhone() {
|
||||||
|
return phone;
|
||||||
|
}
|
||||||
|
public void setPhone(String tel) {
|
||||||
|
this.phone = tel;
|
||||||
|
}
|
||||||
|
public Integer getPromise() {
|
||||||
|
return promise;
|
||||||
|
}
|
||||||
|
public void setPromise(Integer viewOnly) {
|
||||||
|
this.promise = viewOnly;
|
||||||
|
}
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return "Admin [id=" + id + ", name=" + name + ", account=" + account + ", pwd=" + pwd + ", phone=" + phone + "]";
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,54 @@
|
|||||||
|
package edu.ahbvc.recruit.model;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author c215
|
||||||
|
* 封装返回数据
|
||||||
|
* 统一返回数据格式
|
||||||
|
*/
|
||||||
|
public class ApiResponseData<T> {
|
||||||
|
|
||||||
|
public String code;
|
||||||
|
public T data;
|
||||||
|
public String message;
|
||||||
|
|
||||||
|
public ApiResponseData() {
|
||||||
|
super();
|
||||||
|
}
|
||||||
|
|
||||||
|
public ApiResponseData(String code, T data, String message) {
|
||||||
|
super();
|
||||||
|
this.code = code;
|
||||||
|
this.data = data;
|
||||||
|
this.message = message;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCode() {
|
||||||
|
return code;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCode(String code) {
|
||||||
|
this.code = code;
|
||||||
|
}
|
||||||
|
|
||||||
|
public T getData() {
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setData(T data) {
|
||||||
|
this.data = data;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getMessage() {
|
||||||
|
return message;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setMessage(String message) {
|
||||||
|
this.message = message;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return "ApiResponseData [code=" + code + ", data=" + data + ", message=" + message + "]";
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,102 @@
|
|||||||
|
package edu.ahbvc.recruit.model;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnore;
|
||||||
|
|
||||||
|
public class Batch {
|
||||||
|
private int id;
|
||||||
|
@JsonIgnore
|
||||||
|
private int index;
|
||||||
|
private String name;
|
||||||
|
private String startTime;
|
||||||
|
private String deadline;
|
||||||
|
private int open;
|
||||||
|
private int disableAutoUpdate;
|
||||||
|
private int positionNum;
|
||||||
|
|
||||||
|
public Batch() {
|
||||||
|
super();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public int getId() {
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setId(int id) {
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getIndex() {
|
||||||
|
return index;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setIndex(int index) {
|
||||||
|
this.index = index;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getName() {
|
||||||
|
return name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setName(String name) {
|
||||||
|
this.name = name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getStartTime() {
|
||||||
|
return startTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setStartTime(String startTime) {
|
||||||
|
this.startTime = startTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getDeadline() {
|
||||||
|
return deadline;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDeadline(String deadline) {
|
||||||
|
this.deadline = deadline;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getPositionNum() {
|
||||||
|
return positionNum;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPositionNum(int positionNum) {
|
||||||
|
this.positionNum = positionNum;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getOpen() {
|
||||||
|
return open;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setOpen(int canuse) {
|
||||||
|
this.open = canuse;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getDisableAutoUpdate() {
|
||||||
|
return disableAutoUpdate;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDisableAutoUpdate(int disableAutoUPDATE) {
|
||||||
|
this.disableAutoUpdate = disableAutoUPDATE;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public int getNum() {
|
||||||
|
return positionNum;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setNum(int num) {
|
||||||
|
this.positionNum = num;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return "Batch [id=" + id + ", index=" + index + ", name=" + name + ", startime=" + startTime + ", deadline="
|
||||||
|
+ deadline + ", open=" + open + ", disableAutoUpdate=" + disableAutoUpdate + ", positionNum="
|
||||||
|
+ positionNum + "]";
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,164 @@
|
|||||||
|
package edu.ahbvc.recruit.model;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 岗位信息
|
||||||
|
*
|
||||||
|
* @author c215
|
||||||
|
*/
|
||||||
|
public class Position {
|
||||||
|
private int id;
|
||||||
|
/**
|
||||||
|
* 标识该岗位在对应批次下的编号(序号) 例如 2003 01 001
|
||||||
|
*/
|
||||||
|
private int recruitId;
|
||||||
|
private String code;
|
||||||
|
private String jobTitle;
|
||||||
|
private int toll;
|
||||||
|
private String type;
|
||||||
|
private String specialty;
|
||||||
|
private int education;
|
||||||
|
private int degree;
|
||||||
|
/**
|
||||||
|
* 性别要求 0不限 1男 2女
|
||||||
|
* 数据库类型 tinyint
|
||||||
|
* 默认值 0 不限
|
||||||
|
*/
|
||||||
|
private int sex;
|
||||||
|
/**
|
||||||
|
* 政治面貌
|
||||||
|
*/
|
||||||
|
private String politicalStatus;
|
||||||
|
private int maxAge;
|
||||||
|
private String info;
|
||||||
|
private String require;
|
||||||
|
|
||||||
|
|
||||||
|
public Position() {
|
||||||
|
super();
|
||||||
|
}
|
||||||
|
|
||||||
|
public Position(int id, int recruitId, String code, String jobTitle, int toll,
|
||||||
|
int education, int degree, int maxAge, String info, String require) {
|
||||||
|
super();
|
||||||
|
this.id = id;
|
||||||
|
this.recruitId = recruitId;
|
||||||
|
this.code = code;
|
||||||
|
this.jobTitle = jobTitle;
|
||||||
|
this.toll = toll;
|
||||||
|
this.education = education;
|
||||||
|
this.degree = degree;
|
||||||
|
this.maxAge = maxAge;
|
||||||
|
this.info = info;
|
||||||
|
this.require = require;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getId() {
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
public void setId(int id) {
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
public int getRecruitId() {
|
||||||
|
return recruitId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setRecruitId(int recruitId) {
|
||||||
|
this.recruitId = recruitId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCode() {
|
||||||
|
return code;
|
||||||
|
}
|
||||||
|
public void setCode(String code) {
|
||||||
|
this.code = code;
|
||||||
|
}
|
||||||
|
public String getJobTitle() {
|
||||||
|
return jobTitle;
|
||||||
|
}
|
||||||
|
public void setJobTitle(String jobTitle) {
|
||||||
|
this.jobTitle = jobTitle;
|
||||||
|
}
|
||||||
|
public int getEducation() {
|
||||||
|
return education;
|
||||||
|
}
|
||||||
|
public void setEducation(int degree) {
|
||||||
|
this.education = degree;
|
||||||
|
}
|
||||||
|
public int getMaxAge() {
|
||||||
|
return maxAge;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setMaxAge(int maxAge) {
|
||||||
|
this.maxAge = maxAge;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getInfo() {
|
||||||
|
return info;
|
||||||
|
}
|
||||||
|
public void setInfo(String info) {
|
||||||
|
this.info = info;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getDegree() {
|
||||||
|
return degree;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDegree(int degree) {
|
||||||
|
this.degree = degree;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getType() {
|
||||||
|
return type;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setType(String type) {
|
||||||
|
this.type = type;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getSpecialty() {
|
||||||
|
return specialty;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setSpecialty(String specialty) {
|
||||||
|
this.specialty = specialty;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getPoliticalStatus() {
|
||||||
|
return politicalStatus;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPoliticalStatus(String politicalStatus) {
|
||||||
|
this.politicalStatus = politicalStatus;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getSex() {
|
||||||
|
return sex;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setSex(int sex) {
|
||||||
|
this.sex = sex;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getToll() {
|
||||||
|
return toll;
|
||||||
|
}
|
||||||
|
public void setToll(int toll) {
|
||||||
|
this.toll = toll;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getRequire() {
|
||||||
|
return require;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setRequire(String require) {
|
||||||
|
this.require = require;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return "Position [id=" + id + ", recruitId=" + recruitId + ", code=" + code + ", jobTitle=" + jobTitle
|
||||||
|
+ ", toll=" + toll + ", maxAge=" + maxAge + ", education="
|
||||||
|
+ education + ", info=" + info + ", require=" + require + "]";
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,27 @@
|
|||||||
|
package edu.ahbvc.recruit.model;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author c215
|
||||||
|
*/
|
||||||
|
public class SwitchMethodStatus {
|
||||||
|
|
||||||
|
private Integer open;
|
||||||
|
|
||||||
|
public SwitchMethodStatus() {
|
||||||
|
super();
|
||||||
|
}
|
||||||
|
|
||||||
|
public SwitchMethodStatus(Integer open) {
|
||||||
|
super();
|
||||||
|
this.open = open;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getOpen() {
|
||||||
|
return open;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setOpen(Integer open) {
|
||||||
|
this.open = open;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,177 @@
|
|||||||
|
package edu.ahbvc.recruit.model;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
public class Thing {
|
||||||
|
/** 岗位id */
|
||||||
|
private int positionId;
|
||||||
|
/** 岗位与批次关系表的主键id */
|
||||||
|
private int recruitId;
|
||||||
|
/** 用户与<岗位批次>关系表的主键id */
|
||||||
|
private int thingId;
|
||||||
|
private String jobTitle;
|
||||||
|
private String code;
|
||||||
|
private Integer ticketNum;
|
||||||
|
private int batchId;
|
||||||
|
private String batchname;
|
||||||
|
private int degree;
|
||||||
|
private int status;
|
||||||
|
private String awardsAndPunishments;
|
||||||
|
private String note;
|
||||||
|
private String qualificationResult;
|
||||||
|
/**
|
||||||
|
* 用户投递时间
|
||||||
|
*/
|
||||||
|
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd,HH-mm-ss")
|
||||||
|
private Date time;
|
||||||
|
/**
|
||||||
|
* 对应用户是否申请过该岗位,无用
|
||||||
|
*/
|
||||||
|
private int ok;
|
||||||
|
|
||||||
|
public Thing() {
|
||||||
|
super();
|
||||||
|
}
|
||||||
|
|
||||||
|
public Thing(int id, int recruitId, String batch, int batchid, int degree, int status,
|
||||||
|
String jobTitle, int ok) {
|
||||||
|
super();
|
||||||
|
this.positionId = id;
|
||||||
|
this.recruitId = recruitId;
|
||||||
|
this.batchname = batch;
|
||||||
|
this.batchId = batchid;
|
||||||
|
this.degree = degree;
|
||||||
|
this.status = status;
|
||||||
|
this.jobTitle = jobTitle;
|
||||||
|
this.ok = ok;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getPositionId() {
|
||||||
|
return positionId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPositionId(int id) {
|
||||||
|
this.positionId = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getRecruitId() {
|
||||||
|
return recruitId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setRecruitId(int recruitId) {
|
||||||
|
this.recruitId = recruitId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getThingId() {
|
||||||
|
return thingId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setThingId(int thingId) {
|
||||||
|
this.thingId = thingId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCode() {
|
||||||
|
return code;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCode(String code) {
|
||||||
|
this.code = code;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getTicketNum() {
|
||||||
|
return ticketNum;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setTicketNum(Integer ticketNum) {
|
||||||
|
this.ticketNum = ticketNum;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getStatus() {
|
||||||
|
return status;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setStatus(int status) {
|
||||||
|
this.status = status;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getBatchname() {
|
||||||
|
return batchname;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setBatchname(String batch) {
|
||||||
|
this.batchname = batch;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getDegree() {
|
||||||
|
return degree;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDegree(int degree) {
|
||||||
|
this.degree = degree;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getJobTitle() {
|
||||||
|
return jobTitle;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setJobTitle(String jobTitle) {
|
||||||
|
this.jobTitle = jobTitle;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getOk() {
|
||||||
|
return ok;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setOk(int ok) {
|
||||||
|
this.ok = ok;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getBatchId() {
|
||||||
|
return batchId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setBatchId(int batchid) {
|
||||||
|
this.batchId = batchid;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getAwardsAndPunishments() {
|
||||||
|
return awardsAndPunishments;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setAwardsAndPunishments(String awardsAndPunishments) {
|
||||||
|
this.awardsAndPunishments = awardsAndPunishments;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getNote() {
|
||||||
|
return note;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setNote(String note) {
|
||||||
|
this.note = note;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getQualificationResult() {
|
||||||
|
return qualificationResult;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setQualificationResult(String qualificationResult) {
|
||||||
|
this.qualificationResult = qualificationResult;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Date getTime() {
|
||||||
|
return time;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setTime(Date time) {
|
||||||
|
this.time = time;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return "TableDataThing [positionId=" + positionId + "," + jobTitle + ", batchname=" + batchname + ", degree=" + degree
|
||||||
|
+ ", status=" + status + ", ok=" + ok + "]";
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,46 @@
|
|||||||
|
package edu.ahbvc.recruit.model;
|
||||||
|
|
||||||
|
public class ThingWithUser extends Thing{
|
||||||
|
|
||||||
|
private String username;
|
||||||
|
private int userId;
|
||||||
|
|
||||||
|
public ThingWithUser() {
|
||||||
|
super();
|
||||||
|
}
|
||||||
|
|
||||||
|
public ThingWithUser(int id, int recruitId, String batch, int batchId, int degree, int status,
|
||||||
|
String department, String jobTitle, int ok) {
|
||||||
|
super(id, recruitId, batch, batchId, degree, status, jobTitle, ok);
|
||||||
|
}
|
||||||
|
|
||||||
|
public ThingWithUser(String username, int userId) {
|
||||||
|
super();
|
||||||
|
this.username = username;
|
||||||
|
this.userId = userId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getUsername() {
|
||||||
|
return username;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setUsername(String username) {
|
||||||
|
this.username = username;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getUserId() {
|
||||||
|
return userId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setUserId(int userId) {
|
||||||
|
this.userId = userId;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return "TableDataThingWithUser [username=" + username + ", userId=" + userId + "]";
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,40 @@
|
|||||||
|
package edu.ahbvc.recruit.model.api;
|
||||||
|
|
||||||
|
public class ImageCaptchaResponse {
|
||||||
|
/**
|
||||||
|
* API响应状态码
|
||||||
|
*/
|
||||||
|
public String statusCode;
|
||||||
|
/**
|
||||||
|
* 状态码说明
|
||||||
|
*/
|
||||||
|
public String desc;
|
||||||
|
/**
|
||||||
|
* 接口的返回信息
|
||||||
|
*/
|
||||||
|
public VerifyCodeResponse result;
|
||||||
|
|
||||||
|
public String getStatusCode() {
|
||||||
|
return statusCode;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setStatusCode(String statusCode) {
|
||||||
|
this.statusCode = statusCode;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getDesc() {
|
||||||
|
return desc;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDesc(String desc) {
|
||||||
|
this.desc = desc;
|
||||||
|
}
|
||||||
|
|
||||||
|
public VerifyCodeResponse getResult() {
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setResult(VerifyCodeResponse result) {
|
||||||
|
this.result = result;
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,63 @@
|
|||||||
|
package edu.ahbvc.recruit.model.api;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* API响应数据模型
|
||||||
|
* 用于封装API响应数据
|
||||||
|
* 使用于发短信验证码的API响应
|
||||||
|
*
|
||||||
|
* @author c215
|
||||||
|
*/
|
||||||
|
public class SMApiResponse {
|
||||||
|
// 响应状态码
|
||||||
|
public String code;
|
||||||
|
// 响应消息
|
||||||
|
@JsonProperty("msg")
|
||||||
|
public String message;
|
||||||
|
// 短信验证码UUID
|
||||||
|
@JsonProperty("smUuid")
|
||||||
|
public String smUuid;
|
||||||
|
|
||||||
|
// 构造函数
|
||||||
|
public SMApiResponse() {
|
||||||
|
super();
|
||||||
|
}
|
||||||
|
|
||||||
|
// getter方法
|
||||||
|
public String getCode() {
|
||||||
|
return code;
|
||||||
|
}
|
||||||
|
|
||||||
|
// setter方法
|
||||||
|
public void setCode(String code) {
|
||||||
|
this.code = code;
|
||||||
|
}
|
||||||
|
|
||||||
|
// getter方法
|
||||||
|
public String getMessage() {
|
||||||
|
return message;
|
||||||
|
}
|
||||||
|
|
||||||
|
// setter方法
|
||||||
|
public void setMessage(String message) {
|
||||||
|
this.message = message;
|
||||||
|
}
|
||||||
|
|
||||||
|
// getter方法
|
||||||
|
public String getSmUuid() {
|
||||||
|
return smUuid;
|
||||||
|
}
|
||||||
|
|
||||||
|
// setter方法
|
||||||
|
public void setSmUuid(String smUuid) {
|
||||||
|
this.smUuid = smUuid;
|
||||||
|
}
|
||||||
|
|
||||||
|
// 重写toString方法
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return "APIVerifyCodeResponse [code=" + code + ", message=" + message + ", data=" + smUuid + "]";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,209 @@
|
|||||||
|
package edu.ahbvc.recruit.model.export;
|
||||||
|
|
||||||
|
import edu.ahbvc.recruit.model.resume.Education;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Excel 导出总表数据模型
|
||||||
|
* @author c215
|
||||||
|
*/
|
||||||
|
public class Excel {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 序号
|
||||||
|
*/
|
||||||
|
protected int no;
|
||||||
|
/**
|
||||||
|
* 用户id
|
||||||
|
*/
|
||||||
|
protected int userid;
|
||||||
|
/**
|
||||||
|
* 岗位代码
|
||||||
|
*/
|
||||||
|
protected String code;
|
||||||
|
/**
|
||||||
|
* 姓名
|
||||||
|
*/
|
||||||
|
protected String name;
|
||||||
|
/**
|
||||||
|
* 性别
|
||||||
|
*/
|
||||||
|
protected int sex;
|
||||||
|
/**
|
||||||
|
* 出生日期
|
||||||
|
*/
|
||||||
|
protected String birthday;
|
||||||
|
/**
|
||||||
|
* 身份证号
|
||||||
|
*/
|
||||||
|
protected String idnum;
|
||||||
|
/**
|
||||||
|
* 教育经历
|
||||||
|
*/
|
||||||
|
protected ArrayList<Education> education;
|
||||||
|
/**
|
||||||
|
* 政治面貌
|
||||||
|
*/
|
||||||
|
protected String zzmm;
|
||||||
|
/**
|
||||||
|
* 民族
|
||||||
|
*/
|
||||||
|
protected String nation;
|
||||||
|
/**
|
||||||
|
* 联系电话
|
||||||
|
*/
|
||||||
|
protected String phone;
|
||||||
|
/**
|
||||||
|
* 状态
|
||||||
|
*/
|
||||||
|
protected int status;
|
||||||
|
/**
|
||||||
|
* 备注
|
||||||
|
*/
|
||||||
|
protected String note;
|
||||||
|
|
||||||
|
public Excel() {
|
||||||
|
super();
|
||||||
|
}
|
||||||
|
|
||||||
|
public Excel(int no, String code, String name, int sex, String birthday, String idnum,
|
||||||
|
ArrayList<Education> education, String zzmm, String nation, String phone, int status, String note) {
|
||||||
|
super();
|
||||||
|
this.no = no;
|
||||||
|
this.code = code;
|
||||||
|
this.name = name;
|
||||||
|
this.sex = sex;
|
||||||
|
this.birthday = birthday;
|
||||||
|
this.idnum = idnum;
|
||||||
|
this.education = education;
|
||||||
|
this.zzmm = zzmm;
|
||||||
|
this.nation = nation;
|
||||||
|
this.phone = phone;
|
||||||
|
this.status = status;
|
||||||
|
this.note = note;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getNo() {
|
||||||
|
return no;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setNo(int no) {
|
||||||
|
this.no = no;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getUserid() {
|
||||||
|
return userid;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setUserid(int userid) {
|
||||||
|
this.userid = userid;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCode() {
|
||||||
|
return code;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCode(String code) {
|
||||||
|
this.code = code;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getName() {
|
||||||
|
return name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setName(String name) {
|
||||||
|
this.name = name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getSex() {
|
||||||
|
return sex;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setSex(int sex) {
|
||||||
|
this.sex = sex;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getBirthday() {
|
||||||
|
return birthday;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setBirthday(String birthday) {
|
||||||
|
this.birthday = birthday;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getIdnum() {
|
||||||
|
return idnum;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setIdnum(String idnum) {
|
||||||
|
this.idnum = idnum;
|
||||||
|
}
|
||||||
|
|
||||||
|
public ArrayList<Education> getEducation() {
|
||||||
|
return education;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setEducation(ArrayList<Education> education) {
|
||||||
|
this.education = education;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getZzmm() {
|
||||||
|
return zzmm;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setZzmm(String zzmm) {
|
||||||
|
this.zzmm = zzmm;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getNation() {
|
||||||
|
return nation;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setNation(String nation) {
|
||||||
|
this.nation = nation;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getPhone() {
|
||||||
|
return phone;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPhone(String phone) {
|
||||||
|
this.phone = phone;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getStatus() {
|
||||||
|
return status;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setStatus(int status) {
|
||||||
|
this.status = status;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getNote() {
|
||||||
|
return note;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setNote(String note) {
|
||||||
|
this.note = note;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return "Excel{" +
|
||||||
|
"no=" + no +
|
||||||
|
", userid=" + userid +
|
||||||
|
", code='" + code + '\'' +
|
||||||
|
", name='" + name + '\'' +
|
||||||
|
", sex=" + sex +
|
||||||
|
", birthday='" + birthday + '\'' +
|
||||||
|
", idnum='" + idnum + '\'' +
|
||||||
|
", education=" + education +
|
||||||
|
", zzmm='" + zzmm + '\'' +
|
||||||
|
", nation='" + nation + '\'' +
|
||||||
|
", phone='" + phone + '\'' +
|
||||||
|
", status=" + status +
|
||||||
|
", note='" + note + '\'' +
|
||||||
|
'}';
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,88 @@
|
|||||||
|
package edu.ahbvc.recruit.model.export;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 准考证数据模型
|
||||||
|
* 用于封装准考证相关信息
|
||||||
|
* @author c215
|
||||||
|
*/
|
||||||
|
public class Ticket {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 岗位代码
|
||||||
|
*/
|
||||||
|
protected String code;
|
||||||
|
/**
|
||||||
|
* 准考证号
|
||||||
|
*/
|
||||||
|
protected String ticketNumber;
|
||||||
|
protected String name;
|
||||||
|
protected String tel;
|
||||||
|
protected String idnum;
|
||||||
|
protected String department;
|
||||||
|
protected String batch;
|
||||||
|
|
||||||
|
|
||||||
|
public Ticket() {
|
||||||
|
super();
|
||||||
|
}
|
||||||
|
public Ticket(String myindex, String myindexWithUser, String name, String tel, String idnum,
|
||||||
|
String department, String batch) {
|
||||||
|
super();
|
||||||
|
this.code = myindex;
|
||||||
|
this.ticketNumber = myindexWithUser;
|
||||||
|
this.name = name;
|
||||||
|
this.tel = tel;
|
||||||
|
this.idnum = idnum;
|
||||||
|
this.department = department;
|
||||||
|
this.batch = batch;
|
||||||
|
}
|
||||||
|
public String getCode() {
|
||||||
|
return code;
|
||||||
|
}
|
||||||
|
public void setCode(String myindex) {
|
||||||
|
this.code = myindex;
|
||||||
|
}
|
||||||
|
public String getTicketNumber() {
|
||||||
|
return ticketNumber;
|
||||||
|
}
|
||||||
|
public void setTicketNumber(String myindexWithUser) {
|
||||||
|
this.ticketNumber = myindexWithUser;
|
||||||
|
}
|
||||||
|
public String getName() {
|
||||||
|
return name;
|
||||||
|
}
|
||||||
|
public void setName(String name) {
|
||||||
|
this.name = name;
|
||||||
|
}
|
||||||
|
public String getTel() {
|
||||||
|
return tel;
|
||||||
|
}
|
||||||
|
public void setTel(String tel) {
|
||||||
|
this.tel = tel;
|
||||||
|
}
|
||||||
|
public String getIdnum() {
|
||||||
|
return idnum;
|
||||||
|
}
|
||||||
|
public void setIdnum(String idnum) {
|
||||||
|
this.idnum = idnum;
|
||||||
|
}
|
||||||
|
public String getDepartment() {
|
||||||
|
return department;
|
||||||
|
}
|
||||||
|
public void setDepartment(String department) {
|
||||||
|
this.department = department;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getBatch() {
|
||||||
|
return batch;
|
||||||
|
}
|
||||||
|
public void setBatch(String batch) {
|
||||||
|
this.batch = batch;
|
||||||
|
}
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return "PrintCertificate [code=" + code + ", ticketNumber=" + ticketNumber + ", name=" + name
|
||||||
|
+ ", tel=" + tel + ", idnum=" + idnum + ", department=" + department + ", batch=" + batch + "]";
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,56 @@
|
|||||||
|
package edu.ahbvc.recruit.model.page;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页工具类
|
||||||
|
* @author c215
|
||||||
|
*/
|
||||||
|
public class Page {
|
||||||
|
/**
|
||||||
|
* 当前页码
|
||||||
|
*/
|
||||||
|
protected int currentPage;
|
||||||
|
/**
|
||||||
|
* 每页显示的记录数
|
||||||
|
*/
|
||||||
|
protected int size;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 无参构造函数
|
||||||
|
*/
|
||||||
|
public Page() {
|
||||||
|
super();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 有参构造函数
|
||||||
|
* @param currentPage 当前页码
|
||||||
|
* @param size 每页显示的记录数
|
||||||
|
*/
|
||||||
|
public Page(int currentPage, int size) {
|
||||||
|
super();
|
||||||
|
this.currentPage = currentPage;
|
||||||
|
this.size = size;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getCurrentPage() {
|
||||||
|
return currentPage;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCurrentPage(int currentPage) {
|
||||||
|
this.currentPage = currentPage;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getSize() {
|
||||||
|
return size;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setSize(int size) {
|
||||||
|
this.size = size;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return "PageUtil [currentPage=" + currentPage + ", size=" + size + "]";
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,51 @@
|
|||||||
|
package edu.ahbvc.recruit.model.page;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author c215
|
||||||
|
*/
|
||||||
|
public class SearchAndPageOfAdmin extends Page {
|
||||||
|
/**
|
||||||
|
* 姓名
|
||||||
|
*/
|
||||||
|
protected String name;
|
||||||
|
/**
|
||||||
|
* 电话
|
||||||
|
*/
|
||||||
|
protected String phone;
|
||||||
|
|
||||||
|
public SearchAndPageOfAdmin() {
|
||||||
|
super();
|
||||||
|
}
|
||||||
|
|
||||||
|
public SearchAndPageOfAdmin(int currentPage, int size) {
|
||||||
|
super(currentPage, size);
|
||||||
|
}
|
||||||
|
|
||||||
|
public SearchAndPageOfAdmin(String name, String phone) {
|
||||||
|
super();
|
||||||
|
this.name = name;
|
||||||
|
this.phone = phone;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getName() {
|
||||||
|
return name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setName(String key) {
|
||||||
|
this.name = key;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getPhone() {
|
||||||
|
return phone;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPhone(String phone) {
|
||||||
|
this.phone = phone;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return "SearchAndPageOfAdmin [name=" + name + ", phone=" + phone + "]";
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,52 @@
|
|||||||
|
package edu.ahbvc.recruit.model.page;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 搜索和分页工具类
|
||||||
|
* @author c215
|
||||||
|
*/
|
||||||
|
public class SearchAndPageOfBatches extends Page {
|
||||||
|
/**
|
||||||
|
* 关键字
|
||||||
|
*/
|
||||||
|
protected String key;
|
||||||
|
/**
|
||||||
|
* 状态
|
||||||
|
*/
|
||||||
|
protected Integer state;
|
||||||
|
|
||||||
|
public SearchAndPageOfBatches() {
|
||||||
|
super();
|
||||||
|
}
|
||||||
|
|
||||||
|
public SearchAndPageOfBatches(int currentPage, int size) {
|
||||||
|
super(currentPage, size);
|
||||||
|
}
|
||||||
|
|
||||||
|
public SearchAndPageOfBatches(String key, Integer state) {
|
||||||
|
super();
|
||||||
|
this.key = key;
|
||||||
|
this.state = state;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getKey() {
|
||||||
|
return key;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setKey(String key) {
|
||||||
|
this.key = key;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getState() {
|
||||||
|
return state;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setState(Integer state) {
|
||||||
|
this.state = state;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return "SearchAndPageOfBatches [key=" + key + ", state=" + state + "]";
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,39 @@
|
|||||||
|
package edu.ahbvc.recruit.model.page;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 搜索和分页工具类
|
||||||
|
* @author c215
|
||||||
|
*/
|
||||||
|
public class SearchAndPageOfDepartment extends Page {
|
||||||
|
/**
|
||||||
|
* 关键字
|
||||||
|
*/
|
||||||
|
protected String key;
|
||||||
|
|
||||||
|
public SearchAndPageOfDepartment() {
|
||||||
|
super();
|
||||||
|
}
|
||||||
|
|
||||||
|
public SearchAndPageOfDepartment(int currentPage, int size) {
|
||||||
|
super(currentPage, size);
|
||||||
|
}
|
||||||
|
|
||||||
|
public SearchAndPageOfDepartment(String key) {
|
||||||
|
super();
|
||||||
|
this.key = key;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getKey() {
|
||||||
|
return key;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setKey(String key) {
|
||||||
|
this.key = key;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return "SearchAndPageOfDepartment [key=" + key + "]";
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,31 @@
|
|||||||
|
package edu.ahbvc.recruit.model.page;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 搜索和分页工具类
|
||||||
|
* @author c215
|
||||||
|
*/
|
||||||
|
public class SearchAndPageOfPosition extends Page {
|
||||||
|
/**
|
||||||
|
* 关键字
|
||||||
|
*/
|
||||||
|
private List<Integer> departments;
|
||||||
|
|
||||||
|
public SearchAndPageOfPosition() {
|
||||||
|
super();
|
||||||
|
}
|
||||||
|
|
||||||
|
public SearchAndPageOfPosition(int currentPage, int size) {
|
||||||
|
super(currentPage, size);
|
||||||
|
}
|
||||||
|
|
||||||
|
public List<Integer> getDepartments() {
|
||||||
|
return departments;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDepartments(List<Integer> departments) {
|
||||||
|
this.departments = departments;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,40 @@
|
|||||||
|
package edu.ahbvc.recruit.model.page;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 搜索和分页工具类
|
||||||
|
* @author c215
|
||||||
|
*/
|
||||||
|
public class SearchAndPageOfPositionByUser extends Page {
|
||||||
|
|
||||||
|
public String code;
|
||||||
|
public int batchId;
|
||||||
|
|
||||||
|
|
||||||
|
public SearchAndPageOfPositionByUser() {
|
||||||
|
super();
|
||||||
|
}
|
||||||
|
public SearchAndPageOfPositionByUser(int currentPage, int size) {
|
||||||
|
super(currentPage, size);
|
||||||
|
}
|
||||||
|
public SearchAndPageOfPositionByUser(String code, int batchId) {
|
||||||
|
super();
|
||||||
|
this.code = code;
|
||||||
|
this.batchId = batchId;
|
||||||
|
}
|
||||||
|
public String getCode() {
|
||||||
|
return code;
|
||||||
|
}
|
||||||
|
public void setCode(String code) {
|
||||||
|
this.code = code;
|
||||||
|
}
|
||||||
|
public int getBatchId() {
|
||||||
|
return batchId;
|
||||||
|
}
|
||||||
|
public void setBatchId(int batchId) {
|
||||||
|
this.batchId = batchId;
|
||||||
|
}
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return "SearchAndPageOfPositionByUser [code=" + code + ", batchId=" + batchId + "]";
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,102 @@
|
|||||||
|
package edu.ahbvc.recruit.model.page;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 搜索和分页工具类
|
||||||
|
* @author c215
|
||||||
|
*/
|
||||||
|
public class SearchAndPageOfResult extends Page {
|
||||||
|
/**
|
||||||
|
* 批次列表
|
||||||
|
*/
|
||||||
|
private List<Integer> batches;
|
||||||
|
/**
|
||||||
|
* 职位列表
|
||||||
|
*/
|
||||||
|
private List<Integer> jobTitles;
|
||||||
|
/**
|
||||||
|
* 状态列表
|
||||||
|
*/
|
||||||
|
private List<Integer> status;
|
||||||
|
/**
|
||||||
|
* 关键字
|
||||||
|
*/
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
public SearchAndPageOfResult() {
|
||||||
|
super();
|
||||||
|
}
|
||||||
|
|
||||||
|
public SearchAndPageOfResult(int currentPage, int size, List<Integer> batches, List<Integer> jobTitles,
|
||||||
|
List<Integer> departments) {
|
||||||
|
super();
|
||||||
|
super.currentPage = currentPage;
|
||||||
|
super.size = size;
|
||||||
|
this.batches = batches;
|
||||||
|
this.jobTitles = jobTitles;
|
||||||
|
this.status = departments;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int getCurrentPage() {
|
||||||
|
return super.getCurrentPage();
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void setCurrentPage(int currentPage) {
|
||||||
|
super.setCurrentPage(currentPage);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int getSize() {
|
||||||
|
return super.getSize();
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void setSize(int size) {
|
||||||
|
super.setSize(size);
|
||||||
|
}
|
||||||
|
|
||||||
|
public List<Integer> getBatches() {
|
||||||
|
return batches;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setBatches(List<Integer> batches) {
|
||||||
|
this.batches = batches;
|
||||||
|
}
|
||||||
|
|
||||||
|
public List<Integer> getJobTitles() {
|
||||||
|
return jobTitles;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setJobTitles(List<Integer> jobTitles) {
|
||||||
|
this.jobTitles = jobTitles;
|
||||||
|
}
|
||||||
|
|
||||||
|
public List<Integer> getStatus() {
|
||||||
|
return status;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setStatus(List<Integer> departments) {
|
||||||
|
this.status = departments;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getName() {
|
||||||
|
return name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setName(String name) {
|
||||||
|
this.name = name;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
final int maxLen = 10;
|
||||||
|
return "SearchAndPageOfResult [batches="
|
||||||
|
+ (batches != null ? batches.subList(0, Math.min(batches.size(), maxLen)) : null) + ", jobTitles="
|
||||||
|
+ (jobTitles != null ? jobTitles.subList(0, Math.min(jobTitles.size(), maxLen)) : null)
|
||||||
|
+ ", status="
|
||||||
|
+ (status != null ? status.subList(0, Math.min(status.size(), maxLen)) : null) + "]";
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,79 @@
|
|||||||
|
package edu.ahbvc.recruit.model.page;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 搜索和分页工具类
|
||||||
|
* @author c215
|
||||||
|
*/
|
||||||
|
public class SearchAndPageOfUsers extends Page {
|
||||||
|
/**
|
||||||
|
* 关键字
|
||||||
|
*/
|
||||||
|
protected String name;
|
||||||
|
/**
|
||||||
|
* 手机号
|
||||||
|
*/
|
||||||
|
protected String phone;
|
||||||
|
/**
|
||||||
|
* 身份证号
|
||||||
|
*/
|
||||||
|
protected String idnum;
|
||||||
|
/**
|
||||||
|
* 学历
|
||||||
|
*/
|
||||||
|
protected Integer degree;
|
||||||
|
|
||||||
|
public SearchAndPageOfUsers() {
|
||||||
|
super();
|
||||||
|
}
|
||||||
|
|
||||||
|
public SearchAndPageOfUsers(int currentPage, int size) {
|
||||||
|
super(currentPage, size);
|
||||||
|
}
|
||||||
|
|
||||||
|
public SearchAndPageOfUsers(String name, String tel, String idnum, Integer degree) {
|
||||||
|
super();
|
||||||
|
this.name = name;
|
||||||
|
this.phone = tel;
|
||||||
|
this.idnum = idnum;
|
||||||
|
this.degree = degree;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getName() {
|
||||||
|
return name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setName(String name) {
|
||||||
|
this.name = name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getPhone() {
|
||||||
|
return phone;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPhone(String phone) {
|
||||||
|
this.phone = phone;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getIdnum() {
|
||||||
|
return idnum;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setIdnum(String idnum) {
|
||||||
|
this.idnum = idnum;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getDegree() {
|
||||||
|
return degree;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDegree(Integer degree) {
|
||||||
|
this.degree = degree;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return "SearchAndPageOfUsers [name=" + name + ", phone=" + phone + ", idnum=" + idnum + ", degree=" + degree
|
||||||
|
+ "]";
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,70 @@
|
|||||||
|
package edu.ahbvc.recruit.model.resume;
|
||||||
|
|
||||||
|
public class Education {
|
||||||
|
private int id;
|
||||||
|
private String school;
|
||||||
|
private String graduationTime;
|
||||||
|
private int degree;
|
||||||
|
private int education;
|
||||||
|
private String specialty;
|
||||||
|
|
||||||
|
public int getId() {
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setId(int id) {
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getSchool() {
|
||||||
|
return school;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setSchool(String school) {
|
||||||
|
this.school = school;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getGraduationTime() {
|
||||||
|
return graduationTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setGraduationTime(String graduationTime) {
|
||||||
|
this.graduationTime = graduationTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getDegree() {
|
||||||
|
return degree;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDegree(int degree) {
|
||||||
|
this.degree = degree;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getEducation() {
|
||||||
|
return education;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setEducation(int education) {
|
||||||
|
this.education = education;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getSpecialty() {
|
||||||
|
return specialty;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setSpecialty(String specialty) {
|
||||||
|
this.specialty = specialty;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return "Education{" +
|
||||||
|
"id=" + id +
|
||||||
|
", school='" + school + '\'' +
|
||||||
|
", graduationTime='" + graduationTime + '\'' +
|
||||||
|
", degree=" + degree +
|
||||||
|
", education=" + education +
|
||||||
|
", specialty='" + specialty + '\'' +
|
||||||
|
'}';
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,54 @@
|
|||||||
|
package edu.ahbvc.recruit.model.resume;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author c215
|
||||||
|
*/
|
||||||
|
public class FamilyConnections {
|
||||||
|
|
||||||
|
private int id;
|
||||||
|
private String name;
|
||||||
|
private String connection;
|
||||||
|
private String work;
|
||||||
|
|
||||||
|
public int getId() {
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setId(int id) {
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getName() {
|
||||||
|
return name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setName(String name) {
|
||||||
|
this.name = name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getConnection() {
|
||||||
|
return connection;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setConnection(String connection) {
|
||||||
|
this.connection = connection;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getWork() {
|
||||||
|
return work;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setWork(String work) {
|
||||||
|
this.work = work;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return "FamilyConnections{" +
|
||||||
|
"id=" + id +
|
||||||
|
", name='" + name + '\'' +
|
||||||
|
", connection='" + connection + '\'' +
|
||||||
|
", work='" + work + '\'' +
|
||||||
|
'}';
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,73 @@
|
|||||||
|
package edu.ahbvc.recruit.model.resume;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author c215
|
||||||
|
*/
|
||||||
|
public class Paper {
|
||||||
|
private int id;
|
||||||
|
private String journal;
|
||||||
|
private String title;
|
||||||
|
private String time;
|
||||||
|
private String journalNum;
|
||||||
|
public Paper() {
|
||||||
|
}
|
||||||
|
|
||||||
|
public Paper(int id, String journal, String title, String time, String journalNum) {
|
||||||
|
this.id = id;
|
||||||
|
this.journal = journal;
|
||||||
|
this.title = title;
|
||||||
|
this.time = time;
|
||||||
|
this.journalNum = journalNum;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getId() {
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setId(int id) {
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getJournal() {
|
||||||
|
return journal;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setJournal(String journal) {
|
||||||
|
this.journal = journal;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getTitle() {
|
||||||
|
return title;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setTitle(String title) {
|
||||||
|
this.title = title;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getTime() {
|
||||||
|
return time;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setTime(String time) {
|
||||||
|
this.time = time;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getJournalNum() {
|
||||||
|
return journalNum;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setJournalNum(String journalNum) {
|
||||||
|
this.journalNum = journalNum;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return "Paper{" +
|
||||||
|
"id=" + id +
|
||||||
|
", journal='" + journal + '\'' +
|
||||||
|
", title='" + title + '\'' +
|
||||||
|
", time='" + time + '\'' +
|
||||||
|
", journalNum='" + journalNum + '\'' +
|
||||||
|
'}';
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,73 @@
|
|||||||
|
package edu.ahbvc.recruit.model.resume;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author c215
|
||||||
|
*/
|
||||||
|
public class Project {
|
||||||
|
private int id;
|
||||||
|
private int type;
|
||||||
|
private String time;
|
||||||
|
private String title;
|
||||||
|
private String level;
|
||||||
|
private String rank;
|
||||||
|
|
||||||
|
public int getId() {
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setId(int id) {
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getType() {
|
||||||
|
return type;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setType(int type) {
|
||||||
|
this.type = type;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getTime() {
|
||||||
|
return time;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setTime(String time) {
|
||||||
|
this.time = time;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getTitle() {
|
||||||
|
return title;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setTitle(String title) {
|
||||||
|
this.title = title;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getLevel() {
|
||||||
|
return level;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setLevel(String level) {
|
||||||
|
this.level = level;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getRank() {
|
||||||
|
return rank;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setRank(String rank) {
|
||||||
|
this.rank = rank;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return "Project{" +
|
||||||
|
"id=" + id +
|
||||||
|
", type=" + type +
|
||||||
|
", time='" + time + '\'' +
|
||||||
|
", title='" + title + '\'' +
|
||||||
|
", level='" + level + '\'' +
|
||||||
|
", rank='" + rank + '\'' +
|
||||||
|
'}';
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,33 @@
|
|||||||
|
package edu.ahbvc.recruit.model.resume;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author c215
|
||||||
|
*/
|
||||||
|
public class Research {
|
||||||
|
private int id;
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
public int getId() {
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setId(int id) {
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getName() {
|
||||||
|
return name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setName(String name) {
|
||||||
|
this.name = name;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return "Research{" +
|
||||||
|
"id=" + id +
|
||||||
|
", name='" + name + '\'' +
|
||||||
|
'}';
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,162 @@
|
|||||||
|
package edu.ahbvc.recruit.model.resume;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author c215
|
||||||
|
*/
|
||||||
|
public class UserInfo {
|
||||||
|
private int id;
|
||||||
|
private String name;
|
||||||
|
private int sex;
|
||||||
|
private String phone;
|
||||||
|
private String birthPlace;
|
||||||
|
private String nation;
|
||||||
|
private String politicalStatus;
|
||||||
|
private String email;
|
||||||
|
private String birthday;
|
||||||
|
private String idNum;
|
||||||
|
private String married;
|
||||||
|
/**
|
||||||
|
* 户口所在地
|
||||||
|
*/
|
||||||
|
private String nativePlace;
|
||||||
|
/**
|
||||||
|
* 家庭详细地址
|
||||||
|
*/
|
||||||
|
private String address;
|
||||||
|
/**
|
||||||
|
* 曾获何种专业证书,有何特长
|
||||||
|
*/
|
||||||
|
private String specialtiesCertificates;
|
||||||
|
|
||||||
|
public int getId() {
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setId(int id) {
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getName() {
|
||||||
|
return name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setName(String name) {
|
||||||
|
this.name = name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int getSex() {
|
||||||
|
return sex;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setSex(int sex) {
|
||||||
|
this.sex = sex;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getPhone() {
|
||||||
|
return phone;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPhone(String phone) {
|
||||||
|
this.phone = phone;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getBirthPlace() {
|
||||||
|
return birthPlace;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setBirthPlace(String birthPlace) {
|
||||||
|
this.birthPlace = birthPlace;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getNation() {
|
||||||
|
return nation;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setNation(String nation) {
|
||||||
|
this.nation = nation;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getPoliticalStatus() {
|
||||||
|
return politicalStatus;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPoliticalStatus(String politicalStatus) {
|
||||||
|
this.politicalStatus = politicalStatus;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getEmail() {
|
||||||
|
return email;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setEmail(String email) {
|
||||||
|
this.email = email;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getBirthday() {
|
||||||
|
return birthday;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setBirthday(String birthday) {
|
||||||
|
this.birthday = birthday;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getIdNum() {
|
||||||
|
return idNum;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setIdNum(String idNum) {
|
||||||
|
this.idNum = idNum;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getMarried() {
|
||||||
|
return married;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setMarried(String married) {
|
||||||
|
this.married = married;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getNativePlace() {
|
||||||
|
return nativePlace;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setNativePlace(String nativePlace) {
|
||||||
|
this.nativePlace = nativePlace;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getAddress() {
|
||||||
|
return address;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setAddress(String address) {
|
||||||
|
this.address = address;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getSpecialtiesCertificates() {
|
||||||
|
return specialtiesCertificates;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setSpecialtiesCertificates(String specialtiesCertificates) {
|
||||||
|
this.specialtiesCertificates = specialtiesCertificates;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return "UserInfo{" +
|
||||||
|
"id=" + id +
|
||||||
|
", name='" + name + '\'' +
|
||||||
|
", sex=" + sex +
|
||||||
|
", phone='" + phone + '\'' +
|
||||||
|
", birthPlace='" + birthPlace + '\'' +
|
||||||
|
", nation='" + nation + '\'' +
|
||||||
|
", zzmm='" + politicalStatus + '\'' +
|
||||||
|
", email='" + email + '\'' +
|
||||||
|
", birthday='" + birthday + '\'' +
|
||||||
|
", idNum='" + idNum + '\'' +
|
||||||
|
", married='" + married + '\'' +
|
||||||
|
", nativePlace='" + nativePlace + '\'' +
|
||||||
|
", address='" + address + '\'' +
|
||||||
|
", specialtiesCertificates='" + specialtiesCertificates + '\'' +
|
||||||
|
'}';
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,62 @@
|
|||||||
|
package edu.ahbvc.recruit.model.resume;
|
||||||
|
/**
|
||||||
|
* @author c215
|
||||||
|
*/
|
||||||
|
public class WorkExperience {
|
||||||
|
private int id;
|
||||||
|
private String company;
|
||||||
|
private String workTimeStart;
|
||||||
|
private String workTimeEnd;
|
||||||
|
private String position;
|
||||||
|
|
||||||
|
public int getId() {
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setId(int id) {
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCompany() {
|
||||||
|
return company;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCompany(String company) {
|
||||||
|
this.company = company;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getWorkTimeStart() {
|
||||||
|
return workTimeStart;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setWorkTimeStart(String workTimeStart) {
|
||||||
|
this.workTimeStart = workTimeStart;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getWorkTimeEnd() {
|
||||||
|
return workTimeEnd;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setWorkTimeEnd(String workTimeEnd) {
|
||||||
|
this.workTimeEnd = workTimeEnd;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getPosition() {
|
||||||
|
return position;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPosition(String position) {
|
||||||
|
this.position = position;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return "WorkExperience{" +
|
||||||
|
"id=" + id +
|
||||||
|
", company='" + company + '\'' +
|
||||||
|
", workTimeStart='" + workTimeStart + '\'' +
|
||||||
|
", workTimeEnd='" + workTimeEnd + '\'' +
|
||||||
|
", position='" + position + '\'' +
|
||||||
|
'}';
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,35 @@
|
|||||||
|
package edu.ahbvc.recruit.model.token;
|
||||||
|
|
||||||
|
import edu.ahbvc.recruit.mapper.UserInter;
|
||||||
|
import org.springframework.security.core.userdetails.UserDetails;
|
||||||
|
import org.springframework.security.core.userdetails.UserDetailsService;
|
||||||
|
import org.springframework.security.core.userdetails.UsernameNotFoundException;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 利用UserInter实现了UserDetailsService中根据名字找用户的抽象方法
|
||||||
|
* @author c215
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class CustomUserDetailsService implements UserDetailsService {
|
||||||
|
|
||||||
|
// 这个类被注解为Service, 所以会被Spring容器管理
|
||||||
|
// 控制翻转!!!
|
||||||
|
// 依赖注入!!!
|
||||||
|
//
|
||||||
|
// 所以可以自动通过构造函数注入UserInter
|
||||||
|
final UserInter userInter;
|
||||||
|
|
||||||
|
public CustomUserDetailsService(UserInter userInter) {
|
||||||
|
this.userInter = userInter;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public UserDetails loadUserByUsername(String username) throws UsernameNotFoundException{
|
||||||
|
// UserInter中实现了根据名字找用户的方法
|
||||||
|
// 因为JWT认证和更规范的权限管理暂暂未实现,所以此处用不到
|
||||||
|
// SELECT * FROM `user-thing` WHERE `userid` = #{arg0}
|
||||||
|
UserDetails userDetails = userInter.loadUserByUsername(username);
|
||||||
|
return userDetails;
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in new issue