Class StepController
- java.lang.Object
-
- com.chutneytesting.component.scenario.api.StepController
-
@RestController @RequestMapping("/api/steps/v1") @CrossOrigin(origins="*") public class StepController extends Object
-
-
Constructor Summary
Constructors Constructor Description StepController(ComposableStepRepository composableStepRepository)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddeleteById(String stepId)List<ComposableStepDto>findAll()ComposableStepDtofindById(String stepId)ParentsStepDtofindParents(String stepId)Stringsave(ComposableStepDto step)
-
-
-
Constructor Detail
-
StepController
public StepController(ComposableStepRepository composableStepRepository)
-
-
Method Detail
-
save
@PreAuthorize("hasAuthority(\'COMPONENT_WRITE\')") @PostMapping(path="", produces="application/json") public String save(@RequestBody ComposableStepDto step)
-
deleteById
@PreAuthorize("hasAuthority(\'COMPONENT_WRITE\')") @DeleteMapping(path="/{stepId}") public void deleteById(@PathVariable String stepId)
-
findAll
@PreAuthorize("hasAuthority(\'COMPONENT_READ\') or hasAuthority(\'SCENARIO_WRITE\')") @GetMapping(path="/all", produces="application/json") public List<ComposableStepDto> findAll()
-
findParents
@PreAuthorize("hasAuthority(\'COMPONENT_READ\')") @GetMapping(path="/{stepId}/parents", produces="application/json") public ParentsStepDto findParents(@PathVariable String stepId)
-
findById
@PreAuthorize("hasAuthority(\'COMPONENT_READ\')") @GetMapping(path="/{stepId}", produces="application/json") public ComposableStepDto findById(@PathVariable String stepId)
-
-