diff --git a/js/controller/CardController.js b/js/controller/CardController.js index 37bd3d3fd..786b3260a 100644 --- a/js/controller/CardController.js +++ b/js/controller/CardController.js @@ -149,20 +149,20 @@ app.controller('CardController', function ($scope, $rootScope, $routeParams, $lo /** * Show ui-select field when clicking the add button */ - $scope.showAssignUser = function() { - $scope.status.showAssignUser = true; - $timeout(function() { - $('#assignUserSelect').find('a').click(); - }); + $scope.toggleAssignUser = function() { + $scope.status.showAssignUser = !$scope.status.showAssignUser; + if ($scope.status.showAssignUser === true) { + $timeout(function () { + $('#assignUserSelect').find('a').click(); + }); + } }; /** * Hide ui-select when select list is closed */ $scope.assingUserOpenClose = function(isOpen) { - if (!isOpen) { - $scope.status.showAssignUser = false; - } + $scope.status.showAssignUser = isOpen; }; $scope.addAssignedUser = function(item) { diff --git a/templates/part.card.php b/templates/part.card.php index e8e43a3eb..cfbfcf862 100644 --- a/templates/part.card.php +++ b/templates/part.card.php @@ -51,9 +51,9 @@

t('Assign users')); ?>

- +
-
+