Bug 9366 - On cataloguing each user can easily display tags or not
Summary: On cataloguing each user can easily display tags or not
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Cataloging (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Jonathan Druart
QA Contact: Marcel de Rooy
URL:
Keywords:
Depends on: 9803
Blocks: 12410
  Show dependency treegraph
 
Reported: 2013-01-08 13:47 UTC by Jonathan Druart
Modified: 2015-06-04 23:33 UTC (History)
5 users (show)

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


Attachments
Bug 9366: On cataloguing each user can easily display tags or not (8.42 KB, patch)
2013-01-08 13:53 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 9366: FIX typo s/class/style (1.11 KB, patch)
2013-01-08 15:33 UTC, Jonathan Druart
Details | Diff | Splinter Review
[SIGNED-OFF] Bug 9366: On cataloguing each user can easily display tags or not (8.51 KB, patch)
2013-01-10 15:34 UTC, Nicole C. Engard
Details | Diff | Splinter Review
[SIGNED-OFF] Bug 9366: FIX typo s/class/style (1.17 KB, patch)
2013-01-10 15:39 UTC, Nicole C. Engard
Details | Diff | Splinter Review
Bug 9366: On cataloguing each user can easily display tags or not (8.39 KB, patch)
2013-02-18 08:41 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 9366: FIX typo s/class/style (1.29 KB, patch)
2013-02-18 08:41 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 9366: On cataloguing each user can easily display tags or not (8.05 KB, patch)
2013-03-14 08:39 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 9366: FIX typo s/class/style + add a margin-left for the checkbox (1.16 KB, patch)
2013-03-14 08:39 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 9366: FIX typo s/class/style (1.21 KB, patch)
2013-03-14 08:41 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 9366: On cataloguing each user can easily display tags or not (8.11 KB, patch)
2013-03-28 15:13 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 9366: FIX typo s/class/style (1.26 KB, patch)
2013-03-28 15:13 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 9366: On cataloguing each user can easily display tags or not (8.19 KB, patch)
2013-06-12 10:21 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 9366: FIX typo s/class/style (1.26 KB, patch)
2013-06-12 10:21 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 9366: On cataloguing each user can easily display tags or not (10.29 KB, patch)
2014-03-04 16:23 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 9366: On cataloguing each user can easily display tags or not (10.33 KB, patch)
2014-03-10 15:05 UTC, Biblibre Sandboxes
Details | Diff | Splinter Review
[PASSED QA] Bug 9366: On cataloguing each user can easily display tags or not (10.89 KB, patch)
2014-03-14 08:40 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 2013-01-08 13:47:45 UTC
If the syspref hide_marc is set to "don't display", tags are not shown by default.
The idea is to add a checkbox to hide/show tags directly on the cataloguing page.
Comment 1 Jonathan Druart 2013-01-08 13:53:32 UTC Comment hidden (obsolete)
Comment 2 Owen Leonard 2013-01-08 14:47:27 UTC
This appears to be working correctly, but I see one little markup error:

<label><input id="hide_tags" type="checkbox" class="vertical-align:middle;"/>Hide tags</label>

class="vertical-align:middle" should be style="vertical-align:middle"

"Hide tags" should probably have a space before it too, for legibility.
Comment 3 Jonathan Druart 2013-01-08 15:33:23 UTC Comment hidden (obsolete)
Comment 4 Jonathan Druart 2013-01-08 15:33:34 UTC
(In reply to comment #2)
> This appears to be working correctly, but I see one little markup error

Oops yes thanks.
Fixed!
Comment 5 Nicole C. Engard 2013-01-10 15:34:47 UTC Comment hidden (obsolete)
Comment 6 Nicole C. Engard 2013-01-10 15:39:41 UTC Comment hidden (obsolete)
Comment 7 Katrin Fischer 2013-02-17 16:21:56 UTC
Patch doesn't apply - please rebase.

I noticed that you delete larger parts of the existing code, but I don't see how this is relevant for the new feature. Could you explain some?
Comment 8 Jonathan Druart 2013-02-18 08:39:03 UTC
Katrin,
The deleted code was used to hide some inputs. Now this is done through the javascript code.
Comment 9 Jonathan Druart 2013-02-18 08:41:05 UTC Comment hidden (obsolete)
Comment 10 Jonathan Druart 2013-02-18 08:41:15 UTC Comment hidden (obsolete)
Comment 11 Katrin Fischer 2013-03-14 06:18:49 UTC
Hi Jonathan - could you please fix the merge conflict with current master? I didn't want to do it wrong.
Comment 12 Jonathan Druart 2013-03-14 08:39:22 UTC Comment hidden (obsolete)
Comment 13 Jonathan Druart 2013-03-14 08:39:51 UTC Comment hidden (obsolete)
Comment 14 Jonathan Druart 2013-03-14 08:41:06 UTC Comment hidden (obsolete)
Comment 15 Jonathan Druart 2013-03-14 08:42:39 UTC
Katrin, I switch back to Signed Off. Conflicts was quite easy.
I modified the followup by replacing the vertical-align with a margin-left (vertical-align seems useless with the Bootstrap toolbar).
Comment 16 Jonathan Druart 2013-03-28 15:13:52 UTC Comment hidden (obsolete)
Comment 17 Jonathan Druart 2013-03-28 15:13:57 UTC Comment hidden (obsolete)
Comment 18 Chris Cormack 2013-06-12 09:54:56 UTC
Lots of conflicts in koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/addbiblio.tt
Comment 19 Jonathan Druart 2013-06-12 10:21:05 UTC Comment hidden (obsolete)
Comment 20 Jonathan Druart 2013-06-12 10:21:09 UTC Comment hidden (obsolete)
Comment 21 Marcel de Rooy 2013-07-18 08:11:23 UTC
QA: Looking at this one now.
Comment 22 Marcel de Rooy 2013-07-18 08:35:42 UTC
QA Comment:
I have two comments. The first having more weight than the second.

If I am hiding descriptions, I am not sure what the purpose is of Hide tags in that case. If both tag and description is gone, a user cannot know what he is doing.
Note that this is possible too in current master also but only via setting both prefs to disabled (which is less likely).
IMO We should not offer to hide both labels; we are only supporting cataloging errors here ;)
I suggest to only offer Hide tags if the description is visible. 

Furtermore, I have some doubts about keeping the pref while adding the checkbox. Maybe we actually want some "staff patron cataloging preference" instead, allowing some users to have the tags and others not..

Setting this report to In Discussion. Hoping for some feedback from all involved.
Comment 23 Jonathan Druart 2013-07-18 08:58:01 UTC
(In reply to M. de Rooy from comment #22)
> QA Comment:
> I have two comments. The first having more weight than the second.
> 
> If I am hiding descriptions, I am not sure what the purpose is of Hide tags
> in that case. If both tag and description is gone, a user cannot know what
> he is doing.
> Note that this is possible too in current master also but only via setting
> both prefs to disabled (which is less likely).
> IMO We should not offer to hide both labels; we are only supporting
> cataloging errors here ;)
> I suggest to only offer Hide tags if the description is visible.

I preferred to keep existing choices instead of restricting them. But maybe you are right, it could be improved.

> Furtermore, I have some doubts about keeping the pref while adding the
> checkbox. Maybe we actually want some "staff patron cataloging preference"
> instead, allowing some users to have the tags and others not..

The pref is the default behavior, if we remove it, catalogers will have to check/uncheck the checkbox each time. Currently, Koha does not offer the possibility to have this kind of preference per patron.

Waiting for others points of view.
Comment 24 Marcel de Rooy 2013-07-18 09:43:51 UTC
(In reply to Jonathan Druart from comment #23)
> The pref is the default behavior, if we remove it, catalogers will have to
> check/uncheck the checkbox each time. Currently, Koha does not offer the
> possibility to have this kind of preference per patron.

For completeness: I do not suggest to remove it on its own. I am thinking about having a patron preference controlling it, because it seems that we need something more than current functionality.
Comment 25 Marcel de Rooy 2013-07-18 09:45:20 UTC
Note that we already have patron messaging preferences. You could easily have patron cataloging preferences too?
Comment 26 Jonathan Druart 2013-07-18 10:13:25 UTC
(In reply to M. de Rooy from comment #25)
> Note that we already have patron messaging preferences. You could easily
> have patron cataloging preferences too?

Yes, but it is completely out of the scope of this bug :)
Comment 27 Jonathan Druart 2013-10-28 11:25:36 UTC
I leave the "in discussion" status since there is no discussion.
Switch back to Signed Off.
Comment 28 Katrin Fischer 2013-12-26 17:57:18 UTC
Some comments on this:

1) Why not make the option "sticky" and saving the choice in a cookie? As it is currently it seems that you will have to recheck the checkbox for every new title that you catalog. It would be nice if it behaved the same as the "Show MARC tag documentation links" feature.

2) There seems to be a weird problem when switching frameworks:
- Go to cataloguing
- Create a new record based on the default framework
- Switch the framework to "Audio..."
- Switch back to default

What I had happen was that after switching the framework, I would be redirectd to the item form and an empty record was saved. I couldn't reproduce this behaviour on master without the patch applied.

3) Why not place the "Hide tags" next to "Show MARC tag documentation links"?

4) As we have a separate option to hide documentation links, I think hiding the tags should only hide the tags, but not the documentation links.
Comment 29 Jonathan Druart 2014-03-04 16:23:28 UTC Comment hidden (obsolete)
Comment 30 Jonathan Druart 2014-03-04 16:25:56 UTC
(In reply to Katrin Fischer from comment #28)
> Some comments on this:

I took all your comments into account.
Comment 31 Biblibre Sandboxes 2014-03-10 15:05:19 UTC
Patch tested with a sandbox, by Joel Aloi <aloi54@live.fr>
Comment 32 Biblibre Sandboxes 2014-03-10 15:05:48 UTC Comment hidden (obsolete)
Comment 33 Katrin Fischer 2014-03-14 08:40:44 UTC
Created attachment 26327 [details] [review]
[PASSED QA] Bug 9366: On cataloguing each user can easily display tags or not

If the syspref hide_marc is set to "don't display", tags are not shown
by default.
This patch adds a checkbox to hide/show tags directly on the
cataloguing page. The value is stored in a cookie.

Test plan:
Enable/disable the sysprefs hide_marc and advancedMARCeditor in order to
check if the display is according with what the user want.
Reload the page and verify the value is kept.
The first value of the cookie is retrieved from the hide_marc pref.

Bonus:
This patch removes the link "Show MARCtag documentation links" if the
syspref advancedMARCeditor is enabled.

Signed-off-by: Joel Aloi <aloi54@live.fr>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
This works as described, the editor will remember the choices
made by the cataloguer.

Passes all tests and QA script.

Notes:
- The error messages for mandatory fields upon saving only
give the tag number and not the description, so this might require
to turn back on the tag display.

- The advancedMARCeditor doesn't display the documentation links before
and after the patch was applied. I think it could still be useful for
an advanced cataloger to be able to look up information on a field quickly.
Comment 34 Galen Charlton 2014-03-14 15:20:16 UTC
Pushed to master.  Thanks, Jonathan!