aboutsummaryrefslogtreecommitdiffstats
path: root/sdc-workflow-designer-ui/src/app/components
diff options
context:
space:
mode:
Diffstat (limited to 'sdc-workflow-designer-ui/src/app/components')
-rw-r--r--sdc-workflow-designer-ui/src/app/components/canvas/canvas.component.ts84
-rw-r--r--sdc-workflow-designer-ui/src/app/components/container/container.component.css (renamed from sdc-workflow-designer-ui/src/app/components/canvas/canvas.component.css)0
-rw-r--r--sdc-workflow-designer-ui/src/app/components/container/container.component.html22
-rw-r--r--sdc-workflow-designer-ui/src/app/components/container/container.component.ts164
-rw-r--r--sdc-workflow-designer-ui/src/app/components/editable-property/editable-property.component.css (renamed from sdc-workflow-designer-ui/src/app/components/canvas/canvas.component.html)42
-rw-r--r--sdc-workflow-designer-ui/src/app/components/editable-property/editable-property.component.html30
-rw-r--r--sdc-workflow-designer-ui/src/app/components/editable-property/editable-property.component.ts47
-rw-r--r--sdc-workflow-designer-ui/src/app/components/menu/menus.component.css (renamed from sdc-workflow-designer-ui/src/app/components/menu/menu.component.css)0
-rw-r--r--sdc-workflow-designer-ui/src/app/components/menu/menus.component.html (renamed from sdc-workflow-designer-ui/src/app/components/menu/menu.component.html)0
-rw-r--r--sdc-workflow-designer-ui/src/app/components/menu/menus.component.spec.ts (renamed from sdc-workflow-designer-ui/src/app/components/menu/menu.component.spec.ts)0
-rw-r--r--sdc-workflow-designer-ui/src/app/components/menu/menus.component.ts (renamed from sdc-workflow-designer-ui/src/app/components/menu/menu.component.ts)11
-rw-r--r--sdc-workflow-designer-ui/src/app/components/node/node.component.css170
-rw-r--r--sdc-workflow-designer-ui/src/app/components/node/node.component.html134
-rw-r--r--sdc-workflow-designer-ui/src/app/components/node/node.component.ts105
-rw-r--r--sdc-workflow-designer-ui/src/app/components/parameter-tree/parameter-tree.component.ts6
-rw-r--r--sdc-workflow-designer-ui/src/app/components/property/properties.component.html11
-rw-r--r--sdc-workflow-designer-ui/src/app/components/property/properties.component.ts17
-rw-r--r--sdc-workflow-designer-ui/src/app/components/property/rest-task/rest-task-parameters/rest-task-parameters.component.ts5
-rw-r--r--sdc-workflow-designer-ui/src/app/components/property/rest-task/rest-task.component.ts93
-rw-r--r--sdc-workflow-designer-ui/src/app/components/sequence-flow/sequence-flow.component.ts2
-rw-r--r--sdc-workflow-designer-ui/src/app/components/toolbar/toolbar.component.css120
-rw-r--r--sdc-workflow-designer-ui/src/app/components/toolbar/toolbar.component.html191
-rw-r--r--sdc-workflow-designer-ui/src/app/components/toolbar/toolbar.component.ts33
23 files changed, 754 insertions, 533 deletions
diff --git a/sdc-workflow-designer-ui/src/app/components/canvas/canvas.component.ts b/sdc-workflow-designer-ui/src/app/components/canvas/canvas.component.ts
deleted file mode 100644
index 1cf197df..00000000
--- a/sdc-workflow-designer-ui/src/app/components/canvas/canvas.component.ts
+++ /dev/null
@@ -1,84 +0,0 @@
-/**
- * Copyright (c) 2017 ZTE Corporation.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * and the Apache License 2.0 which both accompany this distribution,
- * and are available at http://www.eclipse.org/legal/epl-v10.html
- * and http://www.apache.org/licenses/LICENSE-2.0
- *
- * Contributors:
- * ZTE - initial API and implementation and/or initial documentation
- */
-
-import { AfterViewInit, Component, HostListener } from '@angular/core';
-
-import { BroadcastService } from '../../services/broadcast.service';
-import { JsPlumbService } from '../../services/jsplumb.service';
-import { ActivatedRoute } from "@angular/router";
-import { DataAccessService } from "../../services/data-access/data-access.service";
-import { WorkflowService } from "../../services/workflow.service";
-import { PlanModel } from "../../model/workflow/plan-model";
-import { ModelService } from "../../services/model.service";
-import { SequenceFlow } from "../../model/workflow/sequence-flow";
-import { WorkflowNode } from "../../model/workflow/workflow-node";
-
-/**
- * main canvas, it contains two parts: canvas and node property component
- * bpmn task nodes can be dropped into this canvas, and then the workflow can be edit
- */
-@Component({
- selector: 'b4t-canvas',
- styleUrls: ['./canvas.component.css'],
- templateUrl: 'canvas.component.html',
-})
-export class CanvasComponent implements AfterViewInit {
- private currentType: string; // WorkflowNode, SequenceFlow
- private currentWorkflowNode: WorkflowNode;
- private currentSequenceFlow: SequenceFlow;
-
-
- constructor(private broadcastService: BroadcastService,
- private dataAccessService: DataAccessService,
- private jsPlumbService: JsPlumbService,
- private route: ActivatedRoute,
- private workflowService: WorkflowService,
- private processService: ModelService) {
- }
-
- ngOnInit(): void {
- // this.route.queryParams.subscribe(params => {
- // if (params.id) {
- // this.dataAccessService.catalogService.loadWorkflow(params.id).subscribe(workflow => {
- // this.workflowService.workflow = workflow;
- // });
- // }
- // });
- }
-
- public ngAfterViewInit() {
- this.jsPlumbService.buttonDroppable();
- this.broadcastService.currentSequenceFlow$.subscribe(sequenceFlow => this.currentSequenceFlow = sequenceFlow);
- this.broadcastService.currentWorkflowNode$.subscribe(workflowNode => this.currentWorkflowNode = workflowNode);
- this.broadcastService.currentType$.subscribe(type => this.currentType = type);
- }
-
- public canvasClick() {
- this.broadcastService.broadcast(this.broadcastService.showProperty, false);
- this.broadcastService.broadcast(this.broadcastService.showSequenceFlow, false);
- }
-
- @HostListener('window:keyup.delete', ['$event']) ondelete(event: KeyboardEvent) {
- if (this.currentType === 'WorkflowNode') {
- this.jsPlumbService.remove(this.currentWorkflowNode.id);
- this.processService.deleteNode(this.currentWorkflowNode.id);
- } else if (this.currentType === 'SequenceFlow') {
- this.processService.deleteSequenceFlow(this.currentSequenceFlow.sourceRef, this.currentSequenceFlow.targetRef);
- this.jsPlumbService.deleteConnect(this.currentSequenceFlow.sourceRef, this.currentSequenceFlow.targetRef);
- }
- }
-
-
- public getWorkflow(): PlanModel {
- return this.workflowService.planModel;
- }
-}
diff --git a/sdc-workflow-designer-ui/src/app/components/canvas/canvas.component.css b/sdc-workflow-designer-ui/src/app/components/container/container.component.css
index bc889652..bc889652 100644
--- a/sdc-workflow-designer-ui/src/app/components/canvas/canvas.component.css
+++ b/sdc-workflow-designer-ui/src/app/components/container/container.component.css
diff --git a/sdc-workflow-designer-ui/src/app/components/container/container.component.html b/sdc-workflow-designer-ui/src/app/components/container/container.component.html
new file mode 100644
index 00000000..0d9c5222
--- /dev/null
+++ b/sdc-workflow-designer-ui/src/app/components/container/container.component.html
@@ -0,0 +1,22 @@
+<!--
+/**
+ * Copyright (c) 2017 ZTE Corporation.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * and the Apache License 2.0 which both accompany this distribution,
+ * and are available at http://www.eclipse.org/legal/epl-v10.html
+ * and http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Contributors:
+ * ZTE - initial API and implementation and/or initial documentation
+ */
+-->
+
+<div #mainContainer id="canvas" class="canvas" (mousedown)="canvasMouseDown($event)">
+ <div id="node-selector" #nodeSelector></div>
+ <b4t-node *ngFor="let node of modelService.getNodes()" [node]="node" [rank]="10"></b4t-node>
+</div>
+
+<b4t-properties></b4t-properties>
+
+<b4t-sequence-flow></b4t-sequence-flow>
diff --git a/sdc-workflow-designer-ui/src/app/components/container/container.component.ts b/sdc-workflow-designer-ui/src/app/components/container/container.component.ts
new file mode 100644
index 00000000..f35c2482
--- /dev/null
+++ b/sdc-workflow-designer-ui/src/app/components/container/container.component.ts
@@ -0,0 +1,164 @@
+/**
+ * Copyright (c) 2017 ZTE Corporation.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * and the Apache License 2.0 which both accompany this distribution,
+ * and are available at http://www.eclipse.org/legal/epl-v10.html
+ * and http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Contributors:
+ * ZTE - initial API and implementation and/or initial documentation
+ */
+
+import { AfterViewChecked, AfterViewInit, Component, ElementRef, HostListener, OnInit, OnDestroy, ViewChild } from '@angular/core';
+
+import { SequenceFlow } from '../../model/workflow/sequence-flow';
+import { WorkflowElement } from '../../model/workflow/workflow-element';
+import { WorkflowNode } from '../../model/workflow/workflow-node';
+import { BroadcastService } from '../../services/broadcast.service';
+import { JsPlumbService } from '../../services/jsplumb.service';
+import { ModelService } from '../../services/model.service';
+
+/**
+ * main canvas, it contains two parts: canvas and node property component
+ * bpmn task nodes can be dropped into this canvas, and then the workflow can be edit
+ */
+@Component({
+ selector: 'b4t-container',
+ templateUrl: 'container.component.html',
+ styleUrls: ['./container.component.css']
+})
+export class ContainerComponent implements AfterViewChecked, AfterViewInit, OnInit, OnDestroy {
+ public allNotes: WorkflowNode[];
+ @ViewChild('nodeSelector') nodeSelector: ElementRef;
+ @ViewChild('mainContainer') mainContainer: ElementRef;
+
+ private isSelecting = false;
+ private selectedElements: WorkflowElement[] = [];
+ private showProperties = false;
+ private needInitSequence = false;
+
+ constructor(private broadcastService: BroadcastService, private jsPlumbService: JsPlumbService,
+ public modelService: ModelService) {
+ }
+
+ @HostListener('window:keyup.delete', ['$event']) ondelete(event: KeyboardEvent) {
+ if (this.showProperties || 0 >= this.selectedElements.length) {
+ return;
+ }
+ this.selectedElements.forEach(element => {
+ if (this.modelService.isNode(element)) {
+ let selectNode = element as WorkflowNode;
+ const parentId = this.jsPlumbService.getParentNodeId(selectNode.id);
+ this.jsPlumbService.remove(selectNode);
+ this.modelService.deleteNode(parentId, selectNode.id);
+ } else {
+ let sequenceFlow = element as SequenceFlow;
+ this.modelService.deleteConnection(sequenceFlow.sourceRef, sequenceFlow.targetRef);
+ this.jsPlumbService.deleteConnect(sequenceFlow.sourceRef, sequenceFlow.targetRef);
+ }
+ });
+ this.selectedElements = [];
+ }
+
+ @HostListener('document:mouseup', ['$event']) onmouseup() {
+ if (this.isSelecting) {
+ this.nodeSelector.nativeElement.style.display = 'none';
+ this.mainContainer.nativeElement.onmousemove = null;
+ this.isSelecting = false;
+ this.broadcastService.broadcast(this.broadcastService.showProperty, null);
+ this.broadcastService.broadcast(this.broadcastService.selectedElement, this.selectedElements);
+ }
+ }
+
+ public ngOnInit() {
+ this.jsPlumbService.initJsPlumbInstance(this.modelService.rootNodeId);
+ this.broadcastService.planModel$.subscribe(() => {
+ this.needInitSequence = true;
+ });
+ this.broadcastService.showProperty$.subscribe(element=>{
+ this.showProperties = null !== element;
+ });
+ }
+
+ public ngAfterViewInit() {
+ this.jsPlumbService.canvasDroppable();
+ this.broadcastService.selectedElement$.subscribe(elements => {
+ if (elements) {
+ this.selectedElements = elements;
+ } else {
+ this.selectedElements = [];
+ }
+ });
+ }
+
+ public ngAfterViewChecked() {
+ if (this.needInitSequence) {
+ this.needInitSequence = false;
+ // Add the connection
+ this.jsPlumbService.connectChildrenNodes(this.modelService.rootNodeId);
+ }
+ }
+
+ public ngOnDestroy() {
+ if (this.mainContainer.nativeElement.onmousemove) {
+ this.mainContainer.nativeElement.document.onmousemove = null;
+ }
+ }
+
+ public canvasMouseDown(event) {
+ this.selectedElements = [];
+ this.isSelecting = true;
+ let posx = event.clientX + this.mainContainer.nativeElement.scrollLeft;
+ posx = 220 > posx ? 0 : posx - 220;
+ let posy = event.clientY + this.mainContainer.nativeElement.scrollTop;
+ posy = 60 > posy ? 0 : posy - 60;
+ let element = this.nodeSelector.nativeElement;
+ element.style.left = posx + "px";
+ element.style.top = posy + "px";
+ element.style.width = '0px';
+ element.style.height = '0px';
+ element.style.display = 'block';
+ let curThis = this;
+ this.mainContainer.nativeElement.onmousemove = function (moveEvent) {
+ let movePosx = moveEvent.clientX + curThis.mainContainer.nativeElement.scrollLeft;
+ movePosx = 220 > movePosx ? 0 : movePosx - 220;
+ let movePosy = moveEvent.clientY + curThis.mainContainer.nativeElement.scrollTop;
+ movePosy = 60 > movePosy ? 0 : movePosy - 60;
+ const left = Math.min(movePosx, posx);
+ const top = Math.min(movePosy, posy);
+ const width = Math.abs(posx - movePosx);
+ const height = Math.abs(posy - movePosy);
+ element.style.left = left + "px";
+ element.style.top = top + "px";
+ element.style.width = width + "px";
+ element.style.height = height + "px";
+ curThis.selectNodes(left, top, width, height);
+ };
+ }
+
+ private selectNodes(left: number, top: number, width: number, height: number) {
+ this.selectedElements = [];
+ const allNodes = this.modelService.getNodes();
+ allNodes.forEach(node => {
+ const np = node.position;
+ let selected = false;
+ if (left < np.left) {
+ if ((top < np.top && left + width > np.left && top + height > np.top)
+ || (top >= np.top && top < np.top + np.height && left + width > np.left)) {
+ selected = true;
+ }
+ } else if (left < np.left + np.width) {
+ if ((top < np.top && top + height > np.top)
+ || (top >= np.top && top < np.top + np.height)) {
+ selected = true;
+ }
+ }
+ if (selected) {
+ this.selectedElements.push(node);
+ }
+ });
+ this.broadcastService.broadcast(this.broadcastService.selectedElement, this.selectedElements);
+ }
+
+}
diff --git a/sdc-workflow-designer-ui/src/app/components/canvas/canvas.component.html b/sdc-workflow-designer-ui/src/app/components/editable-property/editable-property.component.css
index daf26bc1..78475cfa 100644
--- a/sdc-workflow-designer-ui/src/app/components/canvas/canvas.component.html
+++ b/sdc-workflow-designer-ui/src/app/components/editable-property/editable-property.component.css
@@ -1,16 +1,26 @@
-<!--
-/**
- * Copyright (c) 2017 ZTE Corporation.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * and the Apache License 2.0 which both accompany this distribution,
- * and are available at http://www.eclipse.org/legal/epl-v10.html
- * and http://www.apache.org/licenses/LICENSE-2.0
- *
- * Contributors:
- * ZTE - initial API and implementation and/or initial documentation
- */
--->
-<div id="canvas" class="canvas" (click)="canvasClick()" b4tDragSelect>
- <b4t-node *ngFor="let node of getWorkflow()?.nodes; let last = last;" [node]="node" [last]="last"></b4t-node>
-</div>
+/**
+ * Copyright (c) 2017 ZTE Corporation.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * and the Apache License 2.0 which both accompany this distribution,
+ * and are available at http://www.eclipse.org/legal/epl-v10.html
+ * and http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Contributors:
+ * ZTE - initial API and implementation and/or initial documentation
+ */
+
+ .edit{
+ font-size: 24px;
+ width: 300px;
+ height: 30px;
+ border: 1px solid #fff;
+}
+
+.edit:hover{
+ border-color: #80bdff;
+}
+
+.edit:focus{
+ border-color: #80bdff;
+}
diff --git a/sdc-workflow-designer-ui/src/app/components/editable-property/editable-property.component.html b/sdc-workflow-designer-ui/src/app/components/editable-property/editable-property.component.html
index a2d9fd51..8dde9f1c 100644
--- a/sdc-workflow-designer-ui/src/app/components/editable-property/editable-property.component.html
+++ b/sdc-workflow-designer-ui/src/app/components/editable-property/editable-property.component.html
@@ -1,25 +1,5 @@
-<!--
-/**
- * Copyright (c) 2017 ZTE Corporation.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * and the Apache License 2.0 which both accompany this distribution,
- * and are available at http://www.eclipse.org/legal/epl-v10.html
- * and http://www.apache.org/licenses/LICENSE-2.0
- *
- * Contributors:
- * ZTE - initial API and implementation and/or initial documentation
- */
- -->
-<span *ngIf="!isEditing()">
- <span (dblclick)="startEdit()">{{parameter.value}}</span>
- <i class="fa fa-edit" (click)="startEdit()"></i>
-</span>
-<span class="row" *ngIf="isEditing()">
- <span class="col-sm-10">
- <b4t-parameter [param]="parameter" [showLabel]="showLabel" [valueSource]= "valueSource" [planItems]="planItems"></b4t-parameter>
- </span>
- <span class="col-sm-2">
- <i class="fa fa-check" (click)="completeEdit()"></i>
- </span>
-</span>
+<input class="edit pull-left" [ngModel]="name" (ngModelChange)="change($event)" (click)="startEdit()" (blur)="stopEdit()"
+(mouseover)="showEditComponent(true)" (mouseout)="showEditComponent(false)">
+<button *ngIf="showEdit" type="button" class="btn blue1 pull-left" (click)="stopEdit();">
+<i class="fa fa-check"></i>
+</button>
diff --git a/sdc-workflow-designer-ui/src/app/components/editable-property/editable-property.component.ts b/sdc-workflow-designer-ui/src/app/components/editable-property/editable-property.component.ts
index 719d2a60..ea965755 100644
--- a/sdc-workflow-designer-ui/src/app/components/editable-property/editable-property.component.ts
+++ b/sdc-workflow-designer-ui/src/app/components/editable-property/editable-property.component.ts
@@ -10,41 +10,44 @@
* ZTE - initial API and implementation and/or initial documentation
*/
-import { AfterViewInit, Component, EventEmitter, Input, Output } from '@angular/core';
-
-import { ValueSource } from '../../model/value-source.enum';
-import { ValueType } from '../../model/value-type.enum';
-import { Parameter} from '../../model/workflow/parameter';
-import { PlanTreeviewItem } from "../../model/plan-treeview-item";
+import { Component, EventEmitter, Input, Output } from '@angular/core';
/**
- * property component presents information of a workflow node.
- * the presented information can be edit in this component.
- * it may load information dynamically. the content may be different for different node type.
+ * node or workflow-line name
*/
@Component({
selector: 'b4t-editable-property',
templateUrl: 'editable-property.component.html',
+ styleUrls: ['./editable-property.component.css']
})
export class EditablePropertyComponent {
- @Input() public parameter: Parameter;
- @Input() public planItems: PlanTreeviewItem[];
- @Input() public showLabel: boolean;
- @Input() public valueSource: ValueSource[];
- @Output() public parameterChange = new EventEmitter<Parameter>();
+ @Input() public name: string;
+ @Output() public nameChange = new EventEmitter<string>();
+
+ public showEdit = false;
+ public isEditing = false;
- private editing = false;
+ public showEditComponent(isShow: boolean): void {
+ if(isShow){
+ this.showEdit = isShow;
+ }else{
+ if(!this.isEditing){
+ this.showEdit = false;
+ }
+ }
+ }
- public isEditing(): boolean {
- return this.editing;
+ public startEdit(): void {
+ this.isEditing = true;
}
- public startEdit() {
- this.editing = true;
+ public stopEdit(): void {
+ this.isEditing = false;
+ this.showEdit = false;
}
- public completeEdit() {
- this.editing = false;
- this.parameterChange.emit(this.parameter);
+ public change(newName: string) {
+ this.name = newName;
+ this.nameChange.emit(this.name);
}
}
diff --git a/sdc-workflow-designer-ui/src/app/components/menu/menu.component.css b/sdc-workflow-designer-ui/src/app/components/menu/menus.component.css
index 6ba4133b..6ba4133b 100644
--- a/sdc-workflow-designer-ui/src/app/components/menu/menu.component.css
+++ b/sdc-workflow-designer-ui/src/app/components/menu/menus.component.css
diff --git a/sdc-workflow-designer-ui/src/app/components/menu/menu.component.html b/sdc-workflow-designer-ui/src/app/components/menu/menus.component.html
index 8cf9dc57..8cf9dc57 100644
--- a/sdc-workflow-designer-ui/src/app/components/menu/menu.component.html
+++ b/sdc-workflow-designer-ui/src/app/components/menu/menus.component.html
diff --git a/sdc-workflow-designer-ui/src/app/components/menu/menu.component.spec.ts b/sdc-workflow-designer-ui/src/app/components/menu/menus.component.spec.ts
index b80edce7..b80edce7 100644
--- a/sdc-workflow-designer-ui/src/app/components/menu/menu.component.spec.ts
+++ b/sdc-workflow-designer-ui/src/app/components/menu/menus.component.spec.ts
diff --git a/sdc-workflow-designer-ui/src/app/components/menu/menu.component.ts b/sdc-workflow-designer-ui/src/app/components/menu/menus.component.ts
index adad16c1..6932e764 100644
--- a/sdc-workflow-designer-ui/src/app/components/menu/menu.component.ts
+++ b/sdc-workflow-designer-ui/src/app/components/menu/menus.component.ts
@@ -18,11 +18,11 @@ import { BroadcastService } from "../../services/broadcast.service";
import { PlanModel } from "../../model/workflow/plan-model";
@Component({
- selector: 'b4t-menu',
- templateUrl: './menu.component.html',
- styleUrls: ['./menu.component.css']
+ selector: 'menus',
+ templateUrl: './menus.component.html',
+ styleUrls: ['./menus.component.css']
})
-export class MenuComponent {
+export class MenusComponent {
@ViewChild(MicroserviceComponent) public microserviceComponent: MicroserviceComponent;
@ViewChild(WorkflowsComponent) public workflowsComponent: WorkflowsComponent;
public currentWorkflow = 'Workflows';
@@ -62,6 +62,7 @@ export class MenuComponent {
const options = [];
workflows.forEach((value, key, map) => {
options.push({label: value.planName, command: () => {
+ console.log(`${value.planName} selected`);
this.workflowSelected(value.planName, value.plan);
}});
});
@@ -73,7 +74,7 @@ export class MenuComponent {
public workflowSelected(planName: string, workflow: PlanModel) {
this.currentWorkflow = planName;
- this.broadcastService.broadcast(this.broadcastService.workflow, workflow);
+ this.broadcastService.broadcast(this.broadcastService.planModel, workflow);
}
public download() {
diff --git a/sdc-workflow-designer-ui/src/app/components/node/node.component.css b/sdc-workflow-designer-ui/src/app/components/node/node.component.css
index 093892e4..af1ce88e 100644
--- a/sdc-workflow-designer-ui/src/app/components/node/node.component.css
+++ b/sdc-workflow-designer-ui/src/app/components/node/node.component.css
@@ -11,30 +11,23 @@
*/
.node {
- border: 1px solid transparent;
cursor: pointer;
display: inline-block;
position: absolute;
z-index: 2;
}
+.node-icon{
+ border-radius: 4px;
+}
-.node.active {
- border: 2px solid red !important;
- box-shadow: 2px 2px 19px #444;
- -o-box-shadow: 2px 2px 19px #444;
- -webkit-box-shadow: 2px 2px 19px #444;
- -moz-box-shadow: 2px 2px 19px #fff;
- opacity: 0.9;
+.node-icon svg{
+ display: block;
+ fill: #00ABFF;
}
-.node:hover {
- border: 1px solid #123456;
- box-shadow: 2px 2px 19px #444;
- -o-box-shadow: 2px 2px 19px #444;
- -webkit-box-shadow: 2px 2px 19px #444;
- -moz-box-shadow: 2px 2px 19px #fff;
- opacity: 0.9;
+.active {
+ outline: 1px solid #00ABFF;
}
/**
@@ -43,11 +36,10 @@
.anchors {
position: absolute;
border-radius: 1em;
- z-index: 20;
display: none;
- background-color: black;
- width: 0;
- height: 0;
+ background-color: #2e6f9a;
+ width: 12px;
+ height: 12px;
cursor: pointer;
-ms-transition: all 0.15s ease-in-out;
transition: all 0.15s ease-in-out;
@@ -56,35 +48,31 @@
-o-transition: all 0.15s ease-in-out;
}
-.node:hover .anchors {
- background-color: black;
+.node-icon:hover > .anchors {
display: inline-block;
- width: 12px;
- height: 12px;
- z-index: 20;
}
.anchor-left {
- left: -5px;
- top: 40%;
+ left: -6px;
+ top: calc(50%);
}
.anchor-right {
- right: -5px;
- top: 40%;
+ right: -6px;
+ top: calc(50%);
}
.anchor-top {
- top: -5px;
- left: 40%;
+ top: -6px;
+ left: calc(50% - 6px);
}
.anchor-bottom {
- bottom: -5px;
- left: 40%;
+ bottom: -6px;
+ left: calc(50% - 6px);
}
-/*right-arrow*/
+/*right arrow*/
.right {
width: 10px;
height: 10px;
@@ -104,7 +92,7 @@
border-top: 5px transparent dashed;
border-right: 5px transparent dashed;
border-bottom: 5px transparent dashed;
- border-left: 5px black solid;
+ border-left: 5px #2e6f9a solid;
overflow: hidden;
}
@@ -117,7 +105,7 @@
left: -2px;
}
-/*left-arrow*/
+/*left arrow */
.left {
width: 10px;
height: 10px;
@@ -134,11 +122,11 @@
position: absolute;
left: 0;
top: 0;
- z-index: 5;
+ z-index: 5; /*ie8-*/
border-top: 5px transparent dashed;
border-left: 5px transparent dashed;
border-bottom: 5px transparent dashed;
- border-right: 5px black solid;
+ border-right: 5px #2e6f9a solid;
overflow: hidden;
}
@@ -150,10 +138,10 @@
left: 2px;
}
-/*top-arrow*/
+/*top arrow*/
.top {
- width: 9px;
- height: 9px;
+ width: 10px;
+ height: 10px;
position: absolute;
left: 1px;
z-index: 2;
@@ -167,7 +155,7 @@
left: 0;
top: 0;
z-index: 5;
- border-bottom: 5px black solid;
+ border-bottom: 5px #2e6f9a solid;
border-left: 5px transparent dashed;
border-right: 5px transparent dashed;
border-top: 5px transparent dashed;
@@ -180,13 +168,13 @@
.top-arrow2 {
top: -2px;
- border-bottom: 4px white solid;
+ border-bottom: 5px white solid;
}
-/*bottom-arrow*/
+/*bottom arrow*/
.bottom {
- width: 9px;
- height: 9px;
+ width: 10px;
+ height: 10px;
position: absolute;
left: 1px;
top: 4px;
@@ -201,10 +189,10 @@
left: 0;
top: 0;
z-index: 5;
- border-bottom: 4px transparent dashed;
- border-left: 4px transparent dashed;
- border-right: 4px transparent dashed;
- border-top: 4px black solid;
+ border-bottom: 5px transparent dashed;
+ border-left: 5px transparent dashed;
+ border-right: 5px transparent dashed;
+ border-top: 5px #2e6f9a solid;
overflow: hidden;
}
@@ -214,77 +202,27 @@
}
.bottom-arrow2 {
- border-top: 4px white solid;
+ border-top: 5px white solid;
}
+/**
+ * Anchors End
+ */
.node .name {
- padding: 10px 15px;
-}
-
-.node:hover {
- border: 1px dotted #000;
-}
-
-.node.focus {
- border: 1px dotted red;
-}
-
-.startEvent {
- border-radius: 30px;
- border: 1px solid rgb(0, 0, 0);
- background-size: cover;
- height: 30px;
- width: 30px;
- /*background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAAAyCAIAAACRXR/mAAAACXBIWXMAAAsTAAALEwEAmpwYAAAKT2lDQ1BQaG90b3Nob3AgS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/pPTT8e7nLuarrlca7nuer21e2b36RueN87d9L158Rb/1tWeOT3dvfN6b/fF9/XfFt1+cif9zsu72Xcn7q28T7xf9EDtQdlD3YfVP1v+3Njv3H9qwHeg89HcR/cGhYPP/pH1jw9DBY+Zj8uGDYbrnjg+OTniP3L96fynQ89kzyaeF/6i/suuFxYvfvjV69fO0ZjRoZfyl5O/bXyl/erA6xmv28bCxh6+yXgzMV70VvvtwXfcdx3vo98PT+R8IH8o/2j5sfVT0Kf7kxmTk/8EA5jz/GMzLdsAAAAgY0hSTQAAeiUAAICDAAD5/wAAgOkAAHUwAADqYAAAOpgAABdvkl/FRgAAAWlJREFUeNrsmLGNwjAUhsmJMpLdpYwrlC7OBCg7IEVUjICZALdUcSZghLBBvIE9gulClTBBrqA56TAQO5yQ7v2trbxPn5znJwfDMMw+L1+zjwxgARZgARZgAdafZ25bOJ/Pxpj3FW7btigK6/JgCULo3UrW67WtutVWkiTGmMvlslqtNptNGIZTSTocDlrrKIoWi8VoW8vlcr/fl2WJECKENE0zeEcIgTFO01Qpdfu+beeTI88Y01rHcZzn+W636/veTZIxJs9zxth2u9VaU0p9/0RCiJSyLMvj8ZhlmZRyLFNVVVmWdV2nlOKcT9kg3LSNleTSt8Zqc5Dk3k5f0eYsyavLP9bmI2mCy+e3Nn9Jzy+f17UJITjndV1fr9c4jpVSPkCTXdU3bZRSf0nT2Pqp7XQ6wbwFWIAFWP8Y69HQ/O7SD4bmwPZ2KqV0GERtCYI7hRhjGOP7++FJF7AAC7AAC7AA65OxvgcA+Qikc7YGylkAAAAASUVORK5CYII=");*/
-}
-
-.endEvent {
- border-radius: 30px;
- border: 2px solid rgb(0, 0, 0);
- background-size: cover;
- height: 30px;
- width: 30px;
- /*background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAAAyCAIAAACRXR/mAAAACXBIWXMAAAsTAAALEwEAmpwYAAAKT2lDQ1BQaG90b3Nob3AgSUNDIHByb2ZpbGUAAHjanVNnVFPpFj333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9L158Rb/1tWeOT3dvfN6b/fF9/XfFt1+cif9zsu72Xcn7q28T7xf9EDtQdlD3YfVP1v+3Njv3H9qwHeg89HcR/cGhYPP/pH1jw9DBY+Zj8uGDYbrnjg+OTniP3L96fynQ89kzyaeF/6i/suuFxYvfvjV69fO0ZjRoZfyl5O/bXyl/erA6xmv28bCxh6+yXgzMV70VvvtwXfcdx3vo98PT+R8IH8o/2j5sfVT0Kf7kxmTk/8EA5jz/GMzLdsAAAAgY0hSTQAAeiUAAICDAAD5/wAAgOkAAHUwAADqYAAAOpgAABdvkl/FRgAAAQFJREFUeNrs2MENgyAUxvFn0wUcwRHeAuoKjuAIbiBOpCO4gU6hR5yAHkgaoxUsBWOa7x2VwC//i8RIKUX3mwfdcsACCyywwAILLD1Pw7umaQKdmud5mqamFep42raN49i7iZmnaVLGIfNrKWVRFB5NdV2rE2NiLcviMRszD8OgN5zn2Z2VJEnf916yrSMJIYQQ7iy9Y1VVv2RbRxrHkZmJyAOLiJyzbSK9n/thOWT7GCkI63y2o0ihWNZs5khhWUfZrJGCs/bZpJTWSBexNtmska5j6SnLsus6a6SrWd+OlYVrIFi4y68/bYFOzbLMvCDCT0qwwAILLLDAAutfWK8BANHUM0rzFI9RAAAAAElFTkSuQmCC");*/
-}
-
-.intermediateCatchEvent {
- border-radius: 30px;
- border: 1px solid rgb(0, 0, 0);
- background-size: cover;
- height: 30px;
- width: 30px;
- background-image: url("data:image/svg+xml;utf8,<?xml version='1.0' encoding='UTF-8' standalone='no'?><svg xmlns='http://www.w3.org/2000/svg' xmlns:oryx='http://www.b3mn.org/oryx' viewBox='1 1 30 30' width='28' height='28' style='fill:transparent' version='1.0'> <defs></defs> <oryx:magnets> <oryx:magnet oryx:cx='16' oryx:cy='16' oryx:default='yes' /> </oryx:magnets> <oryx:docker oryx:cx='16' oryx:cy='16' /> <g pointer-events='fill'> <defs> <radialGradient id='background' cx='10%' cy='10%' r='100%' fx='10%' fy='10%'> <stop offset='0%' stop-color='#ffffff' stop-opacity='1'/> <stop id='fill_el' offset='100%' stop-color='#ffffff' stop-opacity='1'/> </radialGradient> </defs> <circle id='bg_frame' cx='16' cy='16' r='15' stroke='black' stroke-width='1' style='stroke-dasharray: 5.5, 3' /> <circle id='frame2_non_interrupting' cx='16' cy='16' r='12' stroke='black' fill='none' stroke-width='1' style='stroke-dasharray: 4.5, 3' /><circle id='frame' cx='16' cy='16' r='15' stroke='black' fill='none' stroke-width='1'/><circle id='frame2' cx='16' cy='16' r='12' stroke='black' fill='none' stroke-width='1'/><circle id='circle' cx='16' cy='16' r='10' stroke='black' fill='none' stroke-width='1'/> <path id='path1' d='M 16 6 L 16 9 M 21 7 L 19.5 10 M 25 11 L 22 12.5 M 26 16 L 23 16 M 25 21 L 22 19.5 M 21 25 L 19.5 22 M 16 26 L 16 23 M 11 25 L 12.5 22 M 7 21 L 10 19.5 M 6 16 L 9 16 M 7 11 L 10 12.5 M 11 7 L 12.5 10 M 18 9 L 16 16 L 20 16' fill='none' stroke='black' /> <text font-size='11' id='text_name' x='16' y='33' oryx:align='top center' stroke='black'></text></g></svg>");
-}
-
-
-.scriptTask {
- border-radius: 8px;
- border: 2px solid rgb(0, 0, 0);
- height: 60px;
- width: 80px;
- background-image: url("data:image/svg+xml;utf8,<?xml version='1.0' encoding='UTF-8' standalone='no'?> <svg xmlns='http://www.w3.org/2000/svg' xmlns:svg='http://www.w3.org/2000/svg' xmlns:oryx='http://www.b3mn.org/oryx' version='1.0' width='100%' height='100%'> <g id='scriptTask' transform='scale(1, 1) translate(8,8)'> <path oryx:anchors='top left' id='paper' style='opacity:1;fill:none;stroke:#000000' d='M6.402,0.5h14.5c0,0-5.833,2.833-5.833,5.583s4.417,6,4.417,9.167 s-4.167,5.083-4.167,5.083H0.235c0,0,5-2.667,5-5s-4.583-6.75-4.583-9.25S6.402,0.5,6.402,0.5z'/> <path oryx:anchors='top left' id='line1' style='opacity:1;fill:none;stroke:#000000;stroke-width:1.5' d='M 3.5 4.5 L 13.5 4.5' /> <path oryx:anchors='top left' id='line2' style='opacity:1;fill:none;stroke:#000000;stroke-width:1.5' d='M 3.8 8.5 L 13.8 8.5' /> <path oryx:anchors='top left' id='line3' style='opacity:1;fill:none;stroke:#000000;stroke-width:1.5' d='M 6.3 12.5 L 16.3 12.5' /> <path oryx:anchors='top left' id='line4' style='opacity:1;fill:none;stroke:#000000;stroke-width:1.5' d='M 6.5 16.5 L 16.5 16.5' /> </g> </svg> ");
-}
-
-.restTask {
- border-radius: 8px;
- border: 2px solid rgb(0, 0, 0);
- font-size: 10px;
+ width: 55px;
+ height: 12px;
+ text-align: center;
+ white-space: nowrap;
+ color: #5c6d90;
+ line-height: 12px;
+ cursor: pointer;
+ font-family: Arial;
+ font-size: 12px;
}
-.parallelGateway {
- transform: rotate(45deg);
- border: 2px solid rgb(0, 0, 0);
- background-size: cover;
- height: 30px;
- width: 30px;
- background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAOwQAADsEBuJFr7QAAABl0RVh0U29mdHdhcmUAUGFpbnQuTkVUIHYzLjUuND6NzHYAAAEASURBVGhD7ZXRDcIwDEQ7AiMwQkdiQ0ZgBEbpCCWRiBRVob5zbaDSIeUD9WzfvSruNOknAiIgAiIgAiIgAiIgAiLwQwKXMvtezkx48NQQ7XFpNfIsZy1nAUN4anBHhLI3UgMgITw1hCVOOjKzF4LVc26catQUqnPaOFZmmbOeH5seVL1nsl3ydk+QuxJki2vzKURv/G/Nt6hWCHTVcuiC1df3St2Sr/9vwbPC2536DVjm0Y9dOFWk4am3kLXnrecIoDQNag7VpRkdNWZNsfr0MCND1p731KQG6Q1Z5kcfO7QmPcSjTJiJKTU4W0O0l1QEREAEREAEREAEREAEvkHgBRtRrTMkpctqAAAAAElFTkSuQmCC");
+.resizeable {
+ background-color: darkolivegreen;
+ border:1px solid blue;
+ margin: 10px;
}
-.exclusiveGateway {
- transform: rotate(45deg);
- border: 2px solid rgb(0, 0, 0);
- background-size: cover;
- height: 30px;
- width: 30px;
- background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAOwQAADsEBuJFr7QAAABl0RVh0U29mdHdhcmUAUGFpbnQuTkVUIHYzLjUuND6NzHYAAAC4SURBVGhD7ZXRCcAgEEMdpSN0hI7WTTpKR+hIrZ9yIBi4SIUn+CGc0bwoVwoDAhCAAAQgAAEIQMBB4K6i7dwdhzg13yrezsN5mEMbAw6qiiYJKLQctSTgoKpokoBCS6mNHba3jgk8oTP39tk7drxY9tresbMvPP2vLG/grG95ZEaj1+C+TfmQztrpTyPbDAayiap6JKASy64ngWyiqh4JqMSy62O3/k2HzTaKHgQgAAEIQAACyxL4AOr3u2BKXQ3gAAAAAElFTkSuQmCC");
-}
diff --git a/sdc-workflow-designer-ui/src/app/components/node/node.component.html b/sdc-workflow-designer-ui/src/app/components/node/node.component.html
index d4c59d68..1832944b 100644
--- a/sdc-workflow-designer-ui/src/app/components/node/node.component.html
+++ b/sdc-workflow-designer-ui/src/app/components/node/node.component.html
@@ -11,15 +11,15 @@
* ZTE - initial API and implementation and/or initial documentation
*/
-->
-<div (dblclick)="showProperties($event)" class="node {{node.type}}" id="{{node.id}}"
- (click)="onSelected()"
- [class.active]="active"
- [style.top]="node.position.top + 'px'"
- [style.left]="node.position.left + 'px'">
- <div class="name">
- {{getDisplayName()}}
- </div>
+<div (click)="onClick($event)" (mousedown)="onMousedown()" (dblclick)="showProperties($event)" class="node" id="{{node.id}}"
+(mouseover)="onMouseOver($event, $event.target.parentNode)" (mouseout)="onMouseOut($event, $event.target.parentNode)" [style.top]="node.position.top + 'px'"
+[style.left]="node.position.left + 'px'" [style.width]="node.position.width + 'px'" #nodeItem>
+
+<div class="name">{{node.name}}</div>
+<div *ngIf="canHaveChildren()" b4tResizable class="node-icon" [style.width]="node.position.width + 'px'" [style.height]="node.position.height + 'px'"
+ [class.active]="active">
+ <b4t-node *ngFor="let child of node.children" [node]="child" [rank]="rank + 10"></b4t-node>
<div class="anchor anchors anchor-left">
<span class="left">
<i class="left-arrow1"></i>
@@ -32,16 +32,118 @@
<i class="right-arrow2"></i>
</span>
</div>
- <div class="anchor anchors anchor-top">
- <span class="top">
- <i class="top-arrow1"></i>
- <i class="top-arrow2"></i>
+</div>
+
+<div *ngIf="!canHaveChildren()" class="node-icon" [class.active]="active">
+ <svg version="1.1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 30 30" [style.width]="node.position.width + 'px'" [style.height]="node.position.height + 'px'">
+ <g [ngSwitch]="node.type">
+ <g *ngSwitchCase="nodeType[nodeType.startEvent]">
+ <path class="st0" d="M15,2c7.2,0,13,5.8,13,13s-5.8,13-13,13S2,22.2,2,15S7.8,2,15,2 M15,0C6.7,0,0,6.7,0,15s6.7,15,15,15
+ s15-6.7,15-15S23.3,0,15,0L15,0z" />
+ </g>
+ <g *ngSwitchCase="nodeType[nodeType.endEvent]">
+ <path class="st0" d="M15,4c6.1,0,11,4.9,11,11s-4.9,11-11,11S4,21.1,4,15S8.9,4,15,4 M15,0C6.7,0,0,6.7,0,15s6.7,15,15,15
+ s15-6.7,15-15S23.3,0,15,0L15,0z" />
+ </g>
+ <g *ngSwitchCase="nodeType[nodeType.errorStartEvent]">
+ <path class="st0" d="M15,0C6.7,0,0,6.7,0,15s6.7,15,15,15s15-6.7,15-15S23.3,0,15,0z M15,28C7.8,28,2,22.2,2,15S7.8,2,15,2
+ s13,5.8,13,13S22.2,28,15,28z" />
+ <path class="st0" d="M19.7,12H17l2-5.5c0.1-0.3,0.1-0.5-0.1-0.7c-0.2-0.2-0.3-0.3-0.6-0.3H14c-0.3,0-0.6,0.2-0.8,0.5L9.7,16
+ c-0.1,0.3-0.1,0.5,0.1,0.7c0.2,0.2,0.3,0.3,0.6,0.3l3.6,0.1l-1,6.7c-0.1,0.3,0.2,0.8,0.5,0.9c0.1,0,0.2,0,0.3,0
+ c0.3,0,0.7-0.2,0.9-0.4l5.5-11.1c0.1-0.3,0.1-0.5,0-0.8C20.2,12.1,19.9,12,19.7,12z M14.6,22.3l1.2-5.9c0-0.3,0-0.4-0.2-0.6
+ c-0.2-0.2-0.3-0.3-0.6-0.3h-3.5L14.5,7h2.6l-2,5.4C15,12.8,15,13,15.2,13.2c0.2,0.2,0.3,0.3,0.6,0.3h2.5L14.6,22.3z"
+ />
+ </g>
+ <g *ngSwitchCase="nodeType[nodeType.errorEndEvent]">
+ <path class="st0" d="M15,0C6.7,0,0,6.7,0,15s6.7,15,15,15s15-6.7,15-15S23.3,0,15,0z M15,26C8.9,26,4,21.1,4,15S8.9,4,15,4
+ s11,4.9,11,11S21.1,26,15,26z" />
+ <path class="st0" d="M19.7,12.4H17l2-5.5c0.1-0.3,0.1-0.5-0.1-0.7c-0.2-0.2-0.3-0.3-0.6-0.3h-4.2c-0.3,0-0.6,0.2-0.8,0.5l-3.5,10
+ c-0.1,0.3-0.1,0.5,0.1,0.7c0.2,0.2,0.3,0.3,0.6,0.3l3.6,0.1l-1,6.7c-0.1,0.3,0.2,0.8,0.5,0.9c0.1,0,0.2,0,0.3,0
+ c0.3,0,0.7-0.2,0.9-0.4l5.5-11.1c0.1-0.3,0.1-0.5,0-0.8C20.2,12.6,20,12.4,19.7,12.4z" />
+ </g>
+ <g *ngSwitchCase="nodeType[nodeType.toscaNodeManagementTask]">
+ <path class="st0" d="M24,29H6c-2.8,0-5-2.2-5-5V6c0-2.8,2.2-5,5-5h18c2.8,0,5,2.2,5,5v18C29,26.8,26.8,29,24,29z M6,3
+ C4.3,3,3,4.3,3,6v18c0,1.7,1.3,3,3,3h18c1.7,0,3-1.3,3-3V6c0-1.7-1.3-3-3-3H6z" />
+ <path class="st0" d="M7.6,14.5h7.5c0.5,0,0.8-0.4,0.8-1s-0.3-1-0.8-1H7.6c-0.5,0-0.8,0.4-0.8,1S7.1,14.5,7.6,14.5z" />
+ <path class="st0" d="M7.6,18.7h3.7c0.5,0,0.8-0.4,0.8-1s-0.3-1-0.8-1H7.6c-0.5,0-0.8,0.4-0.8,1S7.1,18.7,7.6,18.7z" />
+ <path class="st0" d="M7.6,10.4H19c0.5,0,0.8-0.4,0.8-1s-0.3-1-0.8-1H7.6c-0.5,0-0.8,0.4-0.8,1S7.1,10.4,7.6,10.4z" />
+ <path class="st0" d="M24.7,15.1h-5c-0.6,0-1,0.4-1,1c0,0.6,0.4,1,1,1h1.5v5.7c0,0.6,0.4,1,1,1s1-0.4,1-1v-5.7h1.5c0.6,0,1-0.4,1-1
+ C25.7,15.5,25.2,15.1,24.7,15.1z" />
+ </g>
+ <g *ngSwitchCase="nodeType[nodeType.restTask]">
+ <path class="st0" d="M24,29H6c-2.8,0-5-2.2-5-5V6c0-2.8,2.2-5,5-5h18c2.8,0,5,2.2,5,5v18C29,26.8,26.8,29,24,29z M6,3
+ C4.3,3,3,4.3,3,6v18c0,1.7,1.3,3,3,3h18c1.7,0,3-1.3,3-3V6c0-1.7-1.3-3-3-3H6z" />
+ <path class="st0" d="M7.6,14.5h7.5c0.5,0,0.8-0.4,0.8-1s-0.3-1-0.8-1H7.6c-0.5,0-0.8,0.4-0.8,1S7.1,14.5,7.6,14.5z" />
+ <path class="st0" d="M7.6,18.7h3.7c0.5,0,0.8-0.4,0.8-1s-0.3-1-0.8-1H7.6c-0.5,0-0.8,0.4-0.8,1S7.1,18.7,7.6,18.7z" />
+ <path class="st0" d="M7.6,10.4H19c0.5,0,0.8-0.4,0.8-1s-0.3-1-0.8-1H7.6c-0.5,0-0.8,0.4-0.8,1S7.1,10.4,7.6,10.4z" />
+ <path class="st0" d="M24.1,22.6l-1.6-2.7c0.9-0.4,1.5-1.2,1.5-2.2c0-1.4-1.2-2.5-2.8-2.5h-1.9c-0.2,0-0.4,0.1-0.6,0.2
+ c-0.2,0.1-0.3,0.3-0.3,0.6v7c0,0.4,0.3,0.8,0.8,0.8c0.4,0,0.8-0.3,0.8-0.8v-2.8h0.8l1.9,3.2c0.1,0.2,0.4,0.4,0.7,0.4
+ c0.1,0,0.3,0,0.4-0.1C24.2,23.5,24.4,23,24.1,22.6z M20.1,16.8h1.2c0.6,0,1.2,0.4,1.2,0.9s-0.5,0.9-1.2,0.9h-1.2V16.8z"
+ />
+ </g>
+ <g *ngSwitchCase="nodeType[nodeType.exclusiveGateway]">
+ <path class="st0" d="M16.4,15l3.2-3.2c0.4-0.4,0.4-1,0-1.4s-1-0.4-1.4,0L15,13.6l-3.2-3.2c-0.4-0.4-1-0.4-1.4,0s-0.4,1,0,1.4
+ l3.2,3.2l-3.2,3.2c-0.4,0.4-0.4,1,0,1.4s1,0.4,1.4,0l3.2-3.2l3.2,3.2c0.4,0.4,1,0.4,1.4,0s0.4-1,0-1.4L16.4,15z"
+ />
+ <path class="st0" d="M29.1,12.9l-12-12c-1.1-1.1-3.1-1.1-4.2,0l-12,12C0.3,13.4,0,14.2,0,15s0.3,1.6,0.9,2.1l12,12
+ c0.6,0.6,1.3,0.9,2.1,0.9s1.6-0.3,2.1-0.9l12-12c0.6-0.6,0.9-1.3,0.9-2.1S29.7,13.4,29.1,12.9z M27.7,15.7l-12,12
+ c-0.4,0.4-1,0.4-1.4,0l-12-12C2.1,15.5,2,15.3,2,15s0.1-0.5,0.3-0.7l12-12C14.5,2.1,14.7,2,15,2s0.5,0.1,0.7,0.3l12,12
+ c0.2,0.2,0.3,0.4,0.3,0.7S27.9,15.5,27.7,15.7z" />
+ </g>
+ <g *ngSwitchCase="nodeType[nodeType.parallelGateway]">
+ <path class="st0" d="M20.5,14H16V9.5c0-0.6-0.4-1-1-1s-1,0.4-1,1V14H9.5c-0.6,0-1,0.4-1,1s0.4,1,1,1H14v4.5c0,0.6,0.4,1,1,1
+ s1-0.4,1-1V16h4.5c0.6,0,1-0.4,1-1S21.1,14,20.5,14z" />
+ <path class="st0" d="M29.1,12.9l-12-12c-1.1-1.1-3.1-1.1-4.2,0l-12,12C0.3,13.4,0,14.2,0,15s0.3,1.6,0.9,2.1l12,12
+ c0.6,0.6,1.3,0.9,2.1,0.9s1.6-0.3,2.1-0.9l12-12c0.6-0.6,0.9-1.3,0.9-2.1S29.7,13.4,29.1,12.9z M27.7,15.7l-12,12
+ c-0.4,0.4-1,0.4-1.4,0l-12-12C2.1,15.5,2,15.3,2,15s0.1-0.5,0.3-0.7l12-12C14.5,2.1,14.7,2,15,2s0.5,0.1,0.7,0.3l12,12
+ c0.2,0.2,0.3,0.4,0.3,0.7S27.9,15.5,27.7,15.7z" />
+ </g>
+ <g *ngSwitchCase="nodeType[nodeType.subProcess]">
+ <path class="st0" d="M24.5,1h-18c-2.8,0-5,2.2-5,5v18c0,2.8,2.2,5,5,5h18c2.8,0,5-2.2,5-5V6C29.5,3.2,27.2,1,24.5,1z M20.2,27h-9.4
+ v-9.1c0-0.3,0.2-0.5,0.5-0.5h8.4c0.3,0,0.5,0.2,0.5,0.5V27z M27.5,24c0,1.7-1.3,3-3,3h-2.3v-9.1c0-1.4-1.1-2.5-2.5-2.5h-8.4
+ c-1.4,0-2.5,1.1-2.5,2.5V27H6.5c-1.7,0-3-1.3-3-3V6c0-1.7,1.3-3,3-3h18c1.7,0,3,1.3,3,3V24z" />
+ <path class="st0" d="M19,21.3h-2.5v-2.5c0-0.6-0.4-1-1-1c-0.6,0-1,0.4-1,1v2.5H12c-0.6,0-1,0.4-1,1s0.4,1,1,1h2.5v2.5
+ c0,0.6,0.4,1,1,1c0.6,0,1-0.4,1-1v-2.5H19c0.6,0,1-0.4,1-1S19.5,21.3,19,21.3z" />
+ </g>
+ <g *ngSwitchCase="nodeType[nodeType.intermediateCatchEvent]">
+ <path class="st0" d="M15,0C6.7,0,0,6.7,0,15c0,8.3,6.7,15,15,15c8.3,0,15-6.7,15-15C30,6.7,23.3,0,15,0z M16,27.9V26
+ c0-0.6-0.4-1-1-1s-1,0.4-1,1v1.9C7.6,27.5,2.5,22.4,2.1,16H4c0.6,0,1-0.4,1-1s-0.4-1-1-1H2.1C2.5,7.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2-0.9,0.5-1.3c0.4-0.4,0.8-0.5,1.3-0.5c0.5,0,0.9,0.2,1.3,0.5c0.4,0.4,0.5,0.8,0.5,1.3
+ c0,0.5-0.2,0.9-0.5,1.3l0.9,0.9c0.2,0.2,0.4,0.2,0.6,0l5.2-5.2l4.4,4.4l0.8,0.8c0.4,0.4,0.5,0.8,0.5,1.3c0,0.5-0.2,0.9-0.5,1.3v0
+ l-5.8,5.8c-0.1-0.6-0.5-1.2-0.9-1.6L14.5,21.3z M27,24c0,1.7-1.3,3-3,3h-8.6l7.9-7.9c0.7-0.7,1-1.6,1-2.5c0-0.9-0.4-1.8-1-2.5
+ l-0.8-0.8L18.1,9l1.3-1.3c0.7-0.7,1-1.6,1-2.5c0-0.8-0.3-1.6-0.8-2.2H24c1.7,0,3,1.3,3,3V24z" />
+ <path class="st0" d="M17.2,12.4c-0.3-0.3-0.8-0.3-1.1,0L12.6,16c-0.3,0.3-0.3,0.8,0,1.1c0.1,0.1,0.3,0.2,0.5,0.2s0.4-0.1,0.5-0.2
+ l3.6-3.6C17.5,13.1,17.5,12.7,17.2,12.4z" />
+ <path class="st0" d="M18.9,14.2c-0.3-0.3-0.8-0.3-1.1,0l-3.6,3.6c-0.3,0.3-0.3,0.8,0,1.1c0.1,0.1,0.3,0.2,0.5,0.2
+ c0.2,0,0.4-0.1,0.5-0.2l3.6-3.6C19.2,14.9,19.2,14.4,18.9,14.2z" />
+ <path class="st0" d="M17.1,20.6l3.6-3.6c0.3-0.3,0.3-0.8,0-1.1s-0.8-0.3-1.1,0L16,19.5c-0.3,0.3-0.3,0.8,0,1.1
+ c0.1,0.1,0.3,0.2,0.5,0.2S17,20.7,17.1,20.6z" />
+ </g>
+ </g>
+ </svg>
+ <div class="anchor anchors anchor-left">
+ <span class="left">
+ <i class="left-arrow1"></i>
+ <i class="left-arrow2"></i>
</span>
</div>
- <div class="anchor anchors anchor-bottom">
- <span class="bottom">
- <i class="bottom-arrow1"></i>
- <i class="bottom-arrow2"></i>
+ <div class="anchor anchors anchor-right">
+ <span class="right">
+ <i class="right-arrow1"></i>
+ <i class="right-arrow2"></i>
</span>
</div>
</div>
+</div>
diff --git a/sdc-workflow-designer-ui/src/app/components/node/node.component.ts b/sdc-workflow-designer-ui/src/app/components/node/node.component.ts
index 5fe189db..e688e973 100644
--- a/sdc-workflow-designer-ui/src/app/components/node/node.component.ts
+++ b/sdc-workflow-designer-ui/src/app/components/node/node.component.ts
@@ -9,16 +9,19 @@
* Contributors:
* ZTE - initial API and implementation and/or initial documentation
*/
+import { AfterViewInit, Component, ElementRef, Input, OnDestroy, ViewChild } from '@angular/core';
-import { Component, AfterViewInit, Input, OnDestroy } from '@angular/core';
-
+import { Subscription } from 'rxjs/Subscription';
+import { SubProcess } from '../../model/workflow/sub-process';
+import { WorkflowNode } from '../../model/workflow/workflow-node';
+import { BroadcastService } from '../../services/broadcast.service';
import { JsPlumbService } from '../../services/jsplumb.service';
-import { BroadcastService } from "../../services/broadcast.service";
-import { WorkflowNode } from "../../model/workflow/workflow-node";
-import { Subscription } from "rxjs/Subscription";
+import { ModelService } from '../../services/model.service';
+import { NodeType } from '../../model/workflow/node-type.enum';
/**
- * workflow node component
+ * node component represent a single workflow node.
+ * every node would be rendered on the container component
*/
@Component({
selector: 'b4t-node',
@@ -26,61 +29,85 @@ import { Subscription } from "rxjs/Subscription";
templateUrl: 'node.component.html',
})
export class NodeComponent implements AfterViewInit, OnDestroy {
-
@Input() public node: WorkflowNode;
- @Input() public last: boolean;
+ @Input() public rank: number;
+ @ViewChild('nodeItem') nodeItem: ElementRef;
+ public nodeType = NodeType;
public active = false;
- private currentTypeSubscription: Subscription;
private currentWorkflowSubscription: Subscription;
+ private isMoving = false;
- constructor(private broadcastService: BroadcastService,
- private jsPlumbService: JsPlumbService) {
-
+ constructor(private jsPlumbService: JsPlumbService,
+ private modelService: ModelService,
+ private broadcastService: BroadcastService) {
}
- ngAfterViewInit(): void {
- if(this.last) {
- this.jsPlumbService.initNode();
- this.jsPlumbService.connectNodes();
- }
+ public ngAfterViewInit() {
+ this.jsPlumbService.initJsPlumbInstance(this.node.parentId);
+ this.jsPlumbService.initNode(this.node);
- this.currentTypeSubscription = this.broadcastService.currentType$.subscribe(type => {
- if (type === 'SequenceFlow') {
- this.active = false;
- }
- });
+ if (this.canHaveChildren()) {
+ this.jsPlumbService.nodeDroppable(this.node, this.rank);
+ this.jsPlumbService.connectChildrenNodes(this.node.id);
+ }
- this.currentWorkflowSubscription = this.broadcastService.currentWorkflowNode$.subscribe(activeNode => {
- if (activeNode.id === this.node.id) {
- this.active = true;
- } else {
- this.active = false;
+ this.currentWorkflowSubscription = this.broadcastService.selectedElement$.subscribe(activeNodes => {
+ let active = false;
+ for (let index = 0; index < activeNodes.length; index++) {
+ let activeNode = activeNodes[index] as WorkflowNode;
+ if (activeNode.id === this.node.id) {
+ active = true;
+ break;
+ }
}
+ this.active = active;
});
}
public ngOnDestroy() {
- this.currentTypeSubscription.unsubscribe();
this.currentWorkflowSubscription.unsubscribe();
+ if (this.nodeItem.nativeElement.onmousemove) {
+ this.nodeItem.nativeElement.onmousemove = null;
+ }
}
- public showProperties() {
- this.broadcastService.broadcast(this.broadcastService.nodeProperty, this.node);
- this.broadcastService.broadcast(this.broadcastService.showProperty, true);
+ public onMousedown() {
+ let currentThis = this;
+ this.nodeItem.nativeElement.onmousemove = function () {
+ currentThis.isMoving = true;
+ };
}
- public getDisplayName(): string {
- if (this.node.type === 'restTask' || this.node.type === 'toscaTask') {
- return this.node.name;
- } else {
- return ' ';
+ public onClick(event) {
+ if (this.nodeItem.nativeElement.onmousemove) {
+ this.nodeItem.nativeElement.onmousemove = null;
+ }
+ if (this.isMoving && this.active) {
+ this.isMoving = false;
+ return;
}
+ event.stopPropagation();
+ this.broadcastService.broadcast(this.broadcastService.showProperty, null);
+ this.broadcastService.broadcast(this.broadcastService.selectedElement, [this.node]);
+ }
+
+ public canHaveChildren(): boolean {
+ return this.node.type === 'subProcess';
}
- public onSelected() {
- this.broadcastService.broadcast(this.broadcastService.currentWorkflowNode, this.node);
- this.broadcastService.broadcast(this.broadcastService.currentType, 'WorkflowNode');
+ public onMouseOut(event, target) {
+ event.stopPropagation();
+ target.classList.remove('hover');
}
+ public onMouseOver(event, target) {
+ event.stopPropagation();
+ target.classList.add('hover');
+ }
+
+ public showProperties(event) {
+ event.stopPropagation();
+ this.broadcastService.broadcast(this.broadcastService.showProperty, this.node);
+ }
}
diff --git a/sdc-workflow-designer-ui/src/app/components/parameter-tree/parameter-tree.component.ts b/sdc-workflow-designer-ui/src/app/components/parameter-tree/parameter-tree.component.ts
index 9271dac8..77da46b7 100644
--- a/sdc-workflow-designer-ui/src/app/components/parameter-tree/parameter-tree.component.ts
+++ b/sdc-workflow-designer-ui/src/app/components/parameter-tree/parameter-tree.component.ts
@@ -22,6 +22,7 @@ import { SwaggerTreeConverterService } from '../../services/swagger-tree-convert
import { WorkflowUtil } from '../../util/workflow-util';
import { Swagger } from "../../model/swagger";
import { WorkflowConfigService } from "../../services/workflow-config.service";
+import { RestService } from '../../services/rest.service';
/**
* parameter tree presents parameter of task node's input and output parameters.
@@ -37,8 +38,9 @@ export class ParameterTreeComponent implements OnChanges {
@Input() public defaultValueSource: string;
@Input() public valueSource: ValueSource[];
@Input() public planItems: PlanTreeviewItem[];
+ @Input() public restConfigId: string;
- constructor(private restService: WorkflowConfigService, private swaggerTreeConverterService: SwaggerTreeConverterService) { }
+ constructor(private restService: RestService, private swaggerTreeConverterService: SwaggerTreeConverterService) { }
public ngOnChanges(changes: SimpleChanges) {
// const changeParameters = changes['parameters'];
@@ -81,7 +83,7 @@ export class ParameterTreeComponent implements OnChanges {
}
private getSwagger(): Swagger {
- return this.restService.getSwaggerInfo(this.task.serviceName, this.task.serviceVersion);
+ return this.restService.getSwaggerInfo(this.restConfigId);
}
public getKeyParameter(node: any) {
diff --git a/sdc-workflow-designer-ui/src/app/components/property/properties.component.html b/sdc-workflow-designer-ui/src/app/components/property/properties.component.html
index 2870a4b1..19d0dce1 100644
--- a/sdc-workflow-designer-ui/src/app/components/property/properties.component.html
+++ b/sdc-workflow-designer-ui/src/app/components/property/properties.component.html
@@ -14,19 +14,12 @@
<div class="wm-properties-wrapper" *ngIf="show">
<div class="form-group row">
- <div *ngIf="!titleEditing" class="view col-md-10" (dblclick)="titleEditing = !titleEditing">
- <h4>{{node.name}}</h4>
- </div>
- <div class="col-md-10" *ngIf="titleEditing">
- <input class="form-control" (blur)="nodeNameChanged()" type="text" [(ngModel)]="node.name"/>
- </div>
-
+ <b4t-editable-property class="col-md-10" [(name)]="node.name"></b4t-editable-property>
<div class="col-md-2">
- <button (click)="deleteNode()" type="button" class="btn btn-danger">
+ <button (click)="deleteNode()" type="button" class="btn white">
<i class="fa fa-trash" style="margin-right: 5px;"></i>
</button>
</div>
-
</div>
<hr>
diff --git a/sdc-workflow-designer-ui/src/app/components/property/properties.component.ts b/sdc-workflow-designer-ui/src/app/components/property/properties.component.ts
index 2091d83c..d3a6a416 100644
--- a/sdc-workflow-designer-ui/src/app/components/property/properties.component.ts
+++ b/sdc-workflow-designer-ui/src/app/components/property/properties.component.ts
@@ -35,8 +35,8 @@ export class PropertiesComponent implements AfterViewInit {
public planItems: PlanTreeviewItem[];
constructor(private broadcastService: BroadcastService,
- private jsPlumnService: JsPlumbService,
- private processService: ModelService) {
+ private jsPlumbService: JsPlumbService,
+ private modelService: ModelService) {
}
@@ -44,19 +44,14 @@ export class PropertiesComponent implements AfterViewInit {
this.broadcastService.showProperty$.subscribe(show => this.show = show);
this.broadcastService.nodeProperty$.subscribe(node => {
this.node = node;
- this.planItems = this.processService.getPlanParameters(this.node.id);
+ this.planItems = this.modelService.getPlanParameters(this.node.id);
});
}
- public nodeNameChanged() {
- this.titleEditing = !this.titleEditing;
- this.jsPlumnService.jsplumbInstance.repaintEverything();
- }
-
public deleteNode() {
this.show = false;
-
- this.jsPlumnService.remove(this.node.id);
- this.processService.deleteNode(this.node.id);
+ const parentId = this.jsPlumbService.getParentNodeId(this.node.id);
+ this.jsPlumbService.remove(this.node);
+ this.modelService.deleteNode(parentId, this.node.id);
}
}
diff --git a/sdc-workflow-designer-ui/src/app/components/property/rest-task/rest-task-parameters/rest-task-parameters.component.ts b/sdc-workflow-designer-ui/src/app/components/property/rest-task/rest-task-parameters/rest-task-parameters.component.ts
index 7f8bbf43..8e8cc94f 100644
--- a/sdc-workflow-designer-ui/src/app/components/property/rest-task/rest-task-parameters/rest-task-parameters.component.ts
+++ b/sdc-workflow-designer-ui/src/app/components/property/rest-task/rest-task-parameters/rest-task-parameters.component.ts
@@ -21,6 +21,7 @@ import { ValueSource } from "../../../../model/value-source.enum";
import { SwaggerTreeConverterService } from "../../../../services/swagger-tree-converter.service";
import { PlanTreeviewItem } from "../../../../model/plan-treeview-item";
import { WorkflowConfigService } from "../../../../services/workflow-config.service";
+import { RestService } from '../../../../services/rest.service';
/**
* property component presents information of a workflow node.
@@ -44,7 +45,7 @@ export class RestTaskParametersComponent implements OnInit {
private index = 1;
constructor(private broadcastService: BroadcastService,
- private workflowConfigService: WorkflowConfigService,
+ private restService: RestService,
private swaggerTreeConverterService: SwaggerTreeConverterService) {
}
@@ -62,7 +63,7 @@ export class RestTaskParametersComponent implements OnInit {
this.task.parameters.forEach(param => {
if (param.position === 'body') {
const requestTreeNode = this.swaggerTreeConverterService
- .schema2TreeNode(this.workflowConfigService.getSwaggerInfo(this.task.serviceName, this.task.serviceVersion), 'Request Param', param.schema, param.value);
+ .schema2TreeNode(this.restService.getSwaggerInfo(this.task.restConfigId), 'Request Param', param.schema, param.value);
param.value = requestTreeNode.value;
param.value = param.schema.value;
this.bodyParameter.push(requestTreeNode);
diff --git a/sdc-workflow-designer-ui/src/app/components/property/rest-task/rest-task.component.ts b/sdc-workflow-designer-ui/src/app/components/property/rest-task/rest-task.component.ts
index d0c92dfd..eb1c81bd 100644
--- a/sdc-workflow-designer-ui/src/app/components/property/rest-task/rest-task.component.ts
+++ b/sdc-workflow-designer-ui/src/app/components/property/rest-task/rest-task.component.ts
@@ -9,91 +9,61 @@
* Contributors:
* ZTE - initial API and implementation and/or initial documentation
*******************************************************************************/
-import { AfterViewInit, Component, Input, OnInit } from '@angular/core';
+import { Component, Input, OnInit } from '@angular/core';
import { Subscription } from 'rxjs/Subscription';
+import { PlanTreeviewItem } from '../../../model/plan-treeview-item';
import { Swagger, SwaggerMethod, SwaggerParameter, SwaggerResponse } from '../../../model/swagger';
import { ValueSource } from '../../../model/value-source.enum';
import { ValueType } from '../../../model/value-type.enum';
+import { RestParameter } from '../../../model/workflow/rest-parameter';
import { RestTask } from '../../../model/workflow/rest-task';
import { BroadcastService } from '../../../services/broadcast.service';
-import { WorkflowConfigService } from '../../../services/workflow-config.service';
-import { Microservice } from "../../../model/workflow/microservice";
-import { WorkflowUtil } from "../../../util/workflow-util";
-import { RestParameter } from "../../../model/workflow/rest-parameter";
-import { PlanTreeviewItem } from "../../../model/plan-treeview-item";
+import { RestService } from '../../../services/rest.service';
+import { WorkflowUtil } from '../../../util/workflow-util';
@Component({
selector: 'b4t-rest-task',
templateUrl: 'rest-task.component.html',
})
-export class RestTaskComponent implements AfterViewInit, OnInit {
+export class RestTaskComponent implements OnInit {
@Input() public node: RestTask;
@Input() public planItems: PlanTreeviewItem[];
-
public swaggerJson: any = {};
public restInterfaces: any[];
public restOperations: any = [];
- public microservices: Microservice[];
- public selectedMicroservice: Microservice;
private swagger: Swagger;
- constructor(private broadcastService: BroadcastService,
- private configService: WorkflowConfigService) { }
-
- ngOnInit(): void {
- this.microservices = this.configService.getMicroservices();
- this.selectedMicroservice = this.microservices.find(service =>
- (this.node.serviceName === service.name && this.node.serviceVersion === service.version));
- }
- public ngAfterViewInit() {
- setTimeout(() => {
- this.loadInterfaces();
- this.notifyTaskChanged();
- }, 0);
- }
-
- private notifyTaskChanged() {
- this.broadcastService.broadcast(this.broadcastService.nodeTaskChange, this.node);
- }
+ constructor(private broadcastService: BroadcastService, public restService: RestService) { }
- public getText4Microservice(microservice: Microservice): string {
- return `${microservice.name} [${microservice.version}] `;
+ public ngOnInit() {
+ this.loadInterfaces();
}
- public serviceChanged(service: Microservice) {
- this.selectedMicroservice = service;
- this.node.serviceName = service.name;
- this.node.serviceVersion = service.version;
- this.urlChanged('');
+ public serviceChanged(configId: string) {
+ this.node.restConfigId = configId;
+ this.pathChanged('');
this.loadInterfaces();
}
- public urlChanged(url: string) {
- this.node.url = url;
-
+ public pathChanged(path: string) {
+ this.node.path = path;
this.node.consumes = [];
this.node.produces = [];
this.methodChanged('');
-
this.loadOperations();
}
public methodChanged(method: string) {
this.node.method = method;
-
this.node.parameters = [];
this.node.responses = [];
-
this.updateMethodInfo();
-
- this.notifyTaskChanged();
}
-
private loadInterfaces() {
- if (this.node.serviceName && this.node.serviceVersion) {
- this.swagger = this.configService.getSwaggerInfo(this.node.serviceName, this.node.serviceVersion);
+ if (this.node.restConfigId) {
+ this.swagger = this.restService.getSwaggerInfo(this.node.restConfigId);
if (this.swagger) {
this.restInterfaces = [];
@@ -101,15 +71,13 @@ export class RestTaskComponent implements AfterViewInit, OnInit {
this.restInterfaces.push(key);
}
this.loadOperations();
- } else {
- // TODO error handler
}
}
}
private loadOperations() {
- if (this.node.url) {
- const swaggerPath: any = this.swagger.paths[this.node.url];
+ if (this.node.path) {
+ const swaggerPath: any = this.swagger.paths[this.node.path];
this.restOperations = [];
for (const key of Object.keys(swaggerPath)) {
@@ -120,34 +88,23 @@ export class RestTaskComponent implements AfterViewInit, OnInit {
private updateMethodInfo() {
if (this.node.method) {
- const path: any = this.swagger.paths[this.node.url];
+ const path: any = this.swagger.paths[this.node.path];
const method: SwaggerMethod = path[this.node.method];
this.node.consumes = WorkflowUtil.deepClone(method.consumes);
this.node.produces = WorkflowUtil.deepClone(method.produces);
- // request parameters
+ let tempParameters: RestParameter[] = [];
method.parameters.forEach(param => {
const nodeParam = new RestParameter(param.name, '', ValueSource[ValueSource.String],
- param.type, param.position, param.schema);
- this.node.parameters.push(nodeParam);
+ ValueType[ValueType.String], param.position, param.schema, param.required);
+ tempParameters.push(WorkflowUtil.deepClone(nodeParam));
});
+ this.node.parameters = tempParameters;
- // response parameters
- const responseParams = this.getResponseParameters(method.responses);
+ const responseParams = this.restService.getResponseParameters(
+ this.swagger, this.node.path, this.node.method);
this.node.responses = responseParams.map(param => WorkflowUtil.deepClone(param));
}
}
-
- private getResponseParameters(responses: any) {
- let response: SwaggerResponse = null;
-
- for (const key of Object.keys(responses)) {
- if (key.startsWith('20')) {
- response = responses[key];
- }
- }
-
- return [response];
- }
}
diff --git a/sdc-workflow-designer-ui/src/app/components/sequence-flow/sequence-flow.component.ts b/sdc-workflow-designer-ui/src/app/components/sequence-flow/sequence-flow.component.ts
index c4a70ec9..b114d0ae 100644
--- a/sdc-workflow-designer-ui/src/app/components/sequence-flow/sequence-flow.component.ts
+++ b/sdc-workflow-designer-ui/src/app/components/sequence-flow/sequence-flow.component.ts
@@ -51,7 +51,7 @@ export class SequenceFlowComponent implements AfterViewInit {
public delete() {
this.show = false;
- this.processService.deleteSequenceFlow(this.sequenceFlow.sourceRef, this.sequenceFlow.targetRef);
+ this.processService.deleteConnection(this.sequenceFlow.sourceRef, this.sequenceFlow.targetRef);
this.jsPlumbService.deleteConnect(this.sequenceFlow.sourceRef, this.sequenceFlow.targetRef);
}
}
diff --git a/sdc-workflow-designer-ui/src/app/components/toolbar/toolbar.component.css b/sdc-workflow-designer-ui/src/app/components/toolbar/toolbar.component.css
index 3edffd66..1d119530 100644
--- a/sdc-workflow-designer-ui/src/app/components/toolbar/toolbar.component.css
+++ b/sdc-workflow-designer-ui/src/app/components/toolbar/toolbar.component.css
@@ -9,106 +9,54 @@
* Contributors:
* ZTE - initial API and implementation and/or initial documentation
*/
-
- .toolbar{
- padding: 20px 10px;
-}
-
-.row{
- margin: 0;
-}
-
-button {
- min-width: 40px;
- width: 60px;
- height: 60px;
- transition: all 0s;
- margin: 10px;
- padding: 0;
-}
-
-button div{
- left: 0;
- right: 0;
- margin: auto;
- width: 40px;
- height: 40px;
-}
-
-button span{
- padding: 0;
- font-size: 10px;
- letter-spacing: 0px;
- color: black;
+ .toolbar-head{
+ color:#404040;
+ font-size: 14px;
}
-.subProcess {
- border-radius: 8px;
- border: 2px solid rgb(0, 0, 0);
- font-size: 10px;
+.toolbar-head:hover{
+ cursor: pointer;
}
-.parallelGateway {
- transform: rotate(45deg);
- border: 2px solid rgb(0, 0, 0);
- background-size: cover;
- height: 30px !important;
- width: 30px !important;
- background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAOwQAADsEBuJFr7QAAABl0RVh0U29mdHdhcmUAUGFpbnQuTkVUIHYzLjUuND6NzHYAAAEASURBVGhD7ZXRDcIwDEQ7AiMwQkdiQ0ZgBEbpCCWRiBRVob5zbaDSIeUD9WzfvSruNOknAiIgAiIgAiIgAiIgAiLwQwKXMvtezkx48NQQ7XFpNfIsZy1nAUN4anBHhLI3UgMgITw1hCVOOjKzF4LVc26catQUqnPaOFZmmbOeH5seVL1nsl3ydk+QuxJki2vzKURv/G/Nt6hWCHTVcuiC1df3St2Sr/9vwbPC2536DVjm0Y9dOFWk4am3kLXnrecIoDQNag7VpRkdNWZNsfr0MCND1p731KQG6Q1Z5kcfO7QmPcSjTJiJKTU4W0O0l1QEREAEREAEREAEREAEvkHgBRtRrTMkpctqAAAAAElFTkSuQmCC");
+.fold-icon{
+ width: 15px;
+ font-size: 8px;
+ color: #00abff;
}
-.exclusiveGateway {
- transform: rotate(45deg);
- border: 2px solid rgb(0, 0, 0);
- background-size: cover;
- height: 30px !important;
- width: 30px !important;
- background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAOwQAADsEBuJFr7QAAABl0RVh0U29mdHdhcmUAUGFpbnQuTkVUIHYzLjUuND6NzHYAAAC4SURBVGhD7ZXRCcAgEEMdpSN0hI7WTTpKR+hIrZ9yIBi4SIUn+CGc0bwoVwoDAhCAAAQgAAEIQMBB4K6i7dwdhzg13yrezsN5mEMbAw6qiiYJKLQctSTgoKpokoBCS6mNHba3jgk8oTP39tk7drxY9tresbMvPP2vLG/grG95ZEaj1+C+TfmQztrpTyPbDAayiap6JKASy64ngWyiqh4JqMSy62O3/k2HzTaKHgQgAAEIQAACyxL4AOr3u2BKXQ3gAAAAAElFTkSuQmCC");
+.item{
+ width: 50px;
+ height: 50px;
+ text-align: center;
+ float: left;
+ margin-left: 6px;
+ margin-bottom: 10px;
}
-.startEvent {
- border-radius: 30px;
- border: 1px solid rgb(0, 0, 0);
- background-size: cover;
- height: 30px;
- width: 30px;
- /*background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAAAyCAIAAACRXR/mAAAACXBIWXMAAAsTAAALEwEAmpwYAAAKT2lDQ1BQaG90b3Nob3AgSUNDIHByb2ZpbGUAAHjanVNnVFPpFj333vRCS4iAlEtvUhUIIFJCi4AUkSYqIQkQSoghodkVUcERRUUEG8igiAOOjoCMFVEsDIoK2AfkIaKOg6OIisr74Xuja9a89+bN/rXXPues852zzwfACAyWSDNRNYAMqUIeEeCDx8TG4eQuQIEKJHAAEAizZCFz/SMBAPh+PDwrIsAHvgABeNMLCADATZvAMByH/w/qQplcAYCEAcB0kThLCIAUAEB6jkKmAEBGAYCdmCZTAKAEAGDLY2LjAFAtAGAnf+bTAICd+Jl7AQBblCEVAaCRACATZYhEAGg7AKzPVopFAFgwABRmS8Q5ANgtADBJV2ZIALC3AMDOEAuyAAgMADBRiIUpAAR7AGDIIyN4AISZABRG8lc88SuuEOcqAAB4mbI8uSQ5RYFbCC1xB1dXLh4ozkkXKxQ2YQJhmkAuwnmZGTKBNA/g88wAAKCRFRHgg/P9eM4Ors7ONo62Dl8t6r8G/yJiYuP+5c+rcEAAAOF0ftH+LC+zGoA7BoBt/qIl7gRoXgugdfeLZrIPQLUAoOnaV/Nw+H48PEWhkLnZ2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HcZzn+W636/veTZIxJs9zxth2u9VaU0p9/0RCiJSyLMvj8ZhlmZRyLFNVVVmWdV2nlOKcT9kg3LSNleTSt8Zqc5Dk3k5f0eYsyavLP9bmI2mCy+e3Nn9Jzy+f17UJITjndV1fr9c4jpVSPkCTXdU3bZRSf0nT2Pqp7XQ6wbwFWIAFWP8Y69HQ/O7SD4bmwPZ2KqV0GERtCYI7hRhjGOP7++FJF7AAC7AAC7AA65OxvgcA+Qikc7YGylkAAAAASUVORK5CYII=");*/
+.item:hover{
+ cursor: pointer;
}
-.endEvent {
- border-radius: 30px;
- border: 2px solid rgb(0, 0, 0);
- background-size: cover;
- height: 30px;
- width: 30px;
- /*background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAAAyCAIAAACRXR/mAAAACXBIWXMAAAsTAAALEwEAmpwYAAAKT2lDQ1BQaG90b3Nob3AgSUNDIHByb2ZpbGUAAHjanVNnVFPpFj333vRCS4iAlEtvUhUIIFJCi4AUkSYqIQkQSoghodkVUcERRUUEG8igiAOOjoCMFVEsDIoK2AfkIaKOg6OIisr74Xuja9a89+bN/rXXPues852zzwfACAyWSDNRNYAMqUIeEeCDx8TG4eQuQIEKJHAAEAizZCFz/SMBAPh+PDwrIsAHvgABeNMLCADATZvAMByH/w/qQplcAYCEAcB0kThLCIAUAEB6jkKmAEBGAYCdmCZTAKAEAGDLY2LjAFAtAGAnf+bTAICd+Jl7AQBblCEVAaCRACATZYhEAGg7AKzPVopFAFgwABRmS8Q5ANgtADBJV2ZIALC3AMDOEAuyAAgMADBRiIUpAAR7AGDIIyN4AISZABRG8lc88SuuEOcqAAB4mbI8uSQ5RYFbCC1xB1dXLh4ozkkXKxQ2YQJhmkAuwnmZGTKBNA/g88wAAKCRFRHgg/P9eM4Ors7ONo62Dl8t6r8G/yJiYuP+5c+rcEAAAOF0ftH+LC+zGoA7BoBt/qIl7gRoXgugdfeLZrIPQLUAoOnaV/Nw+H48PEWhkLnZ2eXk5NhKxEJbYc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hWUfZrJGCs/bZpJTWSBexNtmska5j6SnLsus6a6SrWd+OlYVrIFi4y68/bYFOzbLMvCDCT0qwwAILLLDAAutfWK8BANHUM0rzFI9RAAAAAElFTkSuQmCC");*/
+.item svg{
+ width:24px;
+ height:24px;
+ margin: 4px 13px;
+ display: block;
+ /* fill: #A9B2BA; */
+ fill: #00ABFF;
}
-.intermediateCatchEvent {
- border-radius: 30px;
- border: 1px solid rgb(0, 0, 0);
- background-size: cover;
- height: 30px;
- width: 30px;
- background-image: url("data:image/svg+xml;utf8,<?xml version='1.0' encoding='UTF-8' standalone='no'?><svg xmlns='http://www.w3.org/2000/svg' xmlns:oryx='http://www.b3mn.org/oryx' viewBox='1 1 30 30' width='28' height='28' style='fill:transparent' version='1.0'> <defs></defs> <oryx:magnets> <oryx:magnet oryx:cx='16' oryx:cy='16' oryx:default='yes' /> </oryx:magnets> <oryx:docker oryx:cx='16' oryx:cy='16' /> <g pointer-events='fill'> <defs> <radialGradient id='background' cx='10%' cy='10%' r='100%' fx='10%' fy='10%'> <stop offset='0%' stop-color='#ffffff' stop-opacity='1'/> <stop id='fill_el' offset='100%' stop-color='#ffffff' stop-opacity='1'/> </radialGradient> </defs> <circle id='bg_frame' cx='16' cy='16' r='15' stroke='black' stroke-width='1' style='stroke-dasharray: 5.5, 3' /> <circle id='frame2_non_interrupting' cx='16' cy='16' r='12' stroke='black' fill='none' stroke-width='1' style='stroke-dasharray: 4.5, 3' /><circle id='frame' cx='16' cy='16' r='15' stroke='black' fill='none' stroke-width='1'/><circle id='frame2' cx='16' cy='16' r='12' stroke='black' fill='none' stroke-width='1'/><circle id='circle' cx='16' cy='16' r='10' stroke='black' fill='none' stroke-width='1'/> <path id='path1' d='M 16 6 L 16 9 M 21 7 L 19.5 10 M 25 11 L 22 12.5 M 26 16 L 23 16 M 25 21 L 22 19.5 M 21 25 L 19.5 22 M 16 26 L 16 23 M 11 25 L 12.5 22 M 7 21 L 10 19.5 M 6 16 L 9 16 M 7 11 L 10 12.5 M 11 7 L 12.5 10 M 18 9 L 16 16 L 20 16' fill='none' stroke='black' /> <text font-size='11' id='text_name' x='16' y='33' oryx:align='top center' stroke='black'></text></g></svg>");
+.item span{
+ font-size: 12px;
+ color: #595959;
+ display: block;
}
-
-.scriptTask {
- background-size: cover;
- height: 30px;
- width: 30px;
- background-image: url("data:image/svg+xml;utf8,<?xml version='1.0' encoding='UTF-8' standalone='no'?> <svg xmlns='http://www.w3.org/2000/svg' xmlns:svg='http://www.w3.org/2000/svg' xmlns:oryx='http://www.b3mn.org/oryx' version='1.0' width='100%' height='100%'> <g id='scriptTask' transform='scale(1, 1) translate(8,8)'> <path oryx:anchors='top left' id='paper' style='opacity:1;fill:none;stroke:#000000' d='M6.402,0.5h14.5c0,0-5.833,2.833-5.833,5.583s4.417,6,4.417,9.167 s-4.167,5.083-4.167,5.083H0.235c0,0,5-2.667,5-5s-4.583-6.75-4.583-9.25S6.402,0.5,6.402,0.5z'/> <path oryx:anchors='top left' id='line1' style='opacity:1;fill:none;stroke:#000000;stroke-width:1.5' d='M 3.5 4.5 L 13.5 4.5' /> <path oryx:anchors='top left' id='line2' style='opacity:1;fill:none;stroke:#000000;stroke-width:1.5' d='M 3.8 8.5 L 13.8 8.5' /> <path oryx:anchors='top left' id='line3' style='opacity:1;fill:none;stroke:#000000;stroke-width:1.5' d='M 6.3 12.5 L 16.3 12.5' /> <path oryx:anchors='top left' id='line4' style='opacity:1;fill:none;stroke:#000000;stroke-width:1.5' d='M 6.5 16.5 L 16.5 16.5' /> </g> </svg> ");
+.getway{
+ padding-top: 5px;
}
-.toscaTask {
- border-radius: 8px;
- border: 2px solid rgb(0, 0, 0);
- font-size: 10px;
-}
-
-.restTask {
- border-radius: 8px;
- border: 2px solid rgb(0, 0, 0);
- font-size: 10px;
+.getway div{
+ width: 30px !important;
+ height: 30px !important;
}
diff --git a/sdc-workflow-designer-ui/src/app/components/toolbar/toolbar.component.html b/sdc-workflow-designer-ui/src/app/components/toolbar/toolbar.component.html
index bb52644f..382e195e 100644
--- a/sdc-workflow-designer-ui/src/app/components/toolbar/toolbar.component.html
+++ b/sdc-workflow-designer-ui/src/app/components/toolbar/toolbar.component.html
@@ -11,13 +11,184 @@
* ZTE - initial API and implementation and/or initial documentation
*/
-->
-<div class="toolbar">
- <div class="row">
- <button *ngFor="let nodeType of nodeTypes" type="button" [attr.nodeType]="nodeType"
- class="btn btn-secondary item ui-draggable">
- <div class="{{nodeType}}">
- </div>
- <span>{{getNameByType(nodeType)}}</span>
- </button>
- </div>
-</div>
+<accordion>
+ <accordion-group [isOpen]="true" #event>
+ <div accordion-heading class="toolbar-head">
+ <i class="fa fold-icon" [ngClass]="{'fa-chevron-down': event?.isOpen, 'fa-chevron-right': !event?.isOpen}"></i>
+ <i class="fa fa-th-list"></i>
+ <span>EVENT</span>
+ </div>
+ <div nodeType="startEvent" class="item ui-draggable">
+ <svg version="1.1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 30 30">
+ <g>
+ <path class="st0" d="M15,2c7.2,0,13,5.8,13,13s-5.8,13-13,13S2,22.2,2,15S7.8,2,15,2 M15,0C6.7,0,0,6.7,0,15s6.7,15,15,15
+ s15-6.7,15-15S23.3,0,15,0L15,0z" />
+ </g>
+ </svg>
+ <span>Start</span>
+ </div>
+ <div nodeType="endEvent" class="item ui-draggable">
+ <svg version="1.1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 30 30">
+ <g>
+ <path class="st0" d="M15,4c6.1,0,11,4.9,11,11s-4.9,11-11,11S4,21.1,4,15S8.9,4,15,4 M15,0C6.7,0,0,6.7,0,15s6.7,15,15,15
+ s15-6.7,15-15S23.3,0,15,0L15,0z" />
+ </g>
+ </svg>
+ <span>End</span>
+ </div>
+ <div nodeType="intermediateCatchEvent" class="item ui-draggable">
+ <svg version="1.1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 30 30">
+ <g>
+ <path class="st0" d="M15,0C6.7,0,0,6.7,0,15c0,8.3,6.7,15,15,15c8.3,0,15-6.7,15-15C30,6.7,23.3,0,15,0z M16,27.9V26
+ c0-0.6-0.4-1-1-1s-1,0.4-1,1v1.9C7.6,27.5,2.5,22.4,2.1,16H4c0.6,0,1-0.4,1-1s-0.4-1-1-1H2.1C2.5,7.6,7.6,2.5,14,2.1V4
+ c0,0.6,0.4,1,1,1s1-0.4,1-1V2.1C22.4,2.5,27.5,7.6,27.9,14H26c-0.6,0-1,0.4-1,1s0.4,1,1,1h1.9C27.5,22.4,22.4,27.5,16,27.9z"
+ />
+ <path class="st0" d="M20,14h-3.6l2.5-6.6c0.2-0.5-0.1-1.1-0.6-1.3c-0.5-0.2-1.1,0.1-1.3,0.6l-3,8c-0.1,0.3-0.1,0.7,0.1,0.9
+ c0.2,0.3,0.5,0.4,0.8,0.4h5c0.6,0,1-0.4,1-1S20.6,14,20,14z" />
+ </g>
+ </svg>
+ <span>Timer</span>
+ </div>
+ <!--
+ <div nodeType="errorStartEvent" class="item ui-draggable">
+ <svg version="1.1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 30 30">
+ <g>
+ <path class="st0" d="M15,0C6.7,0,0,6.7,0,15s6.7,15,15,15s15-6.7,15-15S23.3,0,15,0z M15,28C7.8,28,2,22.2,2,15S7.8,2,15,2
+ s13,5.8,13,13S22.2,28,15,28z" />
+ <path class="st0" d="M19.7,12H17l2-5.5c0.1-0.3,0.1-0.5-0.1-0.7c-0.2-0.2-0.3-0.3-0.6-0.3H14c-0.3,0-0.6,0.2-0.8,0.5L9.7,16
+ c-0.1,0.3-0.1,0.5,0.1,0.7c0.2,0.2,0.3,0.3,0.6,0.3l3.6,0.1l-1,6.7c-0.1,0.3,0.2,0.8,0.5,0.9c0.1,0,0.2,0,0.3,0
+ c0.3,0,0.7-0.2,0.9-0.4l5.5-11.1c0.1-0.3,0.1-0.5,0-0.8C20.2,12.1,19.9,12,19.7,12z M14.6,22.3l1.2-5.9c0-0.3,0-0.4-0.2-0.6
+ c-0.2-0.2-0.3-0.3-0.6-0.3h-3.5L14.5,7h2.6l-2,5.4C15,12.8,15,13,15.2,13.2c0.2,0.2,0.3,0.3,0.6,0.3h2.5L14.6,22.3z"
+ />
+ </g>
+ </svg>
+ <span>{{ 'WORKFLOW.ERROR_START_EVENT' | translate }}</span>
+ </div>
+ <div nodeType="errorEndEvent" class="item ui-draggable">
+ <svg version="1.1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 30 30">
+ <g>
+ <path class="st0" d="M15,0C6.7,0,0,6.7,0,15s6.7,15,15,15s15-6.7,15-15S23.3,0,15,0z M15,26C8.9,26,4,21.1,4,15S8.9,4,15,4
+ s11,4.9,11,11S21.1,26,15,26z" />
+ <path class="st0" d="M19.7,12.4H17l2-5.5c0.1-0.3,0.1-0.5-0.1-0.7c-0.2-0.2-0.3-0.3-0.6-0.3h-4.2c-0.3,0-0.6,0.2-0.8,0.5l-3.5,10
+ c-0.1,0.3-0.1,0.5,0.1,0.7c0.2,0.2,0.3,0.3,0.6,0.3l3.6,0.1l-1,6.7c-0.1,0.3,0.2,0.8,0.5,0.9c0.1,0,0.2,0,0.3,0
+ c0.3,0,0.7-0.2,0.9-0.4l5.5-11.1c0.1-0.3,0.1-0.5,0-0.8C20.2,12.6,20,12.4,19.7,12.4z" />
+ </g>
+ </svg>
+ <span>{{ 'WORKFLOW.ERROR_END_EVENT' | translate }}</span>
+ </div>
+ -->
+ </accordion-group>
+ <accordion-group [isOpen]="true" #task>
+ <div accordion-heading class="toolbar-head">
+ <i class="fa fold-icon" [ngClass]="{'fa-chevron-down': task?.isOpen, 'fa-chevron-right': !task?.isOpen}"></i>
+ <i class="fa fa-th-list"></i>
+ <span>Task</span>
+ </div>
+ <div *ngIf="!isCatalog" nodeType="toscaNodeManagementTask" class="item ui-draggable">
+ <svg version="1.1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 30 30">
+ <g>
+ <path class="st0" d="M24,29H6c-2.8,0-5-2.2-5-5V6c0-2.8,2.2-5,5-5h18c2.8,0,5,2.2,5,5v18C29,26.8,26.8,29,24,29z M6,3
+ C4.3,3,3,4.3,3,6v18c0,1.7,1.3,3,3,3h18c1.7,0,3-1.3,3-3V6c0-1.7-1.3-3-3-3H6z" />
+ <path class="st0" d="M7.6,14.5h7.5c0.5,0,0.8-0.4,0.8-1s-0.3-1-0.8-1H7.6c-0.5,0-0.8,0.4-0.8,1S7.1,14.5,7.6,14.5z" />
+ <path class="st0" d="M7.6,18.7h3.7c0.5,0,0.8-0.4,0.8-1s-0.3-1-0.8-1H7.6c-0.5,0-0.8,0.4-0.8,1S7.1,18.7,7.6,18.7z" />
+ <path class="st0" d="M7.6,10.4H19c0.5,0,0.8-0.4,0.8-1s-0.3-1-0.8-1H7.6c-0.5,0-0.8,0.4-0.8,1S7.1,10.4,7.6,10.4z" />
+ <path class="st0" d="M24.7,15.1h-5c-0.6,0-1,0.4-1,1c0,0.6,0.4,1,1,1h1.5v5.7c0,0.6,0.4,1,1,1s1-0.4,1-1v-5.7h1.5c0.6,0,1-0.4,1-1
+ C25.7,15.5,25.2,15.1,24.7,15.1z" />
+ </g>
+ </svg>
+ <span>TOSCA</span>
+ </div>
+ <div *ngIf="isCatalog" nodeType="restTask" class="item ui-draggable">
+ <svg version="1.1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 30 30">
+ <g>
+ <path class="st0" d="M24,29H6c-2.8,0-5-2.2-5-5V6c0-2.8,2.2-5,5-5h18c2.8,0,5,2.2,5,5v18C29,26.8,26.8,29,24,29z M6,3
+ C4.3,3,3,4.3,3,6v18c0,1.7,1.3,3,3,3h18c1.7,0,3-1.3,3-3V6c0-1.7-1.3-3-3-3H6z" />
+ <path class="st0" d="M7.6,14.5h7.5c0.5,0,0.8-0.4,0.8-1s-0.3-1-0.8-1H7.6c-0.5,0-0.8,0.4-0.8,1S7.1,14.5,7.6,14.5z" />
+ <path class="st0" d="M7.6,18.7h3.7c0.5,0,0.8-0.4,0.8-1s-0.3-1-0.8-1H7.6c-0.5,0-0.8,0.4-0.8,1S7.1,18.7,7.6,18.7z" />
+ <path class="st0" d="M7.6,10.4H19c0.5,0,0.8-0.4,0.8-1s-0.3-1-0.8-1H7.6c-0.5,0-0.8,0.4-0.8,1S7.1,10.4,7.6,10.4z" />
+ <path class="st0" d="M24.1,22.6l-1.6-2.7c0.9-0.4,1.5-1.2,1.5-2.2c0-1.4-1.2-2.5-2.8-2.5h-1.9c-0.2,0-0.4,0.1-0.6,0.2
+ c-0.2,0.1-0.3,0.3-0.3,0.6v7c0,0.4,0.3,0.8,0.8,0.8c0.4,0,0.8-0.3,0.8-0.8v-2.8h0.8l1.9,3.2c0.1,0.2,0.4,0.4,0.7,0.4
+ c0.1,0,0.3,0,0.4-0.1C24.2,23.5,24.4,23,24.1,22.6z M20.1,16.8h1.2c0.6,0,1.2,0.4,1.2,0.9s-0.5,0.9-1.2,0.9h-1.2V16.8z"
+ />
+ </g>
+ </svg>
+ <span>Rest</span>
+ </div>
+ <div nodeType="scriptTask" class="item ui-draggable">
+ <svg version="1.1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 30 30">
+ <g>
+ <path class="st0" d="M24,1H6C3.2,1,1,3.2,1,6v18c0,2.8,2.2,5,5,5h18c2.8,0,5-2.2,5-5V6C29,3.2,26.8,1,24,1z M16.9,3.4
+ c0.5,0,0.9,0.2,1.3,0.5c0.4,0.4,0.5,0.8,0.5,1.3c0,0.5-0.2,0.9-0.5,1.3L17.7,7l-5.3,5.3c-0.2-0.6-0.5-1.2-0.9-1.6
+ c-0.4-0.4-1-0.8-1.6-0.9l5.8-5.8C16,3.6,16.4,3.4,16.9,3.4z M10.3,27H6c-1.7,0-3-1.3-3-3V6c0-1.7,1.3-3,3-3h8.2l-7.4,7.4
+ c-0.1,0.1-0.2,0.2-0.3,0.3c-0.7,0.7-1,1.6-1,2.5c0,0.9,0.4,1.8,1,2.5l5.2,5.2l-1.3,1.3c-0.7,0.7-1,1.6-1,2.5
+ C9.3,25.5,9.7,26.4,10.3,27z M14.1,25.9c-0.4,0.4-0.8,0.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.8,0,1.1
+ c0.1,0.1,0.3,0.2,0.5,0.2S17,20.7,17.1,20.6z" />
+ </g>
+ </svg>
+ <span>Script</span>
+ </div>
+ </accordion-group>
+ <accordion-group [isOpen]="true" #getway>
+ <div accordion-heading class="toolbar-head">
+ <i class="fa fold-icon" [ngClass]="{'fa-chevron-down': getway?.isOpen, 'fa-chevron-right': !getway?.isOpen}"></i>
+ <i class="fa fa-th-list"></i>
+ <span>Gateway</span>
+ </div>
+ <div nodeType="exclusiveGateway" class="item ui-draggable">
+ <svg version="1.1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 30 30">
+ <g>
+ <path class="st0" d="M16.4,15l3.2-3.2c0.4-0.4,0.4-1,0-1.4s-1-0.4-1.4,0L15,13.6l-3.2-3.2c-0.4-0.4-1-0.4-1.4,0s-0.4,1,0,1.4
+ l3.2,3.2l-3.2,3.2c-0.4,0.4-0.4,1,0,1.4s1,0.4,1.4,0l3.2-3.2l3.2,3.2c0.4,0.4,1,0.4,1.4,0s0.4-1,0-1.4L16.4,15z"
+ />
+ <path class="st0" d="M29.1,12.9l-12-12c-1.1-1.1-3.1-1.1-4.2,0l-12,12C0.3,13.4,0,14.2,0,15s0.3,1.6,0.9,2.1l12,12
+ c0.6,0.6,1.3,0.9,2.1,0.9s1.6-0.3,2.1-0.9l12-12c0.6-0.6,0.9-1.3,0.9-2.1S29.7,13.4,29.1,12.9z M27.7,15.7l-12,12
+ c-0.4,0.4-1,0.4-1.4,0l-12-12C2.1,15.5,2,15.3,2,15s0.1-0.5,0.3-0.7l12-12C14.5,2.1,14.7,2,15,2s0.5,0.1,0.7,0.3l12,12
+ c0.2,0.2,0.3,0.4,0.3,0.7S27.9,15.5,27.7,15.7z" />
+ </g>
+ </svg>
+ <span>EXCLUSIVE</span>
+ </div>
+ <div nodeType="parallelGateway" class="item ui-draggable">
+ <svg version="1.1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 30 30">
+ <g>
+ <path class="st0" d="M20.5,14H16V9.5c0-0.6-0.4-1-1-1s-1,0.4-1,1V14H9.5c-0.6,0-1,0.4-1,1s0.4,1,1,1H14v4.5c0,0.6,0.4,1,1,1
+ s1-0.4,1-1V16h4.5c0.6,0,1-0.4,1-1S21.1,14,20.5,14z" />
+ <path class="st0" d="M29.1,12.9l-12-12c-1.1-1.1-3.1-1.1-4.2,0l-12,12C0.3,13.4,0,14.2,0,15s0.3,1.6,0.9,2.1l12,12
+ c0.6,0.6,1.3,0.9,2.1,0.9s1.6-0.3,2.1-0.9l12-12c0.6-0.6,0.9-1.3,0.9-2.1S29.7,13.4,29.1,12.9z M27.7,15.7l-12,12
+ c-0.4,0.4-1,0.4-1.4,0l-12-12C2.1,15.5,2,15.3,2,15s0.1-0.5,0.3-0.7l12-12C14.5,2.1,14.7,2,15,2s0.5,0.1,0.7,0.3l12,12
+ c0.2,0.2,0.3,0.4,0.3,0.7S27.9,15.5,27.7,15.7z" />
+ </g>
+ </svg>
+ <span>PARALLEL</span>
+ </div>
+ </accordion-group>
+ <!-- <accordion-group [isOpen]="true" #structural>
+ <div accordion-heading class="toolbar-head">
+ <i class="fa fold-icon" [ngClass]="{'fa-chevron-down': structural?.isOpen, 'fa-chevron-right': !structural?.isOpen}"></i>
+ <i class="fa fa-th-list"></i>
+ <span>{{ 'WORKFLOW.BPMN_STRUCTURAL' | translate }}</span>
+ </div>
+ <div nodeType="subProcess" class="item ui-draggable">
+ <svg version="1.1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 30 30">
+ <g>
+ <path class="st0" d="M24.5,1h-18c-2.8,0-5,2.2-5,5v18c0,2.8,2.2,5,5,5h18c2.8,0,5-2.2,5-5V6C29.5,3.2,27.2,1,24.5,1z M20.2,27h-9.4
+ v-9.1c0-0.3,0.2-0.5,0.5-0.5h8.4c0.3,0,0.5,0.2,0.5,0.5V27z M27.5,24c0,1.7-1.3,3-3,3h-2.3v-9.1c0-1.4-1.1-2.5-2.5-2.5h-8.4
+ c-1.4,0-2.5,1.1-2.5,2.5V27H6.5c-1.7,0-3-1.3-3-3V6c0-1.7,1.3-3,3-3h18c1.7,0,3,1.3,3,3V24z"/>
+ <path class="st0" d="M19,21.3h-2.5v-2.5c0-0.6-0.4-1-1-1c-0.6,0-1,0.4-1,1v2.5H12c-0.6,0-1,0.4-1,1s0.4,1,1,1h2.5v2.5
+ c0,0.6,0.4,1,1,1c0.6,0,1-0.4,1-1v-2.5H19c0.6,0,1-0.4,1-1S19.5,21.3,19,21.3z"/>
+ </g>
+ </svg>
+ <span>{{ 'WORKFLOW.SUB_PROCESS' | translate }}</span>
+ </div>
+ </accordion-group> -->
+</accordion>
diff --git a/sdc-workflow-designer-ui/src/app/components/toolbar/toolbar.component.ts b/sdc-workflow-designer-ui/src/app/components/toolbar/toolbar.component.ts
index 71bf02ab..c204a19b 100644
--- a/sdc-workflow-designer-ui/src/app/components/toolbar/toolbar.component.ts
+++ b/sdc-workflow-designer-ui/src/app/components/toolbar/toolbar.component.ts
@@ -10,10 +10,10 @@
* ZTE - initial API and implementation and/or initial documentation
*/
-import { AfterViewInit, Component, OnInit } from '@angular/core';
+import { AfterViewChecked, Component, OnInit } from '@angular/core';
+import { BroadcastService } from '../../services/broadcast.service';
import { JsPlumbService } from '../../services/jsplumb.service';
-import { NodeType } from "../../model/workflow/node-type.enum";
/**
* toolbar component contains some basic operations(save) and all of the supported workflow nodes.
@@ -24,29 +24,20 @@ import { NodeType } from "../../model/workflow/node-type.enum";
templateUrl: 'toolbar.component.html',
styleUrls: ['./toolbar.component.css']
})
-export class ToolbarComponent implements AfterViewInit, OnInit {
- public nodeTypes = [];
+export class ToolbarComponent implements AfterViewChecked, OnInit {
+ public isCatalog = true;
+ private needInitButton = true;
- constructor(private jsPlumbService: JsPlumbService) {
- }
-
- public ngAfterViewInit() {
- this.jsPlumbService.buttonDraggable();
- }
+ constructor(private jsPlumbService: JsPlumbService, private broadcastService: BroadcastService) { }
- ngOnInit(): void {
- this.getNodeTypes();
+ public ngOnInit() {
}
- private getNodeTypes() {
- for(let key in NodeType) {
- if (typeof NodeType[key] === 'number') {
- this.nodeTypes.push(key);
- }
+ public ngAfterViewChecked() {
+ if (this.needInitButton) {
+ this.jsPlumbService.buttonDraggable();
+ this.jsPlumbService.buttonDroppable();
+ this.needInitButton = false;
}
}
-
- public getNameByType(type:string):string{
- return type.replace(type.charAt(0), type.charAt(0).toUpperCase());
- }
}