You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nifi.apache.org by al...@apache.org on 2016/02/06 04:36:46 UTC

[50/50] nifi git commit: NIFI-259: - Addressing issues that arose from a merge conflict.

NIFI-259: - Addressing issues that arose from a merge conflict.

Signed-off-by: Aldrin Piri <al...@apache.org>


Project: http://git-wip-us.apache.org/repos/asf/nifi/repo
Commit: http://git-wip-us.apache.org/repos/asf/nifi/commit/7314af61
Tree: http://git-wip-us.apache.org/repos/asf/nifi/tree/7314af61
Diff: http://git-wip-us.apache.org/repos/asf/nifi/diff/7314af61

Branch: refs/heads/master
Commit: 7314af61778b0803a3529551bcc169e981897a6c
Parents: 4df6512
Author: Matt Gilman <ma...@gmail.com>
Authored: Fri Feb 5 17:41:42 2016 -0500
Committer: Aldrin Piri <al...@apache.org>
Committed: Fri Feb 5 17:47:56 2016 -0500

----------------------------------------------------------------------
 .../src/main/webapp/js/nf/canvas/nf-settings.js | 146 +++++++------------
 1 file changed, 51 insertions(+), 95 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/nifi/blob/7314af61/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-settings.js
----------------------------------------------------------------------
diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-settings.js b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-settings.js
index dcec5c0..67bf385 100644
--- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-settings.js
+++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-settings.js
@@ -171,12 +171,6 @@ nf.Settings = (function () {
      * Hides the selected controller service.
      */
     var clearSelectedControllerService = function () {
-        if (nf.Canvas.isClustered()) {
-            $('#controller-service-availability-combo').combo('setSelectedOption', {
-                value: config.node
-            });
-        }
-
         $('#controller-service-type-description').text('');
         $('#controller-service-type-name').text('');
         $('#selected-controller-service-name').text('');
@@ -357,14 +351,14 @@ nf.Settings = (function () {
         if (nf.Canvas.isClustered()) {
             $('#controller-service-availability-combo').combo({
                 options: [{
-                        text: 'Node',
-                        value: config.node,
-                        description: 'This controller service will be available on the nodes only.'
-                    }, {
-                        text: 'Cluster Manager',
-                        value: config.ncm,
-                        description: 'This controller service will be available on the cluster manager only.'
-                    }]
+                    text: 'Node',
+                    value: config.node,
+                    description: 'This controller service will be available on the nodes only.'
+                }, {
+                    text: 'Cluster Manager',
+                    value: config.ncm,
+                    description: 'This controller service will be available on the cluster manager only.'
+                }]
             });
             $('#controller-service-availability-container').show();
         }
@@ -501,20 +495,20 @@ nf.Settings = (function () {
             headerText: 'Add Controller Service',
             overlayBackground: false,
             buttons: [{
-                    buttonText: 'Add',
-                    handler: {
-                        click: function () {
-                            addSelectedControllerService();
-                        }
+                buttonText: 'Add',
+                handler: {
+                    click: function () {
+                        addSelectedControllerService();
                     }
-                }, {
-                    buttonText: 'Cancel',
-                    handler: {
-                        click: function () {
-                            $(this).modal('hide');
-                        }
+                }
+            }, {
+                buttonText: 'Cancel',
+                handler: {
+                    click: function () {
+                        $(this).modal('hide');
                     }
-                }],
+                }
+            }],
             handler: {
                 close: function () {
                     // reset the node availability
@@ -706,15 +700,13 @@ nf.Settings = (function () {
                 }
             }
 
-            // always include a button to view the usage
-            markup += '<img src="images/iconUsage.png" title="Usage" class="pointer controller-service-usage" style="margin-top: 2px;"/>&nbsp;';
 
             return markup;
         };
 
         // define the column model for the controller services table
         var controllerServicesColumns = [
-            {id: 'moreDetails', field: 'moreDetails', name: '&nbsp;', resizable: false, formatter: moreControllerServiceDetails, sortable: true, width: 65, maxWidth: 65, toolTip: 'Sorts based on presence of bulletins'},
+            {id: 'moreDetails', field: 'moreDetails', name: '&nbsp;', resizable: false, formatter: moreControllerServiceDetails, sortable: true, width: 90, maxWidth: 90, toolTip: 'Sorts based on presence of bulletins'},
             {id: 'name', field: 'name', name: 'Name', sortable: true, resizable: true},
             {id: 'type', field: 'type', name: 'Type', formatter: typeFormatter, sortable: true, resizable: true},
             {id: 'state', field: 'state', name: 'State', formatter: controllerServiceStateFormatter, sortable: true, resizeable: true}
@@ -775,20 +767,6 @@ nf.Settings = (function () {
             } else if (controllerServicesGrid.getColumns()[args.cell].id === 'moreDetails') {
                 if (target.hasClass('view-controller-service')) {
                     nf.ControllerService.showDetails(controllerService);
-                } else if (target.hasClass('controller-service-usage')) {
-                    // close the settings dialog
-                    $('#shell-close-button').click();
-
-                    // open the documentation for this reporting task
-                    nf.Shell.showPage('../nifi-docs/documentation?' + $.param({
-                            select: nf.Common.substringAfterLast(controllerService.type, '.')
-                        })).done(function() {
-                        nf.Settings.showSettings();
-                    });
-                }
-            } else if (controllerServicesGrid.getColumns()[args.cell].id === 'moreDetails') {
-                if (target.hasClass('view-controller-service')) {
-                    nf.ControllerService.showDetails(controllerService);
                 }
             }
         });
@@ -968,12 +946,6 @@ nf.Settings = (function () {
      * Hides the selected reporting task.
      */
     var clearSelectedReportingTask = function () {
-        if (nf.Canvas.isClustered()) {
-            $('#reporting-task-availability-combo').combo('setSelectedOption', {
-                value: config.node
-            });
-        }
-
         $('#reporting-task-type-description').text('');
         $('#reporting-task-type-name').text('');
         $('#selected-reporting-task-name').text('');
@@ -1102,14 +1074,14 @@ nf.Settings = (function () {
         if (nf.Canvas.isClustered()) {
             $('#reporting-task-availability-combo').combo({
                 options: [{
-                        text: 'Node',
-                        value: config.node,
-                        description: 'This reporting task will be available on the nodes only.'
-                    }, {
-                        text: 'Cluster Manager',
-                        value: config.ncm,
-                        description: 'This reporting task will be available on the cluster manager only.'
-                    }]
+                    text: 'Node',
+                    value: config.node,
+                    description: 'This reporting task will be available on the nodes only.'
+                }, {
+                    text: 'Cluster Manager',
+                    value: config.ncm,
+                    description: 'This reporting task will be available on the cluster manager only.'
+                }]
             });
             $('#reporting-task-availability-container').show();
         }
@@ -1246,20 +1218,20 @@ nf.Settings = (function () {
             headerText: 'Add Reporting Task',
             overlayBackground: false,
             buttons: [{
-                    buttonText: 'Add',
-                    handler: {
-                        click: function () {
-                            addSelectedReportingTask();
-                        }
+                buttonText: 'Add',
+                handler: {
+                    click: function () {
+                        addSelectedReportingTask();
                     }
-                }, {
-                    buttonText: 'Cancel',
-                    handler: {
-                        click: function () {
-                            $(this).modal('hide');
-                        }
+                }
+            }, {
+                buttonText: 'Cancel',
+                handler: {
+                    click: function () {
+                        $(this).modal('hide');
                     }
-                }],
+                }
+            }],
             handler: {
                 close: function () {
                     // reset the node availability
@@ -1373,15 +1345,13 @@ nf.Settings = (function () {
                 }
             }
 
-            // always include a button to view the usage
-            markup += '<img src="images/iconUsage.png" title="Usage" class="pointer reporting-task-usage" style="margin-top: 2px;"/>&nbsp;';
 
             return markup;
         };
 
         // define the column model for the reporting tasks table
         var reportingTasksColumnModel = [
-            {id: 'moreDetails', field: 'moreDetails', name: '&nbsp;', resizable: false, formatter: moreReportingTaskDetails, sortable: true, width: 65, maxWidth: 65, toolTip: 'Sorts based on presence of bulletins'},
+            {id: 'moreDetails', field: 'moreDetails', name: '&nbsp;', resizable: false, formatter: moreReportingTaskDetails, sortable: true, width: 90, maxWidth: 90, toolTip: 'Sorts based on presence of bulletins'},
             {id: 'name', field: 'name', name: 'Name', sortable: true, resizable: true},
             {id: 'type', field: 'type', name: 'Type', sortable: true, resizable: true, formatter: typeFormatter},
             {id: 'state', field: 'state', name: 'Run Status', sortable: true, resizeable: true, formatter: reportingTaskRunStatusFormatter}
@@ -1443,20 +1413,6 @@ nf.Settings = (function () {
             } else if (reportingTasksGrid.getColumns()[args.cell].id === 'moreDetails') {
                 if (target.hasClass('view-reporting-task')) {
                     nf.ReportingTask.showDetails(reportingTask);
-                } else if (target.hasClass('reporting-task-usage')) {
-                    // close the settings dialog
-                    $('#shell-close-button').click();
-
-                    // open the documentation for this reporting task
-                    nf.Shell.showPage('../nifi-docs/documentation?' + $.param({
-                            select: nf.Common.substringAfterLast(reportingTask.type, '.')
-                        })).done(function() {
-                        nf.Settings.showSettings();
-                    });
-                }
-            } else if (reportingTasksGrid.getColumns()[args.cell].id === 'moreDetails') {
-                if (target.hasClass('view-reporting-task')) {
-                    nf.ReportingTask.showDetails(reportingTask);
                 }
             }
         });
@@ -1602,15 +1558,15 @@ nf.Settings = (function () {
                 tabStyle: 'settings-tab',
                 selectedTabStyle: 'settings-selected-tab',
                 tabs: [{
-                        name: 'General',
-                        tabContentId: 'general-settings-tab-content'
-                    }, {
-                        name: 'Controller Services',
-                        tabContentId: 'controller-services-tab-content'
-                    }, {
-                        name: 'Reporting Tasks',
-                        tabContentId: 'reporting-tasks-tab-content'
-                    }],
+                    name: 'General',
+                    tabContentId: 'general-settings-tab-content'
+                }, {
+                    name: 'Controller Services',
+                    tabContentId: 'controller-services-tab-content'
+                }, {
+                    name: 'Reporting Tasks',
+                    tabContentId: 'reporting-tasks-tab-content'
+                }],
                 select: function () {
                     var tab = $(this).text();
                     if (tab === 'General') {