面试相关接口

This commit is contained in:
俞扬
2023-06-14 10:41:45 +08:00
parent 42dcf14aa9
commit cc118b78fc
11 changed files with 545 additions and 1 deletions

View File

@@ -0,0 +1,70 @@
package com.cool.store.controller;
import com.cool.store.request.*;
import com.cool.store.response.ResponseResult;
import com.cool.store.service.InterviewService;
import com.cool.store.vo.interview.InterviewVO;
import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import java.util.List;
/**
* @Author: young.yu
* @Date: 2023-06-06 15:22
* @Description:
*/
@RestController
@RequestMapping("/interview")
@Api(tags = "面试信息")
public class InterviewController {
@Autowired
private InterviewService interviewService;
@PostMapping("/list")
@ApiOperation("获取面试信息列表")
public ResponseResult<PageInfo<InterviewVO>> getInterviewList(@RequestBody GetInterviewListReq request) {
PageHelper.startPage(request.getPageNum(), request.getPageSize());
List<InterviewVO> interviewList = interviewService.getInterviewList(request);
return ResponseResult.success(new PageInfo<>(interviewList));
}
@PostMapping("/queryByInterviewId")
@ApiOperation("根据面试会议id查询面试信息")
public ResponseResult<InterviewVO> queryByInterviewId(@RequestBody QueryByInterviewIdReq request) {
InterviewVO interviewVO = interviewService.getInterviewInfo(request.getInterviewId());
return ResponseResult.success(interviewVO);
}
@PostMapping("/entrustOthers")
@ApiOperation("委托他人")
public ResponseResult entrustOthers(@RequestBody EntrustOthersReq request) {
interviewService.entrustOthers(request);
return ResponseResult.success();
}
@PostMapping("/modifyInterviewTime")
@ApiOperation("修改面试时间")
public ResponseResult modifyInterviewTime(@RequestBody ModifyInterviewTimeReq request) {
interviewService.modifyInterviewTime(request);
return ResponseResult.success();
}
@PostMapping("/finish")
@ApiOperation("修改面试时间")
public ResponseResult finishInterview(@RequestBody FinishInterviewReq request) {
interviewService.finishInterview(request);
return ResponseResult.success();
}
}