1
0
Fork 0
mirror of https://github.com/portainer/portainer.git synced 2025-07-24 15:59:41 +02:00

Merge branch "feat107-remove-select-all" into internal

This commit is contained in:
Anthony Lapenna 2016-08-04 11:31:35 +12:00
commit 548a458b9a
10 changed files with 7 additions and 43 deletions

View file

@ -2,7 +2,6 @@ angular.module('volumes', [])
.controller('VolumesController', ['$scope', '$state', 'Volume', 'Messages', 'errorMsgFilter',
function ($scope, $state, Volume, Messages, errorMsgFilter) {
$scope.state = {};
$scope.state.toggle = false;
$scope.state.selectedItemCount = 0;
$scope.sortType = 'Driver';
$scope.sortReverse = true;
@ -16,17 +15,6 @@ function ($scope, $state, 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++;