angularjs-dropdown-multiselect icon indicating copy to clipboard operation
angularjs-dropdown-multiselect copied to clipboard

Selecting another value

Open eugenevk opened this issue 7 years ago • 1 comments

Hello, I have set selectionLimit to 1. If I have selected a value and then want to select another value, I first have to unselect the value currently chosen. Can this be done automatically by selecting another value from the list? It would prevent the user has to do an additional click.

eugenevk avatar Jan 12 '18 11:01 eugenevk

For anybody who sees this I ended up setting selectionLimit to 2 and then adding the event onMaxSelectionReached where I set whatever model I have to the second selected option. e.g. html: (simplified for purpose of example) <div ng-dropdown-multiselect="" selected-model="vm.coolio" events="vm.multiEvents"></div> controller: vm.multiEvents = {onMaxSelectionReached: function(){ vm.coolio = [vm.coolio[1]] } };

zatchgordon avatar Apr 27 '18 16:04 zatchgordon