https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43269
--- Comment #4 from Tomás Cohen Arazi (tcohen) <[email protected]> --- Created attachment 203462 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=203462&action=edit Bug 43269: Add Koha::AuthorisedValues->description_for my $desc = Koha::AuthorisedValues->description_for({ category => $category, value => $value, opac => $opac, }); Adds a cached class method that resolves an authorised value to its description. Pre-fetches all values for the category on first access using Koha::Caches. When opac is true and lib_opac is available, returns lib_opac. Otherwise returns lib. Cache key: AV_descriptions:$category (compatible with C4::Biblio::GetAuthorisedValueDesc) Returns empty string if value is falsy or not found. Test plan: 1. Apply patch 2. Run: $ ktd --shell k$ prove t/db_dependent/Koha/AuthorisedValues.t => SUCCESS: Tests pass! 3. Sign off :-D -- You are receiving this mail because: 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/
