View | Details | Raw Unified | Return to bug 9162
Collapse All | Expand All

(-)a/C4/Biblio.pm (-9 / +13 lines)
Lines 1686-1701 sub GetMarcNotes { Link Here
1686
    my $note = "";
1686
    my $note = "";
1687
    my $tag  = "";
1687
    my $tag  = "";
1688
    my $marcnote;
1688
    my $marcnote;
1689
    my %blacklist = map { $_ => 1 } split(/,/,C4::Context->preference('NotesBlacklist'));
1689
    foreach my $field ( $record->field($scope) ) {
1690
    foreach my $field ( $record->field($scope) ) {
1690
        my $value = $field->as_string();
1691
	my $tag = $field->tag();
1691
        if ( $note ne "" ) {
1692
        if (!$blacklist{$tag}) {
1692
            $marcnote = { marcnote => $note, };
1693
        	my $value = $field->as_string();
1693
            push @marcnotes, $marcnote;
1694
        	if ( $note ne "" ) {
1694
            $note = $value;
1695
            	    $marcnote = { marcnote => $note, };
1695
        }
1696
	            push @marcnotes, $marcnote;
1696
        if ( $note ne $value ) {
1697
        	    $note = $value;
1697
            $note = $note . " " . $value;
1698
        	}
1698
        }
1699
        	if ( $note ne $value ) {
1700
            	    $note = $note . " " . $value;
1701
        	}
1702
    	}
1699
    }
1703
    }
1700
1704
1701
    if ($note) {
1705
    if ($note) {
(-)a/installer/data/mysql/sysprefs.sql (+1 lines)
Lines 387-389 INSERT INTO systempreferences (variable,value,explanation,type) VALUES('INTRAdid Link Here
387
INSERT INTO systempreferences (variable, value, options, explanation, type) VALUES ('BlockReturnOfWithdrawnItems', '1', '0', 'If enabled, items that are marked as withdrawn cannot be returned.', 'YesNo');
387
INSERT INTO systempreferences (variable, value, options, explanation, type) VALUES ('BlockReturnOfWithdrawnItems', '1', '0', 'If enabled, items that are marked as withdrawn cannot be returned.', 'YesNo');
388
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('HoldsToPullStartDate','2','Set the default start date for the Holds to pull list to this many days ago',NULL,'Integer');
388
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('HoldsToPullStartDate','2','Set the default start date for the Holds to pull list to this many days ago',NULL,'Integer');
389
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('alphabet','A B C D E F G H I J K L M N O P Q R S T U V W X Y Z','Alphabet than can be expanded into browse links, e.g. on Home > Patrons',NULL,'free');
389
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('alphabet','A B C D E F G H I J K L M N O P Q R S T U V W X Y Z','Alphabet than can be expanded into browse links, e.g. on Home > Patrons',NULL,'free');
390
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('NotesBlacklist','','List of notes fields that should not appear in the title notes/description separator of details',NULL,'free';
(-)a/installer/data/mysql/updatedatabase.pl (+7 lines)
Lines 6083-6088 if ( C4::Context->preference("Version") < TransformToNum($DBversion) ) { Link Here
6083
    SetVersion($DBversion);
6083
    SetVersion($DBversion);
6084
}
6084
}
6085
6085
6086
$DBversion = "XXX";
6087
if ( C4::Context->preference("Version") < TransformToNum($DBversion) ) {
6088
    $dbh->do("INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('NotesBlacklist','','List of notes fields that should not appear in the title notes/description separator of details',NULL,'free')");
6089
    print "Upgrade to $DBversion done (Bug 9162 - Add a system preference to set which notes fields appears on title notes/description separator)\n";
6090
    SetVersion($DBversion);
6091
}
6092
6086
=head1 FUNCTIONS
6093
=head1 FUNCTIONS
6087
6094
6088
=head2 TableExists($table)
6095
=head2 TableExists($table)
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/cataloguing.pref (-2 / +5 lines)
Lines 156-159 Cataloging: Link Here
156
            - pref: OpacSuppressionByIPRange
156
            - pref: OpacSuppressionByIPRange
157
              class: short
157
              class: short
158
            - (Leave blank if not used. Define a range like <code>192.168.</code>.)
158
            - (Leave blank if not used. Define a range like <code>192.168.</code>.)
159
159
	-
160
            - Don't show these
161
            - pref: NotesBlacklist
162
              class: multi
163
            - note fields in title notes separator (OPAC record details) and in the description separator (Staff client record details). The fields should appear separated with commas and according with the Koha MARC format (eg 3.. for UNIMARC, 5.. for MARC21)
160
- 

Return to bug 9162