diff options
author | Lvbo163 <lv.bo163@zte.com.cn> | 2017-09-14 14:07:19 +0800 |
---|---|---|
committer | Lvbo163 <lv.bo163@zte.com.cn> | 2017-09-14 14:07:19 +0800 |
commit | b9cda93f7271d4228c2becd64056e338bdb9791d (patch) | |
tree | dcdee4b716895a662cf936749e2b8282d8450506 /sdc-workflow-designer-ui | |
parent | c437d750a4d2480cf880daa8a52c9d89f2dae400 (diff) |
support workflow variable as input parameter
rest task can reference workflow variable to be input parameter
Issue-ID: SDC-336
Change-Id: Idbab11e95195f659ba429489b2725b2fde8fdbec
Signed-off-by: Lvbo163 <lv.bo163@zte.com.cn>
Diffstat (limited to 'sdc-workflow-designer-ui')
3 files changed, 4 insertions, 1 deletions
diff --git a/sdc-workflow-designer-ui/src/app/components/parameter/parameter.component.html b/sdc-workflow-designer-ui/src/app/components/parameter/parameter.component.html index 229c5afb..e6a7ff44 100644 --- a/sdc-workflow-designer-ui/src/app/components/parameter/parameter.component.html +++ b/sdc-workflow-designer-ui/src/app/components/parameter/parameter.component.html @@ -21,6 +21,8 @@ <div [ngSwitch]="param.valueSource">
<input *ngSwitchCase="sourceEnum[sourceEnum.String]" [ngClass]="valueClass" class="form-control"
type="text" [ngModel]="param.value" (ngModelChange)="valueChange($event)">
+ <input *ngSwitchCase="sourceEnum[sourceEnum.Variable]" [ngClass]="valueClass" class="form-control"
+ type="text" [ngModel]="param.value" (ngModelChange)="valueChange($event)">
<!-- TODO add plan and Top parameters -->
<tree-select *ngSwitchCase="sourceEnum[sourceEnum.Plan]" name="simpleSelect" [items]="planOptions"
childrenField="children" #simpleSelect="ngModel" [ngClass]="valueClass" class="tree-select-class"
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 31b2fd82..87903578 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 @@ -34,7 +34,7 @@ export class RestTaskParametersComponent implements OnInit { @Input() public task: RestTask; @Input() public planItems: PlanTreeviewItem[]; - public inputSources: ValueSource[] = [ValueSource.String, ValueSource.Plan]; + public inputSources: ValueSource[] = [ValueSource.String, ValueSource.Variable, ValueSource.Plan]; public requestParameters: RestParameter[] = []; // not include body parameter public bodyParameter: TreeNode[] = []; public responseParameter: TreeNode[] = []; diff --git a/sdc-workflow-designer-ui/src/app/model/value-source.enum.ts b/sdc-workflow-designer-ui/src/app/model/value-source.enum.ts index 4a9ca78a..eeeb5289 100644 --- a/sdc-workflow-designer-ui/src/app/model/value-source.enum.ts +++ b/sdc-workflow-designer-ui/src/app/model/value-source.enum.ts @@ -13,5 +13,6 @@ export enum ValueSource { String, Plan, + Variable, // Topology, // TODO implement Topology properties in R2 } |