<div class="list-group addedFunctionsList" id="list-tab" role="tablist">
<input type="text" class="form-control input-search-controller"
placeholder="Functions">
- <div class="scrollWrapper" *ngFor="let step of steps">
- <a class="list-group-item list-group-item-action active" id="list-home-list"
- data-toggle="list" href="#list-home" role="tab" aria-controls="home"><i
- class="icon-resource_resolution mr-1" aria-hidden="true"></i>
+ <div class="scrollWrapper">
+ <a [class]="steps.indexOf(step) === 0?
+ 'list-group-item list-group-item-action active':
+ 'list-group-item list-group-item-action'" [id]="step"
+ data-toggle="list" href="#list-home" role="tab" aria-controls="home"
+ *ngFor="let step of steps" >
+
+ <i class="icon-resource_resolution mr-1" aria-hidden="true"
+ (click)="setInputAndOutputs(
+ this.designerState.template.workflows[actionName]['steps'][step]['target']
+ )"
+ ></i>
{{step}} <i class="icon-next_arrow" aria-hidden="true" (click)="setInputAndOutputs(
this.designerState.template.workflows[actionName]['steps'][step]['target']
)"></i></a>
<input type="text" class="form-control input-search-controller"
placeholder="Functions">
<div class="scrollWrapper" *ngFor="let step of steps">
- <a class="list-group-item list-group-item-action active" id="list-home-list"
+ <a [class]="steps.indexOf(step) === 0?
+ 'list-group-item list-group-item-action active':
+ 'list-group-item list-group-item-action'" [id]="step"
+ *ngFor="let step of steps"
data-toggle="list" href="#list-home" role="tab" aria-controls="home"><i
class="icon-resource_resolution mr-1" aria-hidden="true"></i>
{{step}} <i class="icon-next_arrow" aria-hidden="true" (click)="setInputAndOutputs(
</div>
</div>
</div>
-</div>
\ No newline at end of file
+</div>
/* tslint:disable:no-string-literal */
this.suggestedInputs = Object.keys(nodeTemplate['interfaces']
[interfaceName]['operations']['process']['inputs']);
+ this.filterTwoCollections(this.suggestedInputs, this.inputs);
+
}
if (nodeTemplate['interfaces'][interfaceName]['operations']['process']['outputs']) {
/* tslint:disable:no-string-literal */
this.suggestedOutputs = Object.keys(nodeTemplate['interfaces']
[interfaceName]['operations']['process']['outputs']);
- console.log(this.suggestedInputs);
+ this.filterTwoCollections(this.suggestedOutputs, this.outputs);
}
}
console.log(nodeTemplate);
}
+ private filterTwoCollections(suggestedInputs: string[], inputs: any[]) {
+ inputs.forEach(input => {
+ if (suggestedInputs.includes(input.name)) {
+ this.deleteAttribute(suggestedInputs, input.name);
+ }
+ });
+ }
+
printSomethings() {
- console.log('something');
+ this.setInputAndOutputs(
+ this.designerState.template.workflows[this.actionName]['steps'][this.steps[0]]['target']
+ );
}
addTempInput(suggestedInput: string) {
deleteAttribute(container: string[], suggestedAttribute: string) {
if (container && suggestedAttribute && container.includes(suggestedAttribute)) {
const index: number = container.indexOf(suggestedAttribute);
+ console.log(index);
if (index !== -1) {
container.splice(index, 1);
}