From 111cd4ac64a1c1b00fbba9571ce5299d5193ea87 Mon Sep 17 00:00:00 2001 From: Anthony Lapenna Date: Thu, 4 Aug 2016 11:29:29 +1200 Subject: [PATCH] feat(ui): remove the ability to select all entities from list views (#104) --- app/components/images/images.html | 2 +- app/components/images/imagesController.js | 12 ------------ app/components/networks/networks.html | 2 +- app/components/networks/networksController.js | 13 ------------- app/components/volumes/volumes.html | 2 +- app/components/volumes/volumesController.js | 12 ------------ 6 files changed, 3 insertions(+), 40 deletions(-) diff --git a/app/components/images/images.html b/app/components/images/images.html index c44f1a431..4bfe5ec59 100644 --- a/app/components/images/images.html +++ b/app/components/images/images.html @@ -66,7 +66,7 @@ - +
Id diff --git a/app/components/images/imagesController.js b/app/components/images/imagesController.js index 5eac079dd..ee824fcbc 100644 --- a/app/components/images/imagesController.js +++ b/app/components/images/imagesController.js @@ -4,7 +4,6 @@ function ($scope, $state, Image, Messages) { $scope.state = {}; $scope.sortType = 'Created'; $scope.sortReverse = true; - $scope.state.toggle = false; $scope.state.selectedItemCount = 0; $scope.config = { @@ -17,17 +16,6 @@ function ($scope, $state, Image, Messages) { $scope.sortType = sortType; }; - $scope.toggleSelectAll = function () { - angular.forEach($scope.state.filteredImages, function (i) { - i.Checked = $scope.state.toggle; - }); - if ($scope.state.toggle) { - $scope.state.selectedItemCount = $scope.state.filteredImages.length; - } else { - $scope.state.selectedItemCount = 0; - } - }; - $scope.selectItem = function (item) { if (item.Checked) { $scope.state.selectedItemCount++; diff --git a/app/components/networks/networks.html b/app/components/networks/networks.html index 96add077d..9d4e5736c 100644 --- a/app/components/networks/networks.html +++ b/app/components/networks/networks.html @@ -28,7 +28,7 @@ - +
Name diff --git a/app/components/networks/networksController.js b/app/components/networks/networksController.js index 3cde28bfa..59bca6874 100644 --- a/app/components/networks/networksController.js +++ b/app/components/networks/networksController.js @@ -1,9 +1,7 @@ angular.module('networks', []) .controller('NetworksController', ['$scope', 'Network', 'Messages', 'errorMsgFilter', function ($scope, Network, Messages, errorMsgFilter) { - $scope.state = {}; - $scope.state.toggle = false; $scope.state.selectedItemCount = 0; $scope.sortType = 'Name'; $scope.sortReverse = true; @@ -13,17 +11,6 @@ function ($scope, Network, Messages, errorMsgFilter) { $scope.sortType = sortType; }; - $scope.toggleSelectAll = function () { - angular.forEach($scope.state.filteredNetworks, function (i) { - i.Checked = $scope.state.toggle; - }); - if ($scope.state.toggle) { - $scope.state.selectedItemCount = $scope.state.filteredNetworks.length; - } else { - $scope.state.selectedItemCount = 0; - } - }; - $scope.selectItem = function (item) { if (item.Checked) { $scope.state.selectedItemCount++; diff --git a/app/components/volumes/volumes.html b/app/components/volumes/volumes.html index 6c66bc2f0..0391682da 100644 --- a/app/components/volumes/volumes.html +++ b/app/components/volumes/volumes.html @@ -28,7 +28,7 @@ - +
Name diff --git a/app/components/volumes/volumesController.js b/app/components/volumes/volumesController.js index 4b684e60c..035eb481c 100644 --- a/app/components/volumes/volumesController.js +++ b/app/components/volumes/volumesController.js @@ -2,7 +2,6 @@ angular.module('volumes', []) .controller('VolumesController', ['$scope', 'Volume', 'Messages', 'errorMsgFilter', function ($scope, Volume, Messages, errorMsgFilter) { $scope.state = {}; - $scope.state.toggle = false; $scope.state.selectedItemCount = 0; $scope.sortType = 'Name'; $scope.sortReverse = true; @@ -12,17 +11,6 @@ function ($scope, Volume, Messages, errorMsgFilter) { $scope.sortType = sortType; }; - $scope.toggleSelectAll = function () { - angular.forEach($scope.state.filteredVolumes, function (i) { - i.Checked = $scope.state.toggle; - }); - if ($scope.state.toggle) { - $scope.state.selectedItemCount = $scope.state.filteredVolumes.length; - } else { - $scope.state.selectedItemCount = 0; - } - }; - $scope.selectItem = function (item) { if (item.Checked) { $scope.state.selectedItemCount++;