aboutsummaryrefslogtreecommitdiffstats
path: root/sdc-workflow-designer-ui/src/app/components/property/node-template
diff options
context:
space:
mode:
authorYuanHu <yuan.hu1@zte.com.cn>2018-03-27 17:58:42 +0800
committerYuanHu <yuan.hu1@zte.com.cn>2018-03-27 17:58:42 +0800
commit59884c775c9d06e2195401a09e08650a5cf37b20 (patch)
tree80a2db253939f7a3aeb6e7be45c517c87d748511 /sdc-workflow-designer-ui/src/app/components/property/node-template
parent8261a4ea8091c27b61ac581a852e2e18283b3cdd (diff)
Display Extend Activities on WF Designer UI.
Display Extend Activities on WF Designer UI. Use Extend Activities to Design Workflow and Save Issue-ID: SDC-1130,SDC-1131 Change-Id: Iea62eb0edafb2270deaac89b458015e78d961cd0 Signed-off-by: YuanHu <yuan.hu1@zte.com.cn>
Diffstat (limited to 'sdc-workflow-designer-ui/src/app/components/property/node-template')
-rw-r--r--sdc-workflow-designer-ui/src/app/components/property/node-template/node-template.component.html4
-rw-r--r--sdc-workflow-designer-ui/src/app/components/property/node-template/node-template.component.ts19
2 files changed, 11 insertions, 12 deletions
diff --git a/sdc-workflow-designer-ui/src/app/components/property/node-template/node-template.component.html b/sdc-workflow-designer-ui/src/app/components/property/node-template/node-template.component.html
index 5768c0b5..a7cef5a3 100644
--- a/sdc-workflow-designer-ui/src/app/components/property/node-template/node-template.component.html
+++ b/sdc-workflow-designer-ui/src/app/components/property/node-template/node-template.component.html
@@ -43,7 +43,7 @@
</div>
<hr>
-<b4t-parameter *ngFor="let input of node.input" [param]="input" [valueSource]= "inputSources" [planItems]="planItems"></b4t-parameter>
+<wfm-parameter *ngFor="let input of node.input" [param]="input" [valueSource]= "inputSources" [planItems]="planItems"></wfm-parameter>
<hr *ngIf="0 < node.input.length">
-<b4t-parameter *ngFor="let output of node.output" [param]="output" [valueSource]= "outputSources" [planItems]="planItems"></b4t-parameter>
+<wfm-parameter *ngFor="let output of node.output" [param]="output" [valueSource]= "outputSources" [planItems]="planItems"></wfm-parameter>
diff --git a/sdc-workflow-designer-ui/src/app/components/property/node-template/node-template.component.ts b/sdc-workflow-designer-ui/src/app/components/property/node-template/node-template.component.ts
index 5d7339d0..7fa9675f 100644
--- a/sdc-workflow-designer-ui/src/app/components/property/node-template/node-template.component.ts
+++ b/sdc-workflow-designer-ui/src/app/components/property/node-template/node-template.component.ts
@@ -18,32 +18,31 @@ import { ValueSource } from '../../../model/value-source.enum';
import { Parameter } from '../../../model/workflow/parameter';
import { ToscaNodeTask } from '../../../model/workflow/tosca-node-task';
import { BroadcastService } from '../../../services/broadcast.service';
-import { DataService } from '../../../services/data/data.service';
+import { ToscaService } from '../../../services/tosca.service';
/**
* node template component provides operations about tosca modules which saved in winery.
* This component will be used in the property component while the corresponding workflow node is calling the node template's operation
*/
@Component({
- selector: 'b4t-node-template',
+ selector: 'wfm-node-template',
templateUrl: 'node-template.component.html',
})
export class NodeTemplateComponent implements AfterViewInit {
@Input() public node: ToscaNodeTask;
@Input() public planItems: PlanTreeviewItem[];
- public inputSources: ValueSource[] = [ValueSource.String, ValueSource.Variable, ValueSource.Topology, ValueSource.Plan];
+ public inputSources: ValueSource[] = [ValueSource.string, ValueSource.Variable, ValueSource.Topology, ValueSource.Plan];
public outputSources: ValueSource[] = [ValueSource.Topology, ValueSource.Plan];
public nodeInterfaces: string[] = [];
public nodeOperations: any[] = [];
public nodeTemplates: NodeTemplate[] = [];
- constructor(private dataService: DataService) {
+ constructor(private toscaService: ToscaService) {
}
public ngAfterViewInit() {
- this.dataService.loadNodeTemplates()
- .subscribe(nodeTemplates => this.nodeTemplates = nodeTemplates);
+ this.nodeTemplates = this.toscaService.getNodeTemplate();
this.loadInterfaces();
this.loadOperations();
@@ -86,7 +85,7 @@ export class NodeTemplateComponent implements AfterViewInit {
private loadInterfaces() {
if (this.node.template.id) {
- this.dataService.loadNodeTemplateInterfaces(this.node.template)
+ this.toscaService.loadNodeTemplateInterfaces(this.node.template)
.subscribe(interfaces => {
this.nodeInterfaces = interfaces;
});
@@ -98,7 +97,7 @@ export class NodeTemplateComponent implements AfterViewInit {
private loadOperations() {
if (this.node.nodeInterface) {
this.nodeOperations = [];
- this.dataService.loadNodeTemplateOperations(
+ this.toscaService.loadNodeTemplateOperations(
this.node.template,
this.node.nodeInterface)
.subscribe(operations => this.nodeOperations = operations);
@@ -109,7 +108,7 @@ export class NodeTemplateComponent implements AfterViewInit {
private loadParameters() {
if (this.node.operation) {
- this.dataService.loadNodeTemplateOperationParameter(
+ this.toscaService.loadNodeTemplateOperationParameter(
this.node.template,
this.node.nodeInterface,
this.node.operation)
@@ -118,7 +117,7 @@ export class NodeTemplateComponent implements AfterViewInit {
this.node.output = [];
params.input.forEach(param => {
- const p = new Parameter(param, '', ValueSource[ValueSource.String]);
+ const p = new Parameter(param, '', ValueSource[ValueSource.string]);
this.node.input.push(p);
});