From 734f9f5ab3c8fec2b9ea176cfc7a21edab785695 Mon Sep 17 00:00:00 2001 From: Henri-Damien LAURENT Date: Sun, 13 Dec 2009 14:55:30 +0100 Subject: [PATCH] Bug 3824: Item modif doesn't select default value in combo list --- cataloguing/additem.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cataloguing/additem.pl b/cataloguing/additem.pl index 30dba855b5..e4c30e34a9 100755 --- a/cataloguing/additem.pl +++ b/cataloguing/additem.pl @@ -283,7 +283,7 @@ foreach my $tag (sort keys %{$tagslib}) { my ($x,$value); ($x,$value) = find_value($tag,$subfield,$itemrecord) if ($itemrecord); $value =~ s/"/"/g; - unless ($value) { + if ( ! defined( $value ) || $value eq '') { $value = $tagslib->{$tag}->{$subfield}->{defaultvalue}; # get today date & replace YYYY, MM, DD if provided in the default value my ( $year, $month, $day ) = split ',', $today_iso; # FIXME: iso dates don't have commas! -- 2.39.5