From c5b0931e558f7043b29ae1d2edc38dbd5607d289 Mon Sep 17 00:00:00 2001 From: Matt Gilman Date: Fri, 15 Dec 2017 09:49:13 -0500 Subject: [PATCH] NIFI-4436: - Minor UX tweaks. - Updating imports due to refactoring of Registry models. - Fixing checkstyle issues. --- .../main/java/org/apache/nifi/web/NiFiServiceFacade.java | 6 +++--- .../org/apache/nifi/web/StandardNiFiServiceFacade.java | 2 +- .../partials/canvas/import-flow-version-dialog.jsp | 2 +- .../WEB-INF/partials/canvas/save-flow-version-dialog.jsp | 8 ++++---- .../nifi-web/nifi-web-ui/src/main/webapp/css/dialog.css | 2 +- .../nifi-web-ui/src/main/webapp/css/flow-status.css | 4 ++++ .../src/main/webapp/js/nf/canvas/nf-canvas.js | 9 --------- .../src/main/webapp/js/nf/canvas/nf-context-menu.js | 4 +++- .../webapp/views/nf-ng-breadcrumbs-directive-view.html | 2 +- 9 files changed, 18 insertions(+), 21 deletions(-) diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/NiFiServiceFacade.java b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/NiFiServiceFacade.java index 6c20eac022..ab9674773e 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/NiFiServiceFacade.java +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/NiFiServiceFacade.java @@ -1289,7 +1289,7 @@ public interface NiFiServiceFacade { * Returns a FlowComparisonEntity that contains all of the local modifications since the Process Group * was last synchronized with the Flow Registry * - * @param processGroupId + * @param processGroupId the ID of the Process Group * @return a FlowComparisonEntity that contains all of the local modifications since the Process Group * was last synchronized with the Flow Registry * @throws IllegalStateException if the Process Group with the given ID is not under version control @@ -1455,8 +1455,8 @@ public interface NiFiServiceFacade { * update the contents of that Process Group * @return the Process Group */ - ProcessGroupEntity updateProcessGroupContents(NiFiUser user, Revision revision, String groupId, VersionControlInformationDTO versionControlInfo, VersionedFlowSnapshot snapshot, String componentIdSeed, - boolean verifyNotModified, boolean updateSettings, boolean updateDescendantVersionedFlows); + ProcessGroupEntity updateProcessGroupContents(NiFiUser user, Revision revision, String groupId, VersionControlInformationDTO versionControlInfo, VersionedFlowSnapshot snapshot, + String componentIdSeed, boolean verifyNotModified, boolean updateSettings, boolean updateDescendantVersionedFlows); // ---------------------------------------- // Component state methods diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/StandardNiFiServiceFacade.java b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/StandardNiFiServiceFacade.java index 1da63c2b42..1865bff595 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/StandardNiFiServiceFacade.java +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/StandardNiFiServiceFacade.java @@ -87,6 +87,7 @@ import org.apache.nifi.history.History; import org.apache.nifi.history.HistoryQuery; import org.apache.nifi.history.PreviousValue; import org.apache.nifi.registry.ComponentVariableRegistry; +import org.apache.nifi.registry.authorization.Permissions; import org.apache.nifi.registry.bucket.Bucket; import org.apache.nifi.registry.client.NiFiRegistryException; import org.apache.nifi.registry.flow.FlowRegistry; @@ -115,7 +116,6 @@ import org.apache.nifi.registry.flow.mapping.InstantiatedVersionedProcessGroup; import org.apache.nifi.registry.flow.mapping.InstantiatedVersionedProcessor; import org.apache.nifi.registry.flow.mapping.InstantiatedVersionedRemoteGroupPort; import org.apache.nifi.registry.flow.mapping.NiFiRegistryFlowMapper; -import org.apache.nifi.registry.model.authorization.Permissions; import org.apache.nifi.remote.RemoteGroupPort; import org.apache.nifi.remote.RootGroupPort; import org.apache.nifi.reporting.Bulletin; diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/partials/canvas/import-flow-version-dialog.jsp b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/partials/canvas/import-flow-version-dialog.jsp index 5ea622a6df..01e03d54c7 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/partials/canvas/import-flow-version-dialog.jsp +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/partials/canvas/import-flow-version-dialog.jsp @@ -25,7 +25,7 @@
-
Location
+
Bucket
diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/partials/canvas/save-flow-version-dialog.jsp b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/partials/canvas/save-flow-version-dialog.jsp index a7f54b6059..6017f37e3c 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/partials/canvas/save-flow-version-dialog.jsp +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/partials/canvas/save-flow-version-dialog.jsp @@ -19,14 +19,13 @@
Registry
-
+
-
-
Location
+
Bucket
@@ -34,10 +33,11 @@
Name
-
+
+
diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/dialog.css b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/dialog.css index 710c0fb3a7..82ffc381ea 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/dialog.css +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/dialog.css @@ -224,7 +224,7 @@ div.progress-label { height: 85px; } -#save-flow-version-registry-combo, #save-flow-version-registry { +#save-flow-version-name-field, #save-flow-version-name { width: 100%; margin-right: 10px; } diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/flow-status.css b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/flow-status.css index 42f9afd48c..35ef016598 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/flow-status.css +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/flow-status.css @@ -67,6 +67,10 @@ padding-left: 5px; } +#flow-status-container { + width: 90%; +} + #search-container { overflow: hidden; height: 32px; diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-canvas.js b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-canvas.js index 692dd581ae..00dd4a8601 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-canvas.js +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-canvas.js @@ -609,14 +609,6 @@ }); }; - // define a function for update the flow status dimensions - var updateFlowStatusContainerSize = function () { - $('#flow-status-container').css({ - 'width': ((($('#nifi-logo').width() + $('#component-container').width())/$(window).width())*100)*2 + '%' - }); - }; - updateFlowStatusContainerSize(); - // listen for events to go to components $('body').on('GoTo:Component', function (e, item) { nfCanvasUtils.showComponent(item.parentGroupId, item.id); @@ -641,7 +633,6 @@ } updateGraphSize(); - updateFlowStatusContainerSize(); // resize shell when appropriate var shell = $('#shell-dialog'); diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-context-menu.js b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-context-menu.js index 0c21838091..5571e08c7d 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-context-menu.js +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-context-menu.js @@ -541,7 +541,9 @@ } // check the selection for version control information - return versionControlInformation.state !== 'LOCALLY_MODIFIED' && versionControlInformation.state !== 'LOCALLY_MODIFIED_AND_STALE'; + return versionControlInformation.state !== 'LOCALLY_MODIFIED' && + versionControlInformation.state !== 'LOCALLY_MODIFIED_AND_STALE' && + versionControlInformation.state !== 'SYNC_FAILURE'; }; /** diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/views/nf-ng-breadcrumbs-directive-view.html b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/views/nf-ng-breadcrumbs-directive-view.html index a69de46eae..19018d356f 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/views/nf-ng-breadcrumbs-directive-view.html +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/views/nf-ng-breadcrumbs-directive-view.html @@ -22,7 +22,7 @@ limitations under the License. » - +