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

--- Comment #1 from babar junaid <[email protected]> ---
Created attachment 210875
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=210875&action=edit
Bug 44028: Clear the AV_descriptions cache when an authorised value's code or
category changes

Bug 44028: Clear the AV_descriptions cache when an authorised value's code or
category changes

Koha::AuthorisedValue->store cleared the AV_descriptions:<category> cache
only when lib or lib_opac changed. Changing the code (or the category)
left C4::Biblio::GetAuthorisedValueDesc serving the old mapping until the
cache was flushed: items with the old code kept the old description, items
with the new code showed none.

This patch also clears it when authorised_value or category changes, and
clears the old category too when a value moves to another one.

Test plan:
1. Run prove t/db_dependent/AuthorisedValues.t without the patch to the
   module: the new subtest fails.
2. Apply the patch: prove t/db_dependent/AuthorisedValues.t passes.
3. In the staff interface (memcached on), view an item whose shelving
   location shows its description.
4. Administration > Authorised values > LOC, edit that value and change
   only its code.
5. Reload the item: without the patch the old description is still shown;
   with the patch it is not (the item's code no longer exists).
6. Edit a description only: still updated straight away, as before.

Sponsored-by: Koha Solutions

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list -- [email protected]
To unsubscribe send an email to [email protected]
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

Reply via email to