[Koha-bugs] [Bug 22173] Search Groups broken by change in expected structure

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Fri Jan 18 19:21:21 CET 2019


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22173

--- Comment #1 from Kyle M Hall <kyle at bywatersolutions.com> ---
Created attachment 84209
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=84209&action=edit
Bug 22173: Search Groups broken by change in expected structure

The original logic of Search Groups using the heirarchical library groups was
to enable search groups on a root group and have each sub group be a search
group listed in the pulldown:

RootGroup:
   SearchGroup1:
        LibraryA
        LibraryB
   SearchGroup2:
        LibraryC
        LibraryD
   SearchGroup3:
        LibraryE
        LibraryF

At some point, the code was changed to expect the each search group to be the
root group:

RootSearchGroup1:
    LibraryA
    LibraryB

RootSearchGroup2:
    LibraryC
    LibraryD

RootSearchGroup3:
    LibraryE
    LibraryF

It's likely that both styles are being used in production now with different
versions. If a library upgrades, their search groups will be broken. If we
revert the change, currently up to date libraries will have search groups
broken.

Instead, we should accommodate both configurations.

So, if a root group has libraries as direct children, it should be displayed as
a search group. If it does not, we should display the child search groups
instead.

Test Plan:
1) Set up a root group with multiple subgroups each with libraries,
   enable staff and opac search groups for that root group
2) Note the root group is displayed in all the search pulldowns instead
   of the subgroups
3) Apply this patch
4) Restart all the things!
5) Note the search pulldowns now contain the subgroups instead
6) Create another root group, add only libraries to it.
   Set it as a search group for staff and opac.
7) Note the search pulldowns now contain this group as well!

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list