lxw
2023-05-25 f3c27fb78447449a950ba73c5e72ceda64ad8a12
src/main/java/com/whyc/controller/WorkflowPropertyController.java
@@ -2,12 +2,14 @@
import com.whyc.dto.Response;
import com.whyc.dto.WorkflowPropertyDTO;
import com.whyc.pojo.WorkflowProperty;
import com.whyc.service.WorkflowPropertyService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.autoconfigure.ImportAutoConfiguration;
import org.springframework.web.bind.annotation.*;
import sun.net.ApplicationProxy;
import java.util.List;
@@ -21,32 +23,44 @@
    @PostMapping
    @ApiOperation(value = "新增")
    public Response add(@RequestBody List<WorkflowPropertyDTO> propertyList){
        return null;
    public Response add(@RequestBody WorkflowPropertyDTO propertyDTO){
        service.add(propertyDTO);
        return new Response().setII(1,"新增成功");
    }
    @PutMapping
    @ApiOperation(value = "修改")
    public Response update(){
        return null;
    public Response update(@RequestBody WorkflowPropertyDTO propertyDTO){
        service.update(propertyDTO);
        return new Response().setII(1,"修改成功");
    }
    @DeleteMapping
    @ApiOperation(value = "删除")
    public Response delete(){
        return null;
    public Response delete(@RequestParam Integer type,@RequestParam Integer linkType){
        service.delete(type,linkType);
        return new Response().setII(1,"删除成功");
    }
    @GetMapping("propertyList")
    @ApiOperation(value = "查询工单流属性列表")
    public Response<List<WorkflowPropertyDTO>> getPropertyList(){
        List<WorkflowPropertyDTO> propertyList = service.getPropertyList();
        return new Response().set(1,propertyList);
    }
    @GetMapping("linkInfo")
    @ApiOperation(value = "查询节点信息")
    public Response getLinkInfo(@RequestParam Integer type){
        return null;
    public Response<List<WorkflowProperty>> getLinkInfo(@RequestParam Integer type){
        List<WorkflowProperty> propertyList = service.getLinkInfo(type);
        return new Response<List<WorkflowProperty>>().set(1,propertyList);
    }
    @GetMapping("roleInfo")
    @ApiOperation(value = "查询角色信息")
    public Response getLinkInfo(@RequestParam Integer type,@RequestParam Integer linkId){
        return null;
    public Response<List<WorkflowProperty>> getRoleInfo(@RequestParam Integer type,@RequestParam Integer linkId){
        List<WorkflowProperty> propertyList = service.getRoleInfo(type,linkId);
        return new Response<List<WorkflowProperty>>().set(1,propertyList);
    }