| | |
| | | package com.ruoyi.projectManagement.controller; |
| | | |
| | | import com.ruoyi.framework.web.domain.AjaxResult; |
| | | import com.ruoyi.framework.web.controller.BaseController; |
| | | import com.ruoyi.framework.web.domain.R; |
| | | import com.ruoyi.projectManagement.service.PlanService; |
| | | import com.ruoyi.projectManagement.vo.SavePlanNodeVo; |
| | | import com.ruoyi.projectManagement.vo.SavePlanVo; |
| | |
| | | @RequestMapping("/projectManagement/plan") |
| | | @Tag(name = "项目管理计划表(项目管理类型)") |
| | | @RequiredArgsConstructor |
| | | public class PlanController { |
| | | public class PlanController extends BaseController { |
| | | |
| | | private final PlanService planService; |
| | | |
| | | @PostMapping("/save") |
| | | @Operation(summary = "保存") |
| | | public AjaxResult save(@RequestBody @Valid SavePlanVo savePlanVo) { |
| | | public R<?> save(@RequestBody @Valid SavePlanVo savePlanVo) { |
| | | planService.savePlan(savePlanVo); |
| | | return AjaxResult.success(); |
| | | return R.ok(); |
| | | } |
| | | |
| | | @PostMapping("/delete/{id}") |
| | | @Operation(summary = "删除") |
| | | public AjaxResult delete(@PathVariable Long id) { |
| | | public R<?> delete(@PathVariable Long id) { |
| | | planService.deletePlan(id); |
| | | return AjaxResult.success(); |
| | | return R.ok(); |
| | | } |
| | | |
| | | @PostMapping("/listPage") |
| | | @Operation(summary = "分页列表") |
| | | public AjaxResult listPage(@RequestBody SearchPlanVo searchPlanVo) { |
| | | return AjaxResult.success(planService.searchPlan(searchPlanVo)); |
| | | public R<?> listPage(@RequestBody SearchPlanVo searchPlanVo) { |
| | | return R.ok(planService.searchPlan(searchPlanVo)); |
| | | } |
| | | |
| | | } |