[Bug 6600] New: library name linking wrong if current location is diff
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=6600 Bug #: 6600 Summary: library name linking wrong if current location is diff Classification: Unclassified Change sponsored?: --- Product: Koha Version: unspecified Platform: All OS/Version: All Status: NEW Severity: normal Priority: P5 Component: Templates AssignedTo: oleonard@myacpl.org ReportedBy: nengard@gmail.com QAContact: koha-bugs@lists.koha-community.org When you have a URL for a branch it shows in the holdings table in the OPAC. However it looks like the link is pulling from the home branch and the text is pulling from the current branch. Both should be pulling from the 'current branch' See here for an explanation: http://screencast.com/t/27tYlkbW -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the QA Contact for the bug.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=6600 Owen Leonard <oleonard@myacpl.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Version|unspecified |master Summary|library name linking wrong |Library name linking wrong |if current location is diff |if current location is | |different -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the QA Contact for the bug.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=6600 --- Comment #1 from Owen Leonard <oleonard@myacpl.org> 2011-07-19 13:20:56 UTC --- Created attachment 4668 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=4668 Proposed fix GetItemsInfo in Items.pm includes this join: LEFT JOIN branches ON items.homebranch = branches.branchcode This means that the branch URL (from the branches table) comes out as the URL for items.homebranch, thus the URL in the holdings output is the item's home branch even though the display might be showing a different current location. This patch changes the join to use items.holdingbranch. The join was originally added to fix Bug 3702, and based on the description of that feature I'm assuming this change is not harmful to other usages. However, it does make the assumption that the item's current (holding) branch is the branch we want to see information about. -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the QA Contact for the bug.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=6600 Owen Leonard <oleonard@myacpl.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Priority|P5 |PATCH-Sent Patch Status|--- |Needs Signoff -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the QA Contact for the bug.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=6600 Nicole C. Engard <nengard@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Patch Status|Needs Signoff |Signed Off -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the QA Contact for the bug.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=6600 Ian Walls <ian.walls@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |ian.walls@bywatersolutions. | |com --- Comment #2 from Ian Walls <ian.walls@bywatersolutions.com> 2011-09-01 16:29:32 UTC --- I'm extremely leery about making a change in a major C4 subroutine to fix such a minor display issue, but in all likelihood, it's *probably* safe, since the only information being pulled in from the branches table is branchurl. However, I think a further improvement can be made. The query only selects branchurl, none of the other branch information. Later in the subroutine, another query is done EACH ITEM RETURNED by the query (which is all the items for the biblio). Here's the code: #get branch information..... my $bsth = $dbh->prepare( "SELECT * FROM branches WHERE branchcode = ? " ); $bsth->execute( $data->{'holdingbranch'} ); if ( my $bdata = $bsth->fetchrow_hashref ) { $data->{'branchname'} = $bdata->{'branchname'}; } This is using holdingbranch, which explains why the branchname is indeed the holdingbranch. Improvement: Remove this extra check altogether, and just pull in the branchname from the original query, along side branchurl. This will reduce the number of queries MySQL must perform, improving (however marginally) the performance of this subroutine. Since it's a major workhorse of a subroutine (called many time all over the codebase), the net effect could be substantial. -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the QA Contact for the bug.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=6600 Paul Poulain <paul.poulain@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |paul.poulain@biblibre.com --- Comment #3 from Paul Poulain <paul.poulain@biblibre.com> 2011-10-06 14:36:48 UTC --- (In reply to comment #2)
I'm extremely leery about making a change in a major C4 subroutine to fix such a minor display issue, but in all likelihood, it's *probably* safe, since the only information being pulled in from the branches table is branchurl.
Ian: my proposal would be to mark "passed QA" and open another bug to improve the sub behaviour. ( Nicole: +++ for the screencast. Would be perfect if you could speak a little bit more slowly for poor ppl not speaking english natively ;-) ) -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the QA Contact for the bug.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=6600 Ian Walls <ian.walls@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Patch Status|Signed Off |Passed QA --- Comment #4 from Ian Walls <ian.walls@bywatersolutions.com> 2011-10-06 15:45:49 UTC --- GetItemsInfo is used in the following scripts: ./C4/XSLT.pm ./C4/Reserves.pm ./reports/reservereport.pl ./labels/label-item-search.pl ./virtualshelves/sendshelf.pl ./catalogue/moredetail.pl ./catalogue/detailprint.pl ./catalogue/detail.pl ./basket/basket.pl ./basket/sendbasket.pl ./serials/routing-preview.pl ./misc/migration_tools/rebuild_zebra.pl ./opac/opac-reserve.pl ./opac/opac-sendbasket.pl ./opac/opac-detail.pl ./opac/opac-ISBDdetail.pl ./opac/opac-sendshelf.pl Of those, only ./reports/reservereport.pl uses the branchname info, so I think that that whole section of GetItemsInfo can be safely removed. I'm going to mark this patch as Passed QA, and we can move the discussion of improving GetItemsInfo to another report. -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the QA Contact for the bug.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=6600 Chris Cormack <chris@bigballofwax.co.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |chris@bigballofwax.co.nz Patch Status|Passed QA |Patch Pushed --- Comment #5 from Chris Cormack <chris@bigballofwax.co.nz> 2011-10-06 22:39:45 UTC --- Pushed, please test well -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the QA Contact for the bug.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=6600 Owen Leonard <oleonard@myacpl.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Priority|PATCH-Sent (DO NOT USE) |P5 - low Status|Pushed to Master |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are the QA Contact for the bug. You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org