Bug 13406 - Add classes to MARC Authority display to enable CSS styling
Summary: Add classes to MARC Authority display to enable CSS styling
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Staff interface (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement (vote)
Assignee: Jane Sandberg
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-12-08 07:36 UTC by paxed
Modified: 2019-10-14 19:56 UTC (History)
6 users (show)

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


Attachments
Bug 13406 : Add styling classes to authority MARC detail display (3.73 KB, patch)
2018-09-16 19:24 UTC, Jane Sandberg
Details | Diff | Splinter Review
Bug 13406 : Add styling classes to authority MARC detail display (3.73 KB, patch)
2018-09-16 19:25 UTC, Jane Sandberg
Details | Diff | Splinter Review
Bug 13406 : Add styling classes to authority MARC detail display (3.79 KB, patch)
2018-09-16 20:34 UTC, Brendan Gallagher
Details | Diff | Splinter Review
Bug 13406: (follow-up) Add styling classes to authority MARC detail display (2.45 KB, patch)
2018-09-16 23:03 UTC, Jane Sandberg
Details | Diff | Splinter Review
Bug 13406: Add styling classes to authority MARC detail display (3.87 KB, patch)
2018-09-18 13:52 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 13406: (follow-up) Add styling classes to authority MARC detail display (2.58 KB, patch)
2018-09-18 13:52 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 13406: (RM follow-up) Add missing filter (1.27 KB, patch)
2018-09-19 14:36 UTC, Nick Clemens
Details | Diff | Splinter Review
Bug 13406: (RM follow-up) Add missing filter (1.37 KB, patch)
2018-09-20 13:02 UTC, ByWater Sandboxes
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description paxed 2014-12-08 07:36:14 UTC
For example, the tag title line is just a single div:

 <div class="tag_title"> 046 ## - SPECIAL CODED DATES </div>

which makes it impossible to style the tag number, the indicators and the tag description separately.
Comment 1 Jane Sandberg 2018-09-16 19:24:00 UTC
Created attachment 78995 [details] [review]
Bug 13406 : Add styling classes to authority MARC detail display

When viewing authority MARC records in the staff client (detail view), the
MARC tags were not displaying with the tag_num, tag_desc, tag_ind1,
tag_ind2, and desc classes, which made it impossible to add styles
to these specific parts of a MARC tag.  This commit adds these
styles (which are the same as the classes in the bibliographic
MARC detail display).

To test:
1) Open the staff client, then click Authorities.
2) Search for an authority record.
3) Click on Details.
4) Examine some MARC fields.  Note that the entire tag title line
is in a single <div>.
5) Apply this commit.
6) Repeat steps 1-3.
7) Notice that the tag title line is now separated into several
spans, each with their own classes.

Signed-off-by: Jane Sandberg <sandbej@linnbenton.edu>
Comment 2 Jane Sandberg 2018-09-16 19:25:21 UTC
Created attachment 78996 [details] [review]
Bug 13406 : Add styling classes to authority MARC detail display

When viewing authority MARC records in the staff client (detail view), the
MARC tags were not displaying with the tag_num, tag_desc, tag_ind1,
tag_ind2, and desc classes, which made it impossible to add styles
to these specific parts of a MARC tag.  This commit adds these
styles (which are the same as the classes in the bibliographic
MARC detail display).

To test:
1) Open the staff client, then click Authorities.
2) Search for an authority record.
3) Click on Details.
4) Examine some MARC fields.  Note that the entire tag title line
is in a single <div>.
5) Apply this commit.
6) Repeat steps 1-3.
7) Notice that the tag title line is now separated into several
spans, each with their own classes.

Signed-off-by: Jane Sandberg <sandbej@linnbenton.edu>
Comment 3 Brendan Gallagher 2018-09-16 20:34:58 UTC
Created attachment 78999 [details] [review]
Bug 13406 : Add styling classes to authority MARC detail display

When viewing authority MARC records in the staff client (detail view), the
MARC tags were not displaying with the tag_num, tag_desc, tag_ind1,
tag_ind2, and desc classes, which made it impossible to add styles
to these specific parts of a MARC tag.  This commit adds these
styles (which are the same as the classes in the bibliographic
MARC detail display).

To test:
1) Open the staff client, then click Authorities.
2) Search for an authority record.
3) Click on Details.
4) Examine some MARC fields.  Note that the entire tag title line
is in a single <div>.
5) Apply this commit.
6) Repeat steps 1-3.
7) Notice that the tag title line is now separated into several
spans, each with their own classes.

Signed-off-by: Jane Sandberg <sandbej@linnbenton.edu>

Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
Comment 4 Jonathan Druart 2018-09-16 21:38:05 UTC
Change in the behavior, not sure it is expected:
Before the patch: 040 ## - CATALOGING SOURCE 
After the path  : 040 - CATALOGING SOURCE 

There is call to C4::Koha::display_marc_indicators that is no longer taken into account.
Comment 5 Katrin Fischer 2018-09-16 21:57:53 UTC
I think it's possible that indicators are not always numeric - not sure if that factors in here. Just something I have seen in the wild.
Comment 6 Jane Sandberg 2018-09-16 23:03:35 UTC
Created attachment 79026 [details] [review]
Bug 13406: (follow-up) Add styling classes to authority MARC detail display

Signed-off-by: Jane Sandberg <sandbej@linnbenton.edu>
Comment 7 Jonathan Druart 2018-09-18 13:52:43 UTC
Created attachment 79053 [details] [review]
Bug 13406: Add styling classes to authority MARC detail display

When viewing authority MARC records in the staff client (detail view), the
MARC tags were not displaying with the tag_num, tag_desc, tag_ind1,
tag_ind2, and desc classes, which made it impossible to add styles
to these specific parts of a MARC tag.  This commit adds these
styles (which are the same as the classes in the bibliographic
MARC detail display).

To test:
1) Open the staff client, then click Authorities.
2) Search for an authority record.
3) Click on Details.
4) Examine some MARC fields.  Note that the entire tag title line
is in a single <div>.
5) Apply this commit.
6) Repeat steps 1-3.
7) Notice that the tag title line is now separated into several
spans, each with their own classes.

Signed-off-by: Jane Sandberg <sandbej@linnbenton.edu>

Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 8 Jonathan Druart 2018-09-18 13:52:48 UTC
Created attachment 79054 [details] [review]
Bug 13406: (follow-up) Add styling classes to authority MARC detail display

Signed-off-by: Jane Sandberg <sandbej@linnbenton.edu>
Amended patch: replace tab characters with spaces

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 9 Jonathan Druart 2018-09-18 13:53:12 UTC
Great first patches Jane, congrats!
Comment 10 Jane Sandberg 2018-09-18 14:22:37 UTC
Thanks for your help, Jonathan!  This was fun. :-)
Comment 11 Nick Clemens 2018-09-19 14:36:21 UTC
Created attachment 79117 [details] [review]
Bug 13406: (RM follow-up) Add missing filter
Comment 12 Nick Clemens 2018-09-19 14:39:36 UTC
Awesome work all!

Pushed to master for 18.11
Comment 13 Martin Renvoize 2018-09-20 10:59:36 UTC
Nice little enhancement with no unexpected visible effects, simply allows end users more options for customisation.  Backporting to 18.05.x series for 18.05.04, nice work Jane, welcome to the team :)
Comment 14 ByWater Sandboxes 2018-09-20 13:02:44 UTC
Created attachment 79173 [details] [review]
Bug 13406: (RM follow-up) Add missing filter

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>

Signed-off-by: qwer <qwer@qwer.qwer>