package com.gkhy.exam.admin.controller.web;
|
|
|
import com.gkhy.exam.common.annotation.RepeatSubmit;
|
import com.gkhy.exam.common.api.CommonResult;
|
import com.gkhy.exam.system.domain.ManagementReview;
|
import com.gkhy.exam.system.service.ManagementReviewService;
|
import io.swagger.annotations.Api;
|
import io.swagger.annotations.ApiImplicitParam;
|
import io.swagger.annotations.ApiImplicitParams;
|
import io.swagger.annotations.ApiOperation;
|
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.validation.annotation.Validated;
|
import org.springframework.web.bind.annotation.*;
|
|
/**
|
* <p>
|
* 管理评审会议、输入、报告 前端控制器
|
* </p>
|
*
|
* @author hh
|
* @since 2025-07-10 15:11:50
|
*/
|
@RestController
|
@RequestMapping("/system/managementReview")
|
@Api(tags = "管理评审会议、输入、报告")
|
public class ManagementReviewController {
|
@Autowired
|
private ManagementReviewService managementReviewService;
|
|
|
|
@ApiOperation(value = "管理评审会议、输入、报告列表(分页)")
|
@ApiImplicitParams({
|
@ApiImplicitParam(paramType = "query", name = "pageNum", dataType = "int", required = false, value = "当前页,默认1"),
|
@ApiImplicitParam(paramType = "query", name = "pageSize", dataType = "int", required = false, value = "每页数目,默认10"),
|
@ApiImplicitParam(paramType = "query", name = "companyId", dataType = "int", required = false, value = "公司id"),
|
@ApiImplicitParam(paramType = "query", name = "reviewType", dataType = "int", required = true, value = "1会议、2输入、3报告"),
|
@ApiImplicitParam(paramType = "query", name = "year", dataType = "int", required = false, value = "年份")
|
})
|
@GetMapping("/selectMeetingsList")
|
public CommonResult selectMeetingsList(Integer companyId,@RequestParam("reviewType") Integer reviewType,String year){
|
return CommonResult.success(managementReviewService.selectManagementReviewList(companyId,reviewType,year));
|
}
|
@RepeatSubmit
|
@ApiOperation(value = "新增管理评审会议、输入、报告")
|
@PostMapping("/saveManagementReview")
|
public CommonResult insertManagementReview(@RequestBody @Validated ManagementReview managementReview){
|
return managementReviewService.insertManagementReview(managementReview);
|
}
|
@ApiOperation(value = "修改管理评审会议、输入、报告")
|
@PostMapping("/updateManagementReview")
|
public CommonResult updateManagementReview(@RequestBody @Validated ManagementReview managementReview){
|
return managementReviewService.updateManagementReview(managementReview);
|
}
|
@ApiOperation(value = "删除管理评审会议、输入、报告")
|
@ApiImplicitParams({
|
@ApiImplicitParam(paramType = "query", name = "id", dataType = "int", required = true, value = "id"),
|
})
|
@GetMapping("/deletedManagementReview")
|
public CommonResult deletedManagementReview(@RequestParam Integer id){
|
return managementReviewService.deletedManagementReview(id);
|
}
|
|
@RepeatSubmit
|
@ApiOperation(value = "一键复制管理评审会议、输入、报告")
|
@ApiImplicitParams({
|
@ApiImplicitParam(paramType = "query", name = "companyId", dataType = "int", required = false, value = "公司id,不传则使用当前登录用户公司"),
|
@ApiImplicitParam(paramType = "query", name = "sourceYear", dataType = "String", required = true, value = "源年份"),
|
@ApiImplicitParam(paramType = "query", name = "targetYear", dataType = "String", required = true, value = "目标年份"),
|
@ApiImplicitParam(paramType = "query", name = "reviewType", dataType = "int", required = true, value = "评审类型:1会议、2输入、3报告")
|
})
|
@GetMapping("/copyManagementReview")
|
public CommonResult copyManagementReview(
|
@RequestParam(required = false) Integer companyId,
|
@RequestParam String sourceYear,
|
@RequestParam String targetYear,
|
@RequestParam Integer reviewType) {
|
return managementReviewService.copyManagementReview(companyId, sourceYear, targetYear, reviewType);
|
}
|
|
}
|