@@ -, +, @@ - As a quick test for custom CSS, go to Administration -> System preferences and locate the IntranetUserCSS preference. - Add this testing CSS: .marcnote { font-size:140%; font-family: serif; } .marcnote-500 { background-color: #66FFCC; } .marcnote-511 { background-color: #99FFFF; } .marcnote-520 { background-color: #CCFF00; } .marcnote-521 { background-color: #CCFFFF; } .marcnote-538 { background-color: #FFCCCC; } .marcnote-546 { background-color: #FFFFCC; } - Locate a record with multiple notes fields. In the sample data, record 46, "Viridiana" is a good example which works well with the above CSS. - On the bibliographic detail page for the record, click the "Descriptions" tab. - Each MARC note should be colored according to the tag it comes from. - Inspect the HTML to confirm that each paragraph also has its own unique ID. --- Koha/Biblio.pm | 4 ++-- .../prog/en/modules/catalogue/detail.tt | 12 ++++++------ 2 files changed, 8 insertions(+), 8 deletions(-) --- a/Koha/Biblio.pm +++ a/Koha/Biblio.pm @@ -1080,10 +1080,10 @@ sub get_marc_notes { push @marcnotes, { marcnote => $field->as_string($othersub) }; foreach my $sub ( $field->subfield('u') ) { $sub =~ s/^\s+|\s+$//g; # trim - push @marcnotes, { marcnote => $sub }; + push @marcnotes, { marcnote => $sub, tag => $tag }; } } else { - push @marcnotes, { marcnote => $field->as_string() }; + push @marcnotes, { marcnote => $field->as_string(), tag => $tag }; } } return \@marcnotes; --- a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt +++ a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt @@ -738,12 +738,12 @@
[% FOREACH MARCNOTE IN MARCNOTES %] -

- [% IF MARCNOTE.marcnote.match('^https?://\S+$') %] - [% MARCNOTE.marcnote | html %] - [% ELSE %] - [% MARCNOTE.marcnote | html | html_line_break %] - [% END %] +

+ [% IF MARCNOTE.marcnote.match('^https?://\S+$') %] + [% MARCNOTE.marcnote | html %] + [% ELSE %] + [% MARCNOTE.marcnote | html | html_line_break %] + [% END %]

[% END %]
--