blob: be1976a48511edc1abdde91c35a8ac0c4b4a9e1b (
plain)
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
|
package org.onap.vid.controller;
import java.util.List;
import org.onap.portalsdk.core.controller.RestrictedBaseController;
import org.onap.vid.model.SOWorkflow;
import org.onap.vid.services.ExtWorkflowsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
@RestController
@RequestMapping(WorkflowsController.WORKFLOWS_MANAGEMENT)
public class WorkflowsController extends RestrictedBaseController {
static final String WORKFLOWS_MANAGEMENT = "workflows-management";
private ExtWorkflowsService extWorkflowsService;
@Autowired
public WorkflowsController(ExtWorkflowsService extWorkflowsService) {
this.extWorkflowsService = extWorkflowsService;
}
@RequestMapping(value = "workflows", method = RequestMethod.GET)
public List<SOWorkflow> getWorkflows(@RequestParam(value = "vnfName") String vnfName){
return extWorkflowsService.getWorkflows(vnfName);
}
}
|