添加面试邀约接口
This commit is contained in:
@@ -0,0 +1,90 @@
|
||||
package com.ruoyi.cms.controller.cms;
|
||||
|
||||
import com.ruoyi.cms.domain.InterviewInvite;
|
||||
import com.ruoyi.cms.service.InterviewInviteService;
|
||||
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;
|
||||
|
||||
/**
|
||||
* 面试邀约Controller
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/cms/interviewInvite")
|
||||
@Api(tags = "后台:面试邀约")
|
||||
public class InterviewInviteController extends BaseController
|
||||
{
|
||||
@Autowired
|
||||
private InterviewInviteService interviewInviteService;
|
||||
|
||||
/**
|
||||
* 查询面试邀约列表(分页)
|
||||
*/
|
||||
@ApiOperation("查询面试邀约列表")
|
||||
@PreAuthorize("@ss.hasPermi('cms:interviewInvite:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(InterviewInvite interviewInvite)
|
||||
{
|
||||
startPage();
|
||||
List<InterviewInvite> list = interviewInviteService.selectInterviewInviteList(interviewInvite);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取面试邀约详情
|
||||
*/
|
||||
@ApiOperation("获取面试邀约详情")
|
||||
@PreAuthorize("@ss.hasPermi('cms:interviewInvite:query')")
|
||||
@GetMapping(value = "/{id}")
|
||||
public AjaxResult getInfo(@PathVariable("id") Long id)
|
||||
{
|
||||
return AjaxResult.success(interviewInviteService.selectInterviewInviteById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增面试邀约(弹窗保存接口)
|
||||
*/
|
||||
@ApiOperation("新增面试邀约")
|
||||
@PreAuthorize("@ss.hasPermi('cms:interviewInvite:add')")
|
||||
@Log(title = "面试邀约", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody InterviewInvite interviewInvite)
|
||||
{
|
||||
return toAjax(interviewInviteService.insertInterviewInvite(interviewInvite));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改面试邀约
|
||||
*/
|
||||
@ApiOperation("修改面试邀约")
|
||||
@PreAuthorize("@ss.hasPermi('cms:interviewInvite:edit')")
|
||||
@Log(title = "面试邀约", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody InterviewInvite interviewInvite)
|
||||
{
|
||||
return toAjax(interviewInviteService.updateInterviewInvite(interviewInvite));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除面试邀约(逻辑删除)
|
||||
*/
|
||||
@ApiOperation("面试邀约删除")
|
||||
@PreAuthorize("@ss.hasPermi('cms:interviewInvite:remove')")
|
||||
@Log(title = "面试邀约", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public AjaxResult remove(@PathVariable Long[] ids)
|
||||
{
|
||||
return toAjax(interviewInviteService.deleteInterviewInviteByIds(ids));
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user