gongchunyi
4 天以前 d1439e537a47804c7c78e3e78ccd1aa24e2fdd23
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
package com.ruoyi.projectManagement.controller;
 
import com.ruoyi.framework.web.domain.AjaxResult;
import com.ruoyi.projectManagement.service.PlanService;
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 lombok.AllArgsConstructor;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*;
 
import javax.validation.Valid;
 
/**
 * @author buhuazhen
 * @date 2026/3/7
 * @email 3038525872@qq.com
 */
@RestController
@RequestMapping("/projectManagement/plan")
@Api(value = "PlanController", tags = "项目管理计划表(项目管理类型)")
@RequiredArgsConstructor
public class PlanController {
 
    private final PlanService planService;
 
    @PostMapping("/save")
    @ApiOperation("保存")
    public AjaxResult save(@RequestBody @Valid SavePlanVo savePlanVo) {
        planService.savePlan(savePlanVo);
        return AjaxResult.success();
    }
 
    @PostMapping("/delete/{id}")
    @ApiOperation("删除")
    public AjaxResult delete(@PathVariable Long id) {
        planService.deletePlan(id);
        return AjaxResult.success();
    }
 
    @PostMapping("/listPage")
    @ApiOperation("分页列表")
    public AjaxResult listPage(@RequestBody SearchPlanVo searchPlanVo) {
        return AjaxResult.success(planService.searchPlan(searchPlanVo));
    }
 
}