If you want to search the log with a limit on the librarian, the form expects a borrowernumber. Having autocomplete on the field would enable the user to fill the field without knowing the borrowernumber beforehand.
Created attachment 110938 [details] [review] Bug 26572: Add autocomplete to librarian field in log viewer This patch adds patron autocomplete to the librarian field in the log viewer search form. Also changed: Some HTML markup errors in the template have been corrected: Labels with invalid corresponding ids or with no valid id. To test, apply the patch and go to Tools -> Log Viewer. Type a name or cardnumber into the "Librarian" form field. This should trigger an autocomplete dropdown. Select a patron and confirm that the field is populated with the correct borrowernumber.
Created attachment 110977 [details] [review] Bug 26572: Add autocomplete to librarian field in log viewer This patch adds patron autocomplete to the librarian field in the log viewer search form. Also changed: Some HTML markup errors in the template have been corrected: Labels with invalid corresponding ids or with no valid id. To test, apply the patch and go to Tools -> Log Viewer. Type a name or cardnumber into the "Librarian" form field. This should trigger an autocomplete dropdown. Select a patron and confirm that the field is populated with the correct borrowernumber. Signed-off-by: David Nind <david@davidnind.com>
Patch no longer applies cleanly, please rebase! Apply? [(y)es, (n)o, (i)nteractive] y Applying: Bug 26572: Add autocomplete to librarian field in log viewer Using index info to reconstruct a base tree... M koha-tmpl/intranet-tmpl/prog/en/modules/tools/viewlog.tt M koha-tmpl/intranet-tmpl/prog/js/viewlog.js Falling back to patching base and 3-way merge... Auto-merging koha-tmpl/intranet-tmpl/prog/js/viewlog.js CONFLICT (content): Merge conflict in koha-tmpl/intranet-tmpl/prog/js/viewlog.js Auto-merging koha-tmpl/intranet-tmpl/prog/en/modules/tools/viewlog.tt error: Failed to merge in the changes. Patch failed at 0001 Bug 26572: Add autocomplete to librarian field in log viewer The copy of the patch that failed is found in: .git/rebase-apply/patch When you have resolved this problem run "git bz apply --continue". If you would prefer to skip this patch, instead run "git bz apply --skip". To restore the original branch and stop patching run "git bz apply --abort".
Created attachment 111637 [details] [review] Bug 26572: Add autocomplete to librarian field in log viewer This patch adds patron autocomplete to the librarian field in the log viewer search form. Also changed: Some HTML markup errors in the template have been corrected: Labels with invalid corresponding ids or with no valid id. To test, apply the patch and go to Tools -> Log Viewer. Type a name or cardnumber into the "Librarian" form field. This should trigger an autocomplete dropdown. Select a patron and confirm that the field is populated with the correct borrowernumber. Signed-off-by: David Nind <david@davidnind.com>
Created attachment 111664 [details] [review] Bug 26572: Add autocomplete to librarian field in log viewer This patch adds patron autocomplete to the librarian field in the log viewer search form. Also changed: Some HTML markup errors in the template have been corrected: Labels with invalid corresponding ids or with no valid id. To test, apply the patch and go to Tools -> Log Viewer. Type a name or cardnumber into the "Librarian" form field. This should trigger an autocomplete dropdown. Select a patron and confirm that the field is populated with the correct borrowernumber. Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Please rebase on top of bug 26592.
Created attachment 111736 [details] [review] Bug 26592: (QA follow-up) Escape strings in autocomplete This patch updates the construction of the autocomplete dropdown so that values are escaped.
Created attachment 112984 [details] [review] Bug 26572: (QA follow-up) Escape strings in autocomplete This patch updates the construction of the autocomplete dropdown so that values are escaped.
Pushed to master for 20.11, thanks to everybody involved!
enhancement will not be backported to 20.05.x