ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sevdoki...@apache.org
Subject [02/16] incubator-ignite git commit: IGNITE-843: Fixed remove items from groups.
Date Fri, 24 Jul 2015 13:46:13 GMT
IGNITE-843: Fixed remove items from groups.


Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/bbee7131
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/bbee7131
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/bbee7131

Branch: refs/heads/ignite-1121
Commit: bbee7131543c8f66be954fe8d313aca2e41110a7
Parents: e4c0470
Author: AKuznetsov <akuznetsov@gridgain.com>
Authored: Thu Jul 23 15:43:23 2015 +0700
Committer: AKuznetsov <akuznetsov@gridgain.com>
Committed: Thu Jul 23 15:43:23 2015 +0700

----------------------------------------------------------------------
 .../main/js/controllers/metadata-controller.js  | 22 ++++++++++++++++----
 1 file changed, 18 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/bbee7131/modules/web-control-center/src/main/js/controllers/metadata-controller.js
----------------------------------------------------------------------
diff --git a/modules/web-control-center/src/main/js/controllers/metadata-controller.js b/modules/web-control-center/src/main/js/controllers/metadata-controller.js
index 74ece5c..bf58fe2 100644
--- a/modules/web-control-center/src/main/js/controllers/metadata-controller.js
+++ b/modules/web-control-center/src/main/js/controllers/metadata-controller.js
@@ -552,16 +552,30 @@ controlCenterModule.controller('metadataController', ['$scope', '$http',
'$commo
         };
 
         $scope.tableGroupNewItemActive = function (groupIndex) {
-            var groupName = $scope.backupItem.groups[groupIndex].name;
+            var groups = $scope.backupItem.groups;
+
+            if (groups) {
+                var group = groups[groupIndex];
+
+                if (group) {
+                    var groupName = group.name;
+
+                    return $table.tableNewItemActive({model: groupName});
+                }
+            }
 
-            return $table.tableNewItemActive({model: groupName});
+            return false;
         };
 
         $scope.tableGroupItemEditing = function (groupIndex, index) {
             var groups = $scope.backupItem.groups;
 
-            if (groups)
-                return $table.tableEditing({model: groups[groupIndex].name}, index);
+            if (groups) {
+                var group = groups[groupIndex];
+
+                if (group)
+                    return $table.tableEditing({model: group.name}, index);
+            }
 
             return false;
         };


Mime
View raw message