无关风月
2 天以前 2fee40486f9473398be3c293e8311d45bd53adc9
ruoyi-admin/src/main/java/com/ruoyi/web/controller/api/TDeptController.java
@@ -21,6 +21,7 @@
import javax.annotation.Resource;
import java.util.Arrays;
import java.util.List;
/**
 * <p>
@@ -32,7 +33,7 @@
 */
@Api(tags = "部门管理")
@RestController
@RequestMapping("/t-project-dept")
@RequestMapping("/t-dept")
public class TDeptController {
    @Resource
    private TDeptService deptService;
@@ -42,6 +43,12 @@
    @PostMapping(value = "/pageList")
    public R<PageInfo<DeptListVO>> pageList(@RequestBody DeptListQuery query) {
        return R.ok(deptService.pageList(query));
    }
    @ApiOperation(value = "部门不分页列表")
    @PostMapping(value = "/listAll")
    public R<List<TDept>> listAll() {
        List<TDept> depts = deptService.list();
        return R.ok(depts);
    }
    @Log(title = "新增部门", businessType = BusinessType.INSERT)
    @ApiOperation(value = "新增部门")
@@ -73,7 +80,7 @@
    }
    @Log(title = "启用/禁用部门", businessType = BusinessType.OTHER)
    @ApiOperation(value = "启用/禁用部门")
    @DeleteMapping(value = "/editStatus")
    @GetMapping(value = "/editStatus")
    public R<Boolean> editStatus(@RequestParam String id) {
        TDept byId = deptService.getById(id);
        if (byId.getStatus()==1){