Lines 81-86
sub generate_subfield_form {
Link Here
|
81 |
my $restricted_edition = $params->{restricted_editition}; |
81 |
my $restricted_edition = $params->{restricted_editition}; |
82 |
my $prefill_with_default_values = $params->{prefill_with_default_values}; |
82 |
my $prefill_with_default_values = $params->{prefill_with_default_values}; |
83 |
my $branch_limit = $params->{branch_limit}; |
83 |
my $branch_limit = $params->{branch_limit}; |
|
|
84 |
my $default_branches_empty = $params->{default_branches_empty}; |
84 |
|
85 |
|
85 |
my $item = $self->{item}; |
86 |
my $item = $self->{item}; |
86 |
my $subfield = $tagslib->{$tag}{$subfieldtag}; |
87 |
my $subfield = $tagslib->{$tag}{$subfieldtag}; |
Lines 190-195
sub generate_subfield_form {
Link Here
|
190 |
} |
191 |
} |
191 |
} |
192 |
} |
192 |
elsif ( $subfield->{authorised_value} eq "branches" ) { |
193 |
elsif ( $subfield->{authorised_value} eq "branches" ) { |
|
|
194 |
push @authorised_values, "" if $default_branches_empty; |
193 |
foreach my $thisbranch (@$libraries) { |
195 |
foreach my $thisbranch (@$libraries) { |
194 |
push @authorised_values, $thisbranch->{branchcode}; |
196 |
push @authorised_values, $thisbranch->{branchcode}; |
195 |
$authorised_lib{ $thisbranch->{branchcode} } = |
197 |
$authorised_lib{ $thisbranch->{branchcode} } = |
Lines 471-476
sub edit_form {
Link Here
|
471 |
my $subfields_to_ignore= $params->{subfields_to_ignore} || []; |
473 |
my $subfields_to_ignore= $params->{subfields_to_ignore} || []; |
472 |
my $prefill_with_default_values = $params->{prefill_with_default_values}; |
474 |
my $prefill_with_default_values = $params->{prefill_with_default_values}; |
473 |
my $branch_limit = $params->{branch_limit}; |
475 |
my $branch_limit = $params->{branch_limit}; |
|
|
476 |
my $default_branches_empty = $params->{default_branches_empty}; |
474 |
|
477 |
|
475 |
my $libraries = |
478 |
my $libraries = |
476 |
Koha::Libraries->search( {}, { order_by => ['branchname'] } )->unblessed; |
479 |
Koha::Libraries->search( {}, { order_by => ['branchname'] } )->unblessed; |
Lines 542-547
sub edit_form {
Link Here
|
542 |
restricted_edition => $restricted_edition, |
545 |
restricted_edition => $restricted_edition, |
543 |
prefill_with_default_values => $prefill_with_default_values, |
546 |
prefill_with_default_values => $prefill_with_default_values, |
544 |
branch_limit => $branch_limit, |
547 |
branch_limit => $branch_limit, |
|
|
548 |
default_branches_empty => $default_branches_empty, |
545 |
} |
549 |
} |
546 |
); |
550 |
); |
547 |
push @subfields, $subfield_data; |
551 |
push @subfields, $subfield_data; |