Lines 240-246
sub AddItemFromMarc {
Link Here
|
240 |
|
240 |
|
241 |
my $localitemmarc=MARC::Record->new; |
241 |
my $localitemmarc=MARC::Record->new; |
242 |
$localitemmarc->append_fields($source_item_marc->field($itemtag)); |
242 |
$localitemmarc->append_fields($source_item_marc->field($itemtag)); |
243 |
my $item = &TransformMarcToKoha( $localitemmarc, $frameworkcode ,'items'); |
243 |
my $item = C4::Biblio::TransformMarcToKoha( $localitemmarc, $frameworkcode ,'items'); |
244 |
my $unlinked_item_subfields = _get_unlinked_item_subfields($localitemmarc, $frameworkcode); |
244 |
my $unlinked_item_subfields = _get_unlinked_item_subfields($localitemmarc, $frameworkcode); |
245 |
return AddItem($item, $biblionumber, $dbh, $frameworkcode, $unlinked_item_subfields); |
245 |
return AddItem($item, $biblionumber, $dbh, $frameworkcode, $unlinked_item_subfields); |
246 |
} |
246 |
} |
Lines 299-305
sub AddItem {
Link Here
|
299 |
|
299 |
|
300 |
$item->{'itemnumber'} = $itemnumber; |
300 |
$item->{'itemnumber'} = $itemnumber; |
301 |
|
301 |
|
302 |
ModZebra( $item->{biblionumber}, "specialUpdate", "biblioserver" ); |
302 |
C4::Biblio::ModZebra( $item->{biblionumber}, "specialUpdate", "biblioserver" ); |
303 |
|
303 |
|
304 |
logaction( "CATALOGUING", "ADD", $itemnumber, "item" ) |
304 |
logaction( "CATALOGUING", "ADD", $itemnumber, "item" ) |
305 |
if C4::Context->preference("CataloguingLog"); |
305 |
if C4::Context->preference("CataloguingLog"); |
Lines 2190-2196
sub _get_unlinked_item_subfields {
Link Here
|
2190 |
my $original_item_marc = shift; |
2190 |
my $original_item_marc = shift; |
2191 |
my $frameworkcode = shift; |
2191 |
my $frameworkcode = shift; |
2192 |
|
2192 |
|
2193 |
my $marcstructure = GetMarcStructure(1, $frameworkcode, { unsafe => 1 }); |
2193 |
my $marcstructure = C4::Biblio::GetMarcStructure(1, $frameworkcode, { unsafe => 1 }); |
2194 |
|
2194 |
|
2195 |
# assume that this record has only one field, and that that |
2195 |
# assume that this record has only one field, and that that |
2196 |
# field contains only the item information |
2196 |
# field contains only the item information |