@@ -, +, @@ ignore defaults default framework. framework' is *not* checked the default values you assigned them in the default MARC framework --- .../prog/en/modules/tools/batchMod.tt | 14 ++++++++++++++ tools/batchMod.pl | 7 +++---- 2 files changed, 17 insertions(+), 4 deletions(-) --- a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/batchMod.tt +++ a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/batchMod.tt @@ -43,11 +43,25 @@ + +
+ Use default values +
    +
  1. + +
  2. +
+
+ [% IF ( del ) %][% END %]
Cancel
+ --- a/tools/batchMod.pl +++ a/tools/batchMod.pl @@ -47,7 +47,7 @@ my $del_records = $input->param('del_records'); my $completedJobID = $input->param('completedJobID'); my $runinbackground = $input->param('runinbackground'); my $src = $input->param('src'); - +my $use_default_values = $input->param('use_default_values'); my $template_name; my $template_flag; @@ -78,8 +78,7 @@ my $itemrecord; my $nextop=""; my @errors; # store errors found while checking data BEFORE saving item. my $items_display_hashref; -my $frameworkcode=""; -my $tagslib = &GetMarcStructure(1,$frameworkcode); +my $tagslib = &GetMarcStructure(1); my $deleted_items = 0; # Number of deleted items my $deleted_records = 0; # Number of deleted records ( with no items attached ) @@ -309,7 +308,7 @@ foreach my $tag (sort keys %{$tagslib}) { $subfield_data{repeatable} = $tagslib->{$tag}->{$subfield}->{repeatable}; my ($x,$value); $value =~ s/"/"/g; - unless ($value) { + if ( !$value && $use_default_values) { $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! --