Skip to content

Instantly share code, notes, and snippets.

@mrbaboon
Last active August 29, 2015 14:15
Show Gist options
  • Save mrbaboon/4255d84640468737156b to your computer and use it in GitHub Desktop.
Save mrbaboon/4255d84640468737156b to your computer and use it in GitHub Desktop.
ui-select issue
$scope.fetchSearchableUsers = function (query) {
messageService.Contacts.get({name: query, allContacts: true, contactType: 'user'}, function(contacts){
$scope.searchableUsers = contacts.results;
});
};
<ui-select multiple
ng-model="threadFilters.subscribers"
theme="select2"
style="width: 100%;">
<ui-select-match placeholder="Search Users..">{{ $item.name }}</ui-select-match>
<ui-select-choices repeat="user in searchableUsers"
refresh="fetchSearchableUsers($select.search)"
refresh-delay="350">
{{ user.name }}
</ui-select-choices>
</ui-select>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment