PositionItemInfoController.java 2.02 KB
package com.laowu.controller;


import com.laowu.dto.position.UpdateItemInfoDTO;
import com.laowu.model.PositionItemJobMappingDO;
import com.laowu.service.PositionItemInfoService;
import com.laowu.util.ResponseData;
import com.laowu.util.ResponseVO;
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;

/**
 * <p>
 * 项目职位需求 前端控制器
 * </p>
 *
 * @author Tuyp
 * @since 2023-03-27
 */
@RestController
@Api(tags = "项目职位需求")
@RequestMapping("/positionItemInfo")
public class PositionItemInfoController {

    @Autowired
    private PositionItemInfoService positionItemInfoService;

    @PostMapping("updateItemInfo")
    @ApiOperation("编辑职位信息 id  positionName  positionStatus  requireCounts  positionId  startSalary  endSalary  address  jobIds[] 职位分类 ")
    public ResponseVO updateItemInfo(@RequestBody UpdateItemInfoDTO updateItemInfoDTO){
        return ResponseData.generateCreatedResponse(0,positionItemInfoService.updateItemInfo(updateItemInfoDTO));
    }

    @PostMapping("deleteItemInfo")
    @ApiOperation("删除职位信息  id")
    public ResponseVO deleteItemInfo(@RequestBody PositionItemJobMappingDO positionItemJobMappingDO){
        return ResponseData.generateCreatedResponse(0,positionItemInfoService.deleteItemInfo(positionItemJobMappingDO));
    }

    @PostMapping("addItemInfo")
    @ApiOperation("编辑职位信息 positionRequireId  positionName  positionStatus  requireCount  positionId  startSalary  endSalary  address  jobIds[] 职位分类 ")
    public ResponseVO addItemInfo(@RequestBody UpdateItemInfoDTO updateItemInfoDTO){
        return ResponseData.generateCreatedResponse(0,positionItemInfoService.addItemInfo(updateItemInfoDTO));
    }

}