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

(-)a/C4/Charset.pm (-4 / +7 lines)
Lines 324-331 sub SetMarcUnicodeFlag { Link Here
324
        substr($leader, 9, 1) = 'a';
324
        substr($leader, 9, 1) = 'a';
325
        $marc_record->leader($leader); 
325
        $marc_record->leader($leader); 
326
    } elsif ($marc_flavour =~/UNIMARC/) {
326
    } elsif ($marc_flavour =~/UNIMARC/) {
327
	my $defaultlanguage = C4::Context->preference("UNIMARCField100Language");
328
        $defaultlanguage = "fre" if (!$defaultlanguage || length($defaultlanguage) != 3);
327
        my $string; 
329
        my $string; 
328
		my ($subflength,$encodingposition)=($marc_flavour=~/AUTH/?(21,9):(36,22));
330
		my ($subflength,$encodingposition)=($marc_flavour=~/AUTH/?(21,12):(36,25));
329
		$string=$marc_record->subfield( 100, "a" );
331
		$string=$marc_record->subfield( 100, "a" );
330
        if (defined $string && length($string)==$subflength) { 
332
        if (defined $string && length($string)==$subflength) { 
331
			$string = substr $string, 0,$subflength if (length($string)>$subflength);
333
			$string = substr $string, 0,$subflength if (length($string)>$subflength);
Lines 333-341 sub SetMarcUnicodeFlag { Link Here
333
        else { 
335
        else { 
334
            $string = POSIX::strftime( "%Y%m%d", localtime ); 
336
            $string = POSIX::strftime( "%Y%m%d", localtime ); 
335
            $string =~ s/\-//g; 
337
            $string =~ s/\-//g; 
336
            $string = sprintf( "%-*s", $subflength, $string ); 
338
            $string = sprintf( "%-*s", $subflength, $string );
339
	    substr ( $string, ($encodingposition - 3), 3, $defaultlanguage);
337
        } 
340
        } 
338
        substr( $string, $encodingposition, 8, "frey50  " ); 
341
        substr( $string, $encodingposition, 3, "y50" );
339
        if ( $marc_record->subfield( 100, "a" ) ) { 
342
        if ( $marc_record->subfield( 100, "a" ) ) { 
340
			$marc_record->field('100')->update(a=>$string);
343
			$marc_record->field('100')->update(a=>$string);
341
		}
344
		}
Lines 343-349 sub SetMarcUnicodeFlag { Link Here
343
            $marc_record->insert_grouped_field( 
346
            $marc_record->insert_grouped_field( 
344
                MARC::Field->new( 100, '', '', "a" => $string ) ); 
347
                MARC::Field->new( 100, '', '', "a" => $string ) ); 
345
        }
348
        }
346
		$debug && warn "encodage: ", substr( $marc_record->subfield(100, 'a'), $encodingposition, 8 );
349
		$debug && warn "encodage: ", substr( $marc_record->subfield(100, 'a'), $encodingposition, 3 );
347
    } else {
350
    } else {
348
        warn "Unrecognized marcflavour: $marc_flavour";
351
        warn "Unrecognized marcflavour: $marc_flavour";
349
    }
352
    }
(-)a/installer/data/mysql/sysprefs.sql (-1 lines)
Lines 389-395 INSERT INTO systempreferences (variable,value,explanation,type) VALUES('INTRAdid Link Here
389
INSERT INTO systempreferences (variable, value, options, explanation, type) VALUES ('BlockReturnOfWithdrawnItems', '1', '0', 'If enabled, items that are marked as withdrawn cannot be returned.', 'YesNo');
389
INSERT INTO systempreferences (variable, value, options, explanation, type) VALUES ('BlockReturnOfWithdrawnItems', '1', '0', 'If enabled, items that are marked as withdrawn cannot be returned.', 'YesNo');
390
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');
390
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');
391
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');
391
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');
392
<<<<<<< HEAD
393
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('RefundLostItemFeeOnReturn', '1', 'If enabled, the lost item fee charged to a borrower will be refunded when the lost item is returned.', NULL, 'YesNo');
392
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('RefundLostItemFeeOnReturn', '1', 'If enabled, the lost item fee charged to a borrower will be refunded when the lost item is returned.', NULL, 'YesNo');
394
INSERT INTO systempreferences (`variable`, `value`, `options`, `explanation`, `type`) VALUES
393
INSERT INTO systempreferences (`variable`, `value`, `options`, `explanation`, `type`) VALUES
395
('PatronSelfRegistration', '0', NULL, 'If enabled, patrons will be able to register themselves via the OPAC.', 'YesNo'),
394
('PatronSelfRegistration', '0', NULL, 'If enabled, patrons will be able to register themselves via the OPAC.', 'YesNo'),
(-)a/installer/data/mysql/updatedatabase.pl (-2 lines)
Lines 1-4 Link Here
1
2
#!/usr/bin/perl
1
#!/usr/bin/perl
3
2
4
# Database Updater
3
# Database Updater
5
- 

Return to bug 8347