Description
Julian Maurice
2014-12-30 14:49:31 UTC
Created attachment 34830 [details] [review] Bug 13501: Add jQuery UI plugin combobox It allows autocompletion on selects. Based on http://jqueryui.com/autocomplete/#combobox Note: This patch reset $.fn.button to the jQuery UI one (was overwritten by Bootstrap) Created attachment 34831 [details] [review] Bug 13501: Use combobox plugin on cataloguing and batch items edit pages Created attachment 34855 [details] [review] Bug 13501: Use combobox plugin on cataloguing and batch items edit pages Tested with drop downs in cataloguing (edit and new record/item) and batch item editing. Works as expected. Signed-off-by: Marc Véron <veron@veron.ch> Created attachment 34856 [details] [review] Bug 13501: Add jQuery UI plugin combobox It allows autocompletion on selects. Based on http://jqueryui.com/autocomplete/#combobox Note: This patch reset $.fn.button to the jQuery UI one (was overwritten by Bootstrap) Tested together with patch #2 Signed-off-by: Marc Véron <veron@veron.ch> Created attachment 34857 [details] [review] Bug 13501: Use combobox plugin on cataloguing and batch items edit pages Tested with drop downs in cataloguing (edit and new record/item) and batch item editing. Works as expected. Signed-off-by: Marc Véron <veron@veron.ch> Created attachment 34897 [details] [review] [PASSED QA] Bug 13501: Add jQuery UI plugin combobox It allows autocompletion on selects. Based on http://jqueryui.com/autocomplete/#combobox Note: This patch reset $.fn.button to the jQuery UI one (was overwritten by Bootstrap) Tested together with patch #2 Signed-off-by: Marc Veron <veron@veron.ch> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Created attachment 34898 [details] [review] [PASSED QA] Bug 13501: Use combobox plugin on cataloguing and batch items edit pages Tested with drop downs in cataloguing (edit and new record/item) and batch item editing. Works as expected. Signed-off-by: Marc Veron <veron@veron.ch> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Looks good, but could perhaps use some styling, as the box is the same color as the background on the edit items page. Of course, it used to be the same color as the background on the edit record page, so it's kind of a wash in that respect ; ) I think this is a useful enhancement, but I think in its current state it removes some of the built-in usability of a default HTML dropdown. The new dropdown has a fixed width, which in my system means it is not wide enough to show the complete description for some of my codes. After I have selected an item from the dropdown, I expect to be able to see the full description of the selected item by opening the dropdown again. In a <select>, expanding a dropdown with a selected item will scroll the list to the selected item and show it highlighted. In this version it expands the list but doesn't scroll or indicate in any way that it was selected. I think those are issues which ought to be addressed. It works fairly well with keyboard navigation, but it now takes more clicks to choose an item via keyboard. Old: Tab to <select>, type the first letters of the item you're looking for. Item is selected. New: Tab to combobox, type the word you're looking for. Use arrow key to select the item you want. That may not be a deal-breaker for the feature, but I know the different will be noticeable to catalogers. Another problematic difference: After you select an item from the list, if you hit ENTER the form submits. We have been working to eliminate that behavior from forms in Koha, so I would consider it a regression to introduce a feature that brings it back. Created attachment 40654 [details] [review] Bug 13501: Add JS library select2, use it on cataloguing and batch items edit pages Select2's selects behaviour is closer to native selects and I think it addresses all Owen's issues. Created attachment 40708 [details] [review] Bug 13501: Add JS library select2, use it on cataloguing and batch items edit pages Signed-off-by: Josef Moravec <josef.moravec@gmail.com> I would like to get another signoff to confirm that the concerns raised in comment 11 are fixed. Tested in cataloguing (edit and new record/item) and also in batch modification. I had a filter where I can type a part of the authorized value : it works as expected. I can also use the dropdown to select a value and this one is highlighted when I'm on it. When choosing a value in the list, I can see the full description but after have chose, long descriptions are cut (We can have full description when passing mouse over). When using keybord, I have to use enter to select a value. For what I see, this feature works only in cataloguing (I haven't understand at the beginning because I didn't see it in the description). It would be wonderful if we can also have it in acquisitions or patrons) For me, it works functionnaly so I will sign it off but I can't answer to Owen's questions about regresion. Sonia Tested on batchMod.pl: 1/ The "required" is before the select. 2/ After selecting a value, the description is truncated (see comment 9). 3/ (In reply to Owen Leonard from comment #9) > Old: Tab to <select>, type the first letters of the item you're looking for. > Item is selected. > > New: Tab to combobox, type the word you're looking for. Use arrow key to > select the item you want. Still valid. Maybe something like http://stackoverflow.com/questions/20989458/select2-open-dropdown-on-focus 4/ Add the new JS plugin to the about page. Marked as Failed QA. Created attachment 44213 [details] [review] Bug 13501: Indentation fix (batchMod-edit.tt) Created attachment 44214 [details] [review] Bug 13501: Move "Required" and checkbox after input/select Created attachment 44215 [details] [review] Bug 13501: Downgrade Select2 to version 3.5.4 version 3.5.4 is more "keyboard-friendly" than version 4.0.0 + add Select2 to the about page Created attachment 44216 [details] [review] Bug 13501: Add JS library select2 3.5.4 use it on cataloguing and batch items edit pages Note: this is a squash of two commits: - Add JS library select2, use it on cataloguing and batch items edit pages - Downgrade Select2 to version 3.5.4 Created attachment 44217 [details] [review] Bug 13501: Indentation fix (batchMod-edit.tt) Created attachment 44218 [details] [review] Bug 13501: Move "Required" and checkbox after input/select Created attachment 45966 [details] [review] Bug 13501: Move "Required" and checkbox after input/select Signed-off-by: Aleisha <aleishaamohia@hotmail.com> Aleisha, you have only signed off the last patch, could you confirm you have tested the whole feature? (In reply to Jonathan Druart from comment #23) > Aleisha, you have only signed off the last patch, could you confirm you have > tested the whole feature? Yes I have! sorry, meant to sign off on all of the patches Owen, I would like to get your signoff on this one. I am ready to pass QA it as I think the behavior is consistent and it could be very useful for users. Julian, maybe it would be better to use a minified version of select2.css. Created attachment 48368 [details] [review] Bug 13501: Add JS library select2 3.5.4 CSS minified + Signed-off-by line added Created attachment 48369 [details] [review] Bug 13501: Indentation fix (batchMod-edit.tt) Signed-off-by line added Created attachment 48370 [details] [review] Bug 13501: Move "Required" and checkbox after input/select No changes When editing a biblio, if a field is required it's highlighted. With your patch, the highlight does no longer appear. Could you have a look? Jonathan I don't think I see what you're seeing. Could you provide more details? (In reply to Owen Leonard from comment #31) > Jonathan I don't think I see what you're seeing. Could you provide more > details? Steps to recreate: - Mark a subfield as required in your default (or whatever) biblio framemwork - Link it to an authorised value list (to get the dropdown list), LANG for instance - Edit a biblio - Do not fill (or delete the subfield if already filled) - Save You will get an alert "Can't save this record because the following field aren't filled:" And the not filled mandatory fields should be highlighted. With this patch, they are not. And just found another bug: If you click on the "Delete subfield" icon, it won't behave as before, the empty entry is not added and selected. Created attachment 54634 [details] [review] Bug 13501: Add JS library select2 3.5.4 use it on cataloguing and batch items edit pages Signed-off-by: Aleisha <aleishaamohia@hotmail.com> Created attachment 54635 [details] [review] Bug 13501: Indentation fix (batchMod-edit.tt) Signed-off-by: Aleisha <aleishaamohia@hotmail.com> Created attachment 54636 [details] [review] Bug 13501: Move "Required" and checkbox after input/select Signed-off-by: Aleisha <aleishaamohia@hotmail.com> Created attachment 54637 [details] [review] Bug 13501: Highlight select2 control if field is required and value is missing Created attachment 54638 [details] [review] Bug 13501: Fix behavior of 'Delete subfield' button on select2 controls Patches rebased on master + 2 more patches for comment 32 and comment 33 (In reply to Julian Maurice from comment #37) > Created attachment 54637 [details] [review] [review] > Bug 13501: Highlight select2 control if field is required and value is > missing Are you sure you want to remove select2.min.css? (In reply to Jonathan Druart from comment #40) > (In reply to Julian Maurice from comment #37) > > Created attachment 54637 [details] [review] [review] [review] > > Bug 13501: Highlight select2 control if field is required and value is > > missing > > Are you sure you want to remove select2.min.css? I didn't remove select2.min.css, I added a new file select2.css for custom CSS related to select2 Created attachment 54674 [details] [review] Bug 13501: Add JS library select2 3.5.4 use it on cataloguing and batch items edit pages Signed-off-by: Aleisha <aleishaamohia@hotmail.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Created attachment 54675 [details] [review] Bug 13501: Indentation fix (batchMod-edit.tt) Signed-off-by: Aleisha <aleishaamohia@hotmail.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Created attachment 54676 [details] [review] Bug 13501: Move "Required" and checkbox after input/select Signed-off-by: Aleisha <aleishaamohia@hotmail.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Created attachment 54677 [details] [review] Bug 13501: Highlight select2 control if field is required and value is missing Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Created attachment 54678 [details] [review] Bug 13501: Fix behavior of 'Delete subfield' button on select2 controls Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> (In reply to Julian Maurice from comment #41) > (In reply to Jonathan Druart from comment #40) > > (In reply to Julian Maurice from comment #37) > > > Created attachment 54637 [details] [review] [review] [review] [review] > > > Bug 13501: Highlight select2 control if field is required and value is > > > missing > > > > Are you sure you want to remove select2.min.css? > > I didn't remove select2.min.css, I added a new file select2.css for custom > CSS related to select2 Sorry I have misread the diff, everything is fine! Pushed to master for 16.11, thanks Julian! I have proposed on bug 17817 to temporarily deactivate this feature as it introduced important issues. Enhancement, skipping for 16.05.x |