]> git.koha-community.org Git - koha.git/commit
Bug 5529 Absence or Presence of lists not being reliably returned
authorColin Campbell <colin.campbell@ptfs-europe.com>
Thu, 7 Apr 2011 14:25:27 +0000 (16:25 +0200)
committerChris Cormack <chrisc@catalyst.net.nz>
Thu, 7 Apr 2011 22:51:47 +0000 (10:51 +1200)
commit0cf2eccfe926f77753a2b948e2babf077e2975d3
tree76b7519cc983dfc82c8fe7a1e5fbe6aa711ee87f
parent22dc04e24c9af810672ee8f6e313316f3bcc9a59
Bug 5529 Absence or Presence of lists not being reliably returned

C4::VirtualShelves::GetRecentShelves contained some rather confused
code The contents of the requested list are returned in an arrayref
which was in its turn being wrapped needlessly in an array
As a result the returned array always consisted of a single element
irrespective of the number of lists.
Made the routine return the arrayref, which can now be tested directly
Unfortunately rather than fixing this we had previously coded around it
assuming it to be a "design" decision. Have amended other calls of
the subroutine resulting in some hopefully less obscure code

Fixed logic error in the results template which displayed new list
within a test for the presence of lists

Removed the offset parameter from the sql in the routine as it was hardcoded
to 0 i.e. the default value

Signed-off-by: fdurand <frederic.durand@univ-lyon2.fr>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
C4/Auth.pm
C4/VirtualShelves.pm
C4/VirtualShelves/Page.pm
catalogue/search.pl
koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/results.tmpl
virtualshelves/addbybiblionumber.pl