Bug 6479 Converts all the serialseq variables to UTF-8.

Corrects a problem when an UTF-8 character is used in the serial
numbering formula. The encoding became incorrect when concatenating the
number in the subscriptionhistory table.

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
To reproduce:
- Create subscription with numbering pattern N° {X}
- Receive 2 or more issues
- Check subscription summary page and manual history fields on the edit screen

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
This commit is contained in:
Frédérick Capovilla 2011-06-07 14:03:08 -04:00 committed by Chris Cormack
parent da7bcbd4e6
commit acc684bc01
1 changed files with 5 additions and 0 deletions

View File

@ -197,6 +197,11 @@ $template->param( subscriptions => \@subscriptionloop );
if ( $op and $op eq 'serialchangestatus' ) {
# Convert serialseqs to UTF-8 to prevent encoding problems
foreach my $seq (@serialseqs) {
utf8::decode($seq) unless utf8::is_utf8($seq);
}
my $newserial;
for ( my $i = 0 ; $i <= $#serialids ; $i++ ) {
my ($plan_date, $pub_date);