Slight performance improvement over fetching the same field every time
Created attachment 121112 [details] [review] Bug 28372: Use variables instead of repeated field lookup This simply replaces repeated lookups of the field with a variable test To test: 1 - Perform a search on the staff client 2 - Note the 'Format' in the record results 3 - Apply patch 4 - Repeat search 5 - Confirm Formats are unchanged
Hi Nick, this reads well. Could you please change the OPAC results file as well?
Created attachment 140833 [details] [review] Bug 28372: Update OPAC results XSLT to use variables for 007 Same test plan as before, but for OPAC
Created attachment 140839 [details] Screenshot - something went wrong with the OPAC display Something is wrong with the OPAC patch - see the screenshot. No details for a record are shown in the OPAC search results. The staff interface display is unchanged.
Created attachment 140859 [details] [review] Bug 28372: Update OPAC results XSLT to use variables for 007 Same test plan as before, but for OPAC
(In reply to David Nind from comment #4) > Created attachment 140839 [details] > Screenshot - something went wrong with the OPAC display > > Something is wrong with the OPAC patch - see the screenshot. > > No details for a record are shown in the OPAC search results. > > The staff interface display is unchanged. Should be fixed, forgot to delete one 'if'
Created attachment 140874 [details] [review] Bug 28372: Use variables instead of repeated field lookup This simply replaces repeated lookups of the field with a variable test To test: 1 - Perform a search on the staff client 2 - Note the 'Format' in the record results 3 - Apply patch 4 - Repeat search 5 - Confirm Formats are unchanged Signed-off-by: David Nind <david@davidnind.com> https://bugs.koha-community.org/show_bug.cgi?id=2837
Created attachment 140875 [details] [review] Bug 28372: Update OPAC results XSLT to use variables for 007 Same test plan as before, but for OPAC Signed-off-by: David Nind <david@davidnind.com> https://bugs.koha-community.org/show_bug.cgi?id=2837
(In reply to Nick Clemens from comment #6) > Should be fixed, forgot to delete one 'if' Thanks Nick! Now signed off.
Created attachment 141484 [details] [review] Bug 28372: Use variables instead of repeated field lookup This simply replaces repeated lookups of the field with a variable test To test: 1 - Perform a search on the staff client 2 - Note the 'Format' in the record results 3 - Apply patch 4 - Repeat search 5 - Confirm Formats are unchanged Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Created attachment 141485 [details] [review] Bug 28372: Update OPAC results XSLT to use variables for 007 Same test plan as before, but for OPAC Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Nice improvement readability wise.. no noticeable change in performance on my part, but I didn't measure it in any meaningful way. I think this is worthwhile for the readability regardless. Passing QA
Pushed to master for 22.11. Nice work everyone, thanks!