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

(-)a/C4/Items.pm (-6 / +6 lines)
Lines 222-231 sub AddItemFromMarc { Link Here
222
    # parse item hash from MARC
222
    # parse item hash from MARC
223
    my $frameworkcode = C4::Biblio::GetFrameworkCode( $biblionumber );
223
    my $frameworkcode = C4::Biblio::GetFrameworkCode( $biblionumber );
224
    my ($itemtag,$itemsubfield)=C4::Biblio::GetMarcFromKohaField("items.itemnumber",$frameworkcode);
224
    my ($itemtag,$itemsubfield)=C4::Biblio::GetMarcFromKohaField("items.itemnumber",$frameworkcode);
225
225
	
226
    my $localitemmarc=MARC::Record->new;
226
	my $localitemmarc=MARC::Record->new;
227
    $localitemmarc->append_fields($source_item_marc->field($itemtag));
227
	$localitemmarc->append_fields($source_item_marc->field($itemtag));
228
    my $item = TransformMarcToKoha( $localitemmarc, $frameworkcode ,'items');
228
    my $item = C4::Biblio::TransformMarcToKoha( $localitemmarc, $frameworkcode ,'items');
229
    my $unlinked_item_subfields = _get_unlinked_item_subfields($localitemmarc, $frameworkcode);
229
    my $unlinked_item_subfields = _get_unlinked_item_subfields($localitemmarc, $frameworkcode);
230
    return AddItem($item, $biblionumber, $dbh, $frameworkcode, $unlinked_item_subfields);
230
    return AddItem($item, $biblionumber, $dbh, $frameworkcode, $unlinked_item_subfields);
231
}
231
}
Lines 284-290 sub AddItem { Link Here
284
284
285
    $item->{'itemnumber'} = $itemnumber;
285
    $item->{'itemnumber'} = $itemnumber;
286
286
287
    ModZebra( $item->{biblionumber}, "specialUpdate", "biblioserver" );
287
    C4::Biblio::ModZebra( $item->{biblionumber}, "specialUpdate", "biblioserver" );
288
288
289
    logaction( "CATALOGUING", "ADD", $itemnumber, "item" )
289
    logaction( "CATALOGUING", "ADD", $itemnumber, "item" )
290
      if C4::Context->preference("CataloguingLog");
290
      if C4::Context->preference("CataloguingLog");
Lines 2032-2038 sub _get_unlinked_item_subfields { Link Here
2032
    my $original_item_marc = shift;
2032
    my $original_item_marc = shift;
2033
    my $frameworkcode = shift;
2033
    my $frameworkcode = shift;
2034
2034
2035
    my $marcstructure = GetMarcStructure(1, $frameworkcode, { unsafe => 1 });
2035
    my $marcstructure = C4::Biblio::GetMarcStructure(1, $frameworkcode, { unsafe => 1 });
2036
2036
2037
    # assume that this record has only one field, and that that
2037
    # assume that this record has only one field, and that that
2038
    # field contains only the item information
2038
    # field contains only the item information
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-reserve.tt (-1 lines)
Lines 225-231 Link Here
225
                                                        </li>
225
                                                        </li>
226
                                                    [% END %]
226
                                                    [% END %]
227
227
228
229
                                                    [% UNLESS ( singleBranchMode ) %]
228
                                                    [% UNLESS ( singleBranchMode ) %]
230
                                                        [% IF ( bibitemloo.holdable && Koha.Preference('OPACAllowUserToChooseBranch')) %]
229
                                                        [% IF ( bibitemloo.holdable && Koha.Preference('OPACAllowUserToChooseBranch')) %]
231
                                                            <li class="branch">
230
                                                            <li class="branch">
(-)a/opac/opac-reserve.pl (-2 / +7 lines)
Lines 173-178 foreach my $biblioNumber (@biblionumbers) { Link Here
173
173
174
    # Compute the priority rank.
174
    # Compute the priority rank.
175
    my $biblio = Koha::Biblios->find( $biblioNumber );
175
    my $biblio = Koha::Biblios->find( $biblioNumber );
176
    $biblioData->{object} = $biblio;
176
    my $holds = $biblio->holds;
177
    my $holds = $biblio->holds;
177
    my $rank = $holds->count;
178
    my $rank = $holds->count;
178
    $biblioData->{reservecount} = 1;    # new reserve
179
    $biblioData->{reservecount} = 1;    # new reserve
Lines 390-396 $template->param('item_level_itypes' => $itemLevelTypes); Link Here
390
391
391
foreach my $biblioNum (@biblionumbers) {
392
foreach my $biblioNum (@biblionumbers) {
392
393
393
    my @not_available_at = ();
394
    my $record = GetMarcBiblio({ biblionumber => $biblioNum });
394
    my $record = GetMarcBiblio({ biblionumber => $biblioNum });
395
    # Init the bib item with the choices for branch pickup
395
    # Init the bib item with the choices for branch pickup
396
    my %biblioLoopIter;
396
    my %biblioLoopIter;
Lines 402-407 foreach my $biblioNum (@biblionumbers) { Link Here
402
        &get_out($query, $cookie, $template->output);
402
        &get_out($query, $cookie, $template->output);
403
    }
403
    }
404
404
405
    my @not_available_at = ();
406
    my $biblio = $biblioData->{object};
407
    foreach my $library ( $pickup_locations->as_list ) {
408
        push( @not_available_at, $library->branchcode ) unless $biblio->can_be_transferred({ to => $library });
409
    }
410
405
    my $frameworkcode = GetFrameworkCode( $biblioData->{biblionumber} );
411
    my $frameworkcode = GetFrameworkCode( $biblioData->{biblionumber} );
406
    $biblioLoopIter{biblionumber} = $biblioData->{biblionumber};
412
    $biblioLoopIter{biblionumber} = $biblioData->{biblionumber};
407
    $biblioLoopIter{title} = $biblioData->{title};
413
    $biblioLoopIter{title} = $biblioData->{title};
408
- 

Return to bug 7614