You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Oct 2, 2019. It is now read-only.
UPDATE: I have now been able to reproduce this in a plunker. Everything seems to be working as intended with UI Select 0.16.1 but breaks if you switch to 0.17.1. Here is my plunk, you can swap the commented script lines to see how it works/doesn't work with the two versions: https://plnkr.co/edit/fduuxU?p=preview
I have been having this problem where when I click to open my select all options show as they should. Then if I type in the options filter as they should but as soon as I delete what I typed so the filter is empty again, instead of all options reappearing in the select dropdown as they should, all options except the currently selected option reappear. I have been unable to reproduce this behavior with a plunker so I am not sure what is going on here.Here is my data and code for reference:
priorityOptions = [
{"text":"(1) High","value":"(1) High"},
{"text":"(2) Normal","value":"(2) Normal"},
{"text":"(3) Low","value":"(3) Low"}
];
//currentItem is a json object with various data including the PriorityValue field as follows:
currentItem.PriorityValue = "(2) Normal";
Here is my HTML:
<ui-select ng-model="currentItem.PriorityValue" theme="bootstrap" title="Choose a priority">
<ui-select-match allow-clear="true">{{$select.selected.text}}</ui-select-match>
<ui-select-choices repeat="option.value as option in (data.priority.options | myfilter: $select.selected: $select.search: 'text')">
<span ng-bind="option.text"></span>
</ui-select-choices>
</ui-select>
note: I was originally just using filter: $select.search but when I started experiencing this issue I wrote my own filter to make sure the correct object was being passed back. Here is the code for my custom filter:
I can verify that when the search box is empty the entire PriorityOptions object listed above is correctly returned from my filter function and so I would expect all options to list, and yet they still do not. The currently selected option always dissapears once you enter some search value and then clear the box.
Also if I include the allow-clear option on the ui-select-match tag above and use it to clear the select then everything works as it should. If I type in the search it filters and if I delete the entered text all options reappear. But, as soon as I select an option it goes back to how it was where the selected option never reappears after you type in the box.
The text was updated successfully, but these errors were encountered:
Angular: v1.5.0-rc.2
UI-Select: 0.17.1
Bootstrap/Select2/Selectize CSS (if applicable): Bootstrap 3.3.6
UPDATE: I have now been able to reproduce this in a plunker. Everything seems to be working as intended with UI Select 0.16.1 but breaks if you switch to 0.17.1. Here is my plunk, you can swap the commented script lines to see how it works/doesn't work with the two versions:
https://plnkr.co/edit/fduuxU?p=preview
I have been having this problem where when I click to open my select all options show as they should. Then if I type in the options filter as they should but as soon as I delete what I typed so the filter is empty again, instead of all options reappearing in the select dropdown as they should, all options except the currently selected option reappear. I have been unable to reproduce this behavior with a plunker so I am not sure what is going on here.Here is my data and code for reference:
Here is my HTML:
note: I was originally just using filter: $select.search but when I started experiencing this issue I wrote my own filter to make sure the correct object was being passed back. Here is the code for my custom filter:
I can verify that when the search box is empty the entire PriorityOptions object listed above is correctly returned from my filter function and so I would expect all options to list, and yet they still do not. The currently selected option always dissapears once you enter some search value and then clear the box.
Also if I include the allow-clear option on the ui-select-match tag above and use it to clear the select then everything works as it should. If I type in the search it filters and if I delete the entered text all options reappear. But, as soon as I select an option it goes back to how it was where the selected option never reappears after you type in the box.
The text was updated successfully, but these errors were encountered: