diff options
author | 2020-02-26 15:48:32 +0000 | |
---|---|---|
committer | 2020-03-20 12:33:47 +0000 | |
commit | 2d1528b34c45a650e2407bbc90737cc4ca6ec042 (patch) | |
tree | 76bebbb36a444963353dee17cc294c40fa8cb0d0 /mod/designtool/designtool-web/src/main/webapp/WEB-INF | |
parent | 45341fa5e6e64e86286254d49ca951c43726ab94 (diff) |
Link DCAE MOD design tool to Acumos Adapter
Add import item to global menu with choices of import models, component specs,
and data formats.
Add prefix to acumos adapter API for consistency with rest of DCAE MOD and to
allow adding acumos adapter to k8s/rancher ingress or other reverse proxy
mechanism so it can be accessed by browser javascript in the design tool.
Remove dcae mod hostname mechanism for callbacks from browser javascript since
browser security only allows javascript to call back to the originating host
port.
Clean up indentation only differences between original NiFi code and ONAP
versions.
Remove 3 ONAP java files that are now identical to original NiFi versions.
Change-Id: I23bbd98d5b171d624ef35088cd821aff2918fc1b
Issue-ID: DCAEGEN2-1860
Signed-off-by: Andrew Gauld <agauld@att.com>
Diffstat (limited to 'mod/designtool/designtool-web/src/main/webapp/WEB-INF')
-rw-r--r-- | mod/designtool/designtool-web/src/main/webapp/WEB-INF/partials/canvas/canvas-header.jsp | 72 | ||||
-rw-r--r-- | mod/designtool/designtool-web/src/main/webapp/WEB-INF/partials/canvas/navigation.jsp | 50 |
2 files changed, 94 insertions, 28 deletions
diff --git a/mod/designtool/designtool-web/src/main/webapp/WEB-INF/partials/canvas/canvas-header.jsp b/mod/designtool/designtool-web/src/main/webapp/WEB-INF/partials/canvas/canvas-header.jsp index 3afbe66..e0a4a44 100644 --- a/mod/designtool/designtool-web/src/main/webapp/WEB-INF/partials/canvas/canvas-header.jsp +++ b/mod/designtool/designtool-web/src/main/webapp/WEB-INF/partials/canvas/canvas-header.jsp @@ -50,34 +50,34 @@ nf-draggable="appCtrl.serviceProvider.headerCtrl.toolboxCtrl.draggableComponentConfig(appCtrl.serviceProvider.headerCtrl.toolboxCtrl.groupComponent);"> <span class="component-button-grip"></span> </button> - <button title="{{appCtrl.serviceProvider.headerCtrl.toolboxCtrl.config.type.remoteProcessGroup}}" - id="group-remote-component" - class="component-button icon icon-group-remote" - ng-disabled="!appCtrl.nf.CanvasUtils.canWriteCurrentGroup();" - nf-draggable="appCtrl.serviceProvider.headerCtrl.toolboxCtrl.draggableComponentConfig(appCtrl.serviceProvider.headerCtrl.toolboxCtrl.remoteGroupComponent);"> - <span class="component-button-grip"></span> - </button> - <button title="{{appCtrl.serviceProvider.headerCtrl.toolboxCtrl.config.type.funnel}}" - id="funnel-component" - class="component-button icon icon-funnel" - ng-disabled="!appCtrl.nf.CanvasUtils.canWriteCurrentGroup();" - nf-draggable="appCtrl.serviceProvider.headerCtrl.toolboxCtrl.draggableComponentConfig(appCtrl.serviceProvider.headerCtrl.toolboxCtrl.funnelComponent);"> - <span class="component-button-grip"></span> - </button> - <button title="{{appCtrl.serviceProvider.headerCtrl.toolboxCtrl.config.type.template}}" - id="template-component" - class="component-button icon icon-template" - ng-disabled="!appCtrl.nf.CanvasUtils.canWriteCurrentGroup();" - nf-draggable="appCtrl.serviceProvider.headerCtrl.toolboxCtrl.draggableComponentConfig(appCtrl.serviceProvider.headerCtrl.toolboxCtrl.templateComponent);"> - <span class="component-button-grip"></span> - </button> - <button title="{{appCtrl.serviceProvider.headerCtrl.toolboxCtrl.config.type.label}}" - id="label-component" - class="component-button icon icon-label" - ng-disabled="!appCtrl.nf.CanvasUtils.canWriteCurrentGroup();" - nf-draggable="appCtrl.serviceProvider.headerCtrl.toolboxCtrl.draggableComponentConfig(appCtrl.serviceProvider.headerCtrl.toolboxCtrl.labelComponent);"> - <span class="component-button-grip"></span> - </button> + <button title="{{appCtrl.serviceProvider.headerCtrl.toolboxCtrl.config.type.remoteProcessGroup}}" + id="group-remote-component" + class="component-button icon icon-group-remote" + ng-disabled="!appCtrl.nf.CanvasUtils.canWriteCurrentGroup();" + nf-draggable="appCtrl.serviceProvider.headerCtrl.toolboxCtrl.draggableComponentConfig(appCtrl.serviceProvider.headerCtrl.toolboxCtrl.remoteGroupComponent);"> + <span class="component-button-grip"></span> + </button> + <button title="{{appCtrl.serviceProvider.headerCtrl.toolboxCtrl.config.type.funnel}}" + id="funnel-component" + class="component-button icon icon-funnel" + ng-disabled="!appCtrl.nf.CanvasUtils.canWriteCurrentGroup();" + nf-draggable="appCtrl.serviceProvider.headerCtrl.toolboxCtrl.draggableComponentConfig(appCtrl.serviceProvider.headerCtrl.toolboxCtrl.funnelComponent);"> + <span class="component-button-grip"></span> + </button> + <button title="{{appCtrl.serviceProvider.headerCtrl.toolboxCtrl.config.type.template}}" + id="template-component" + class="component-button icon icon-template" + ng-disabled="!appCtrl.nf.CanvasUtils.canWriteCurrentGroup();" + nf-draggable="appCtrl.serviceProvider.headerCtrl.toolboxCtrl.draggableComponentConfig(appCtrl.serviceProvider.headerCtrl.toolboxCtrl.templateComponent);"> + <span class="component-button-grip"></span> + </button> + <button title="{{appCtrl.serviceProvider.headerCtrl.toolboxCtrl.config.type.label}}" + id="label-component" + class="component-button icon icon-label" + ng-disabled="!appCtrl.nf.CanvasUtils.canWriteCurrentGroup();" + nf-draggable="appCtrl.serviceProvider.headerCtrl.toolboxCtrl.draggableComponentConfig(appCtrl.serviceProvider.headerCtrl.toolboxCtrl.labelComponent);"> + <span class="component-button-grip"></span> + </button> </div> <div layout="row" layout-align="space-between center"> <div layout-align="space-between end" layout="column"> @@ -128,6 +128,22 @@ <i class="icon icon-provenance"></i>Data Provenance </a> </md-menu-item> + <md-menu-item layout-align="space-around center"> + <md-menu class="onap-unpadded"> + <a id="import-link" ng-click="$mdMenu.open()"><i class="icon icon-import"></i>Import</a> + <md-menu-content id="import-menu-content"> + <md-menu-item layout-align="space-around center"> + <a id="adapter-acumos-link" ng-click="appCtrl.serviceProvider.headerCtrl.globalMenuCtrl.importModel.shell.launch();">Import Models ...</a> + </md-menu-item> + <md-menu-item layout-align="space-around center"> + <a id="import-component-link" ng-click="appCtrl.serviceProvider.headerCtrl.globalMenuCtrl.importComponent.shell.launch();">Import Component Spec. ...</a> + </md-menu-item> + <md-menu-item layout-align="space-around center"> + <a id="import-format-link" ng-click="appCtrl.serviceProvider.headerCtrl.globalMenuCtrl.importDataFormat.shell.launch();">Import Data Format ...</a> + </md-menu-item> + </md-menu-content> + </md-menu> + </md-menu-item> <md-menu-divider></md-menu-divider> <md-menu-item layout-align="space-around center"> <a id="flow-settings-link" diff --git a/mod/designtool/designtool-web/src/main/webapp/WEB-INF/partials/canvas/navigation.jsp b/mod/designtool/designtool-web/src/main/webapp/WEB-INF/partials/canvas/navigation.jsp index caf7278..30eb004 100644 --- a/mod/designtool/designtool-web/src/main/webapp/WEB-INF/partials/canvas/navigation.jsp +++ b/mod/designtool/designtool-web/src/main/webapp/WEB-INF/partials/canvas/navigation.jsp @@ -127,3 +127,53 @@ </div> </div> </div> +<div id="import-model" class="hidden medium-dialog import-group"> + <div id="import-model-header-text" class="import-header-text">Import Model</div> + <div class="import-container"> + <select id="model-type" onchange="setModelType()"> + <option value="-" selected="true">-- Choose Model Type --</option> + <option value="mtAcumos">Acumos</option> + </select> + <div id="mt-acumos" class="hidden"> + <hr/> + <label for="furl"><b>Acumos Federation URL</b></label> <input id="furl" type="text" name="furl" placeholder="https://server:9084" required/> + <button type="button" class="onap-action" onclick="lookupCatalogs()">Lookup</button> + </div> + <div id="c-acumos" class="hidden"> + <hr/> + <label for="cat-menu"><b>Select Catalog</b></label> <select id="cat-menu" onchange="chooseCatalog()"> + <option value="*">All Catalogs</option> + </select> + </div> + <div id="ac-sols" class="hidden"> + <hr/> + <label for="sol-menu"><b>Select Solution</b></label> <select id="sol-menu" onchange="chooseSolution()"> + <option value="*">All Solutions</option> + </select> + </div> + <div id="ac-revs" class="hidden"> + <hr/> + <label for="rev-menu"><b>Select Revision</b></label> <select id="rev-menu"> + <option value="*">All Revisions</option> + </select> + </div> + <hr/> + <button id="onboard" class="hidden onap-action" type="button" onclick="onBoard()">Onboard</button><br> + <b id="onboarding-in-progress" class="hidden">Onboarding - Please Wait ...</b> + </div> +</div> + +<div id="import-component" class="hidden medium-dialog import-group"> + <div id="import-component-header-text" class="import-header-text">Import Component Specification</div> + <div class="import-container"> + <label for="cspec"><b>Component Specification File</b></label> <input id="cspec" type="file" name="file" placeholder="Component-Spec.json" accept=".json,application/json" required> + <br><button id="uploadComponent" type="button" class="onap-action" onclick="onBoardComponent()">Upload</button> + </div> +</div> +<div id="import-data-format" class="hidden medium-dialog import-group"> + <div id="import-data-format-header-text" class="import-header-text">Import Data Format</div> + <div class="import-container"> + <label for="dfspec"><b>Data Format File</b></label> <input id="dfspec" type="file" name="file" placeholder="Data-Format.json" accept=".json,application/json" required> + <br><button id="uploadDataFormat" type="button" class="onap-action" onclick="onBoardDataFormat()">Upload</button> + </div> +</div> |