-
Notifications
You must be signed in to change notification settings - Fork 96
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
In Bootstrap 5.2.3 Ajax-Bootstrap-Select doesn't work #218
Comments
I noticed that when I load an element in the ajax-select, and after loading it a second time (same identical item) the ajax-select adds it like a new item and so on repeating the element: the correct behavior should be that if the element is previus loaded the library hasn't to load it anymore... PS: I don't expect anyone to fix it, I'm just saying this for clarity and transparency... thank you |
This is a bug on the bootrap-select script. |
The fix almost work, but there is still a issue. |
I had issue with multiple items being selected, not sure if will fix with the issue you have. $('#selector')
.selectpicker()
.ajaxSelectPicker({
ajax: {
url: '/ajax_search',
},
locale: {
emptyTitle: 'Search...'
},
preserveSelected : false
});
//Added the code below
$('#selector').on('shown.bs.select', function() {
$('#selector').selectpicker('val', '');
}); |
No, it doesn't work, but what works is to change preserveSelected to true. The selected item is shown in a different line/section but it works fine that way. |
Thank you for that, selection is working fine without the added code. |
I like it more with the preserveSelected to true because in my case it separates the options from the one that is selected, but this depends on the use you are giving to the control. Without that it doesn't work when you select an option that is above the current selection. |
Hello guys, |
Hi everybody, unfortunately I'm testing bootstrap 5 with ajax select but it doesn't work.
I have used the bootstrap-select 1.14.0-beta3 that works with bootstrap 5 without problem, in a simple/classic select, but when I attempt to use ajax-select (that uses bootstrap-select 1.14.0-beta3) the result is not reliable: as the result list has a strange behavior, for example if you want to chose more than one element, you can't despite multi selection is enabled; moreover when you click dropdown-button to open it and soon after close it, the library sets a list of separator inside of the select.
Thank you very much for the library very usefull and admirable, reason why I would continue to use it.
The text was updated successfully, but these errors were encountered: