Bug 16167 - Remove prefs to drive authorised value images
Summary: Remove prefs to drive authorised value images
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Architecture, internals, and plumbing (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Jonathan Druart
QA Contact: Testopia
URL:
Keywords:
Depends on: 16041
Blocks: 16408
  Show dependency treegraph
 
Reported: 2016-03-30 08:23 UTC by Jonathan Druart
Modified: 2019-04-29 00:05 UTC (History)
3 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Medium patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:


Attachments
Bug 16167: Remove Authorised value images (28.18 KB, patch)
2016-03-30 08:33 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 16167: Atomic update (733 bytes, patch)
2016-04-04 07:40 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 16167: Remove Authorised value images prefs (23.46 KB, patch)
2016-04-15 08:49 UTC, Jonathan Druart
Details | Diff | Splinter Review
[SIGNED-OFF] Bug 16167: Atomic update (838 bytes, patch)
2016-04-15 14:08 UTC, Owen Leonard
Details | Diff | Splinter Review
[SIGNED-OFF] Bug 16167: Remove Authorised value images prefs (23.56 KB, patch)
2016-04-15 14:08 UTC, Owen Leonard
Details | Diff | Splinter Review
[PASSED QA] Bug 16167: Atomic update (853 bytes, patch)
2016-04-25 13:03 UTC, Katrin Fischer
Details | Diff | Splinter Review
[PASSED QA] Bug 16167: Remove Authorised value images prefs (23.58 KB, patch)
2016-04-25 13:03 UTC, Katrin Fischer
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Jonathan Druart 2016-03-30 08:23:40 UTC
The feature to attach an image to an authorised value does not seem to work perfectly and it's possible that nobody uses it.
I'd suggest to discuss about that removal on this bug report.
Comment 1 Jonathan Druart 2016-03-30 08:24:57 UTC
From bug 16041:
There are 2 prefs to drive this feature: StaffAuthorisedValueImages and
AuthorisedValueImages. AuthorisedValueImages is not added by sysprefs.sql and
does not appear in updatedatabase.pl, we could easily imagine that
nobody uses it.
With XSLT enabled, the feature is only visible on a record detail page
at the OPAC, if AuthorisedValueImages is set.
Otherwise you need to turn the XSLT off. In this case you will see the
images on the result list (OPAC+Staff interfaces) and OPAC detail page,
but not the Staff detail page.
Comment 2 Jonathan Druart 2016-03-30 08:33:21 UTC Comment hidden (obsolete)
Comment 3 Jonathan Druart 2016-04-04 07:40:24 UTC Comment hidden (obsolete)
Comment 4 Owen Leonard 2016-04-12 13:06:50 UTC
I think we should retain the ability to associate an image with an authorized value because libraries like having an image associated with a collection code or shelving location on the advanced search page (like you can with item types).

I think the StaffAuthorisedValueImages and AuthorisedValueImages preferences should be removed because they don't really do anything, but keep the image-handling.
Comment 5 Jonathan Druart 2016-04-13 07:55:40 UTC
(In reply to Owen Leonard from comment #4)
> I think we should retain the ability to associate an image with an
> authorized value because libraries like having an image associated with a
> collection code or shelving location on the advanced search page (like you
> can with item types).
> 
> I think the StaffAuthorisedValueImages and AuthorisedValueImages preferences
> should be removed because they don't really do anything, but keep the
> image-handling.

We need to keep the pref to avoid the useless processing done at different places.
I have not found any uses of the images anywhere unless non-XSLT views.
If you find a place where it is used, please let me know.
Comment 6 Katrin Fischer 2016-04-13 10:18:15 UTC
I think what Owen was trying to say is that the feature for linking icons with authorised valued should be kept. Because this is currently in use on the advanced search page (and maybe in other spots).

But the expectation for icons to show up on the result list and the detail page is wrong at the moment for XSLT and that we should remove the prefs saying so and also the code related to that and possibly the normal views as they are deprecated. 

It would be a first as we haven't actively removed non-XSLT features so far, although the views have been deprecated for a while now. So if we do it - we should make sure it's noted clearly somewhere in the Release notes I think.
Comment 7 Jonathan Druart 2016-04-15 08:49:26 UTC Comment hidden (obsolete)
Comment 8 Jonathan Druart 2016-04-15 08:51:02 UTC
(In reply to Katrin Fischer from comment #6)
> I think what Owen was trying to say is that the feature for linking icons
> with authorised valued should be kept. Because this is currently in use on
> the advanced search page (and maybe in other spots).
> 
> But the expectation for icons to show up on the result list and the detail
> page is wrong at the moment for XSLT and that we should remove the prefs
> saying so and also the code related to that and possibly the normal views as
> they are deprecated. 
> 
> It would be a first as we haven't actively removed non-XSLT features so far,
> although the views have been deprecated for a while now. So if we do it - we
> should make sure it's noted clearly somewhere in the Release notes I think.

With this last patch the prefs are removed but the ability to choose an icon for a AV is still possible. If defined, the icon will be displayed to the adv search form.
Note that if the prefs were off but an image defined, before this patch the image was not displayed, now it will.
Comment 9 Owen Leonard 2016-04-15 14:08:19 UTC Comment hidden (obsolete)
Comment 10 Owen Leonard 2016-04-15 14:08:25 UTC Comment hidden (obsolete)
Comment 11 Katrin Fischer 2016-04-25 13:02:30 UTC
Note: the detail pages in OPAC don't work for me with and without this patch.
Comment 12 Katrin Fischer 2016-04-25 13:03:01 UTC
Created attachment 50631 [details] [review]
[PASSED QA] Bug 16167: Atomic update

Signed-off-by: Owen Leonard <oleonard@myacpl.org>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 13 Katrin Fischer 2016-04-25 13:03:32 UTC
Created attachment 50632 [details] [review]
[PASSED QA] Bug 16167: Remove Authorised value images prefs

There are 2 prefs to drive this feature: StaffAuthorisedValueImages and
AuthorisedValueImages. AuthorisedValueImages is not added by
sysprefs.sql and does not appear in updatedatabase.pl, we could easily
imagine that nobody uses it.

With XSLT enabled, the feature is only visible on a record detail page
at the OPAC, if AuthorisedValueImages is set. Otherwise you need to turn
the XSLT off. In this case you will see the images on the result list
(OPAC+Staff interfaces) and OPAC detail page, but not the Staff detail
page.

This patch suggests to remove completely this feature as it does not
work correctly.

The ability to assign an image to an authorised value is now always
displayed, but the image will only be displayed on the advanced search
if defined.

Test plan:
Confirm that the authorised value images are no longer visible at the
opac and the staff interfaces.
The prefs should have been removed too.

Signed-off-by: Owen Leonard <oleonard@myacpl.org>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 14 Kyle M Hall (khall) 2016-04-29 14:06:57 UTC
Pushed to master for the 16.05 release. Thanks Jonathan!
Comment 15 Doug Dearden 2016-11-04 20:25:44 UTC
I did an upgrade to 16.05.05.000 and got these errors that seem to be related (maybe only the second one):

updatedatabase.pl: At least one authorised value has an icon defined (imageurl)

updatedatabase.pl: The system preference AuthorisedValueImages or StaffAuthorisedValueImages could be turned off if you are not aware of this feature.

I went looking for the two system preferences mentioned and couldn't find them.
Comment 16 Jonathan Druart 2016-11-07 08:32:45 UTC
(In reply to Doug Dearden from comment #15)
> I did an upgrade to 16.05.05.000 and got these errors that seem to be
> related (maybe only the second one):
> 
> updatedatabase.pl: At least one authorised value has an icon defined
> (imageurl)
> 
> updatedatabase.pl: The system preference AuthorisedValueImages or
> StaffAuthorisedValueImages could be turned off if you are not aware of this
> feature.
> 
> I went looking for the two system preferences mentioned and couldn't find
> them.

Yes the output is confusing I agree. Actually we decided to display the warning on bug 16041 but the decided to remove the 2 prefs from 16167.