Bugzilla – Attachment 55330 Details for
Bug 6852
Staged import reports wrong success for items with false branchcode
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 6852: Preliminary test
Bug-6852-Preliminary-test.patch (text/plain), 1.69 KB, created by
Marcel de Rooy
on 2016-09-08 10:09:12 UTC
(
hide
)
Description:
Bug 6852: Preliminary test
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2016-09-08 10:09:12 UTC
Size:
1.69 KB
patch
obsolete
>From 38f644bb1f8bf820f36b1479cd74bf9a537e6e9c Mon Sep 17 00:00:00 2001 >From: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Date: Thu, 8 Sep 2016 12:06:05 +0200 >Subject: [PATCH] Bug 6852: Preliminary test >Content-Type: text/plain; charset=utf-8 > >--- > C4/ImportBatch.pm | 14 ++++++++------ > C4/Items.pm | 3 +++ > 2 files changed, 11 insertions(+), 6 deletions(-) > >diff --git a/C4/ImportBatch.pm b/C4/ImportBatch.pm >index 046b859..2ecd96b 100644 >--- a/C4/ImportBatch.pm >+++ b/C4/ImportBatch.pm >@@ -792,12 +792,14 @@ sub BatchCommitItems { > $num_items_errored++; > } else { > my ( $item_biblionumber, $biblioitemnumber, $itemnumber ) = AddItemFromMarc( $item_marc, $biblionumber ); >- $updsth->bind_param( 1, 'imported' ); >- $updsth->bind_param( 2, $itemnumber ); >- $updsth->bind_param( 3, $row->{'import_items_id'} ); >- $updsth->execute(); >- $updsth->finish(); >- $num_items_added++; >+ if( $itemnumber ) { >+ $updsth->bind_param( 1, 'imported' ); >+ $updsth->bind_param( 2, $itemnumber ); >+ $updsth->bind_param( 3, $row->{'import_items_id'} ); >+ $updsth->execute(); >+ $updsth->finish(); >+ $num_items_added++; >+ } > } > } > >diff --git a/C4/Items.pm b/C4/Items.pm >index 2f31897..d379989 100644 >--- a/C4/Items.pm >+++ b/C4/Items.pm >@@ -309,6 +309,9 @@ sub AddItem { > } > > my ( $itemnumber, $error ) = _koha_new_item( $item, $item->{barcode} ); >+ if( $error ) { >+ return; >+ } > $item->{'itemnumber'} = $itemnumber; > > ModZebra( $item->{biblionumber}, "specialUpdate", "biblioserver" ); >-- >1.7.10.4
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 6852
:
5333
|
5334
|
55330
|
55331
|
55359
|
55477