| | |
| | | import com.ruoyi.projectManagement.vo.SavePlanNodeVo; |
| | | import com.ruoyi.projectManagement.vo.SavePlanVo; |
| | | import com.ruoyi.projectManagement.vo.SearchPlanVo; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import lombok.AllArgsConstructor; |
| | | import lombok.RequiredArgsConstructor; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.validation.Valid; |
| | | import jakarta.validation.Valid; |
| | | |
| | | /** |
| | | * @author buhuazhen |
| | |
| | | */ |
| | | @RestController |
| | | @RequestMapping("/projectManagement/plan") |
| | | @Api(value = "PlanController", tags = "项目管理计划表(项目管理类型)") |
| | | @Tag(name = "项目管理计划表(项目管理类型)") |
| | | @RequiredArgsConstructor |
| | | public class PlanController { |
| | | |
| | | private final PlanService planService; |
| | | |
| | | @PostMapping("/save") |
| | | @ApiOperation("保存") |
| | | @Operation(summary = "保存") |
| | | public AjaxResult save(@RequestBody @Valid SavePlanVo savePlanVo) { |
| | | planService.savePlan(savePlanVo); |
| | | return AjaxResult.success(); |
| | | } |
| | | |
| | | @PostMapping("/delete/{id}") |
| | | @ApiOperation("删除") |
| | | @Operation(summary = "删除") |
| | | public AjaxResult delete(@PathVariable Long id) { |
| | | planService.deletePlan(id); |
| | | return AjaxResult.success(); |
| | | } |
| | | |
| | | @PostMapping("/listPage") |
| | | @ApiOperation("分页列表") |
| | | @Operation(summary = "分页列表") |
| | | public AjaxResult listPage(@RequestBody SearchPlanVo searchPlanVo) { |
| | | return AjaxResult.success(planService.searchPlan(searchPlanVo)); |
| | | } |