Bug 15496: Tidy code block (Whitespace changes only)
Signed-off-by: Liz Rea <wizzyrea@gmail.com> Signed-off-by: Josef Moravec <josef.moravec@gmail.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
This commit is contained in:
parent
2b45630e42
commit
428fcb3421
1 changed files with 27 additions and 21 deletions
|
@ -65,38 +65,44 @@ $template->param(bibliotitle => $biblio->title);
|
|||
$template->param(biblionumber => $biblionumber);
|
||||
|
||||
# If we already have the barcode of the item to move and the biblionumber to move the item to
|
||||
if ($barcode && $biblionumber) {
|
||||
if ( $barcode && $biblionumber ) {
|
||||
|
||||
my $itemnumber;
|
||||
my $item = Koha::Items->find({ barcode => $barcode });
|
||||
my $item = Koha::Items->find( { barcode => $barcode } );
|
||||
|
||||
if ($item) {
|
||||
|
||||
$itemnumber = $item->itemnumber;
|
||||
my $frombiblionumber = $item->biblionumber;
|
||||
|
||||
my $moveresult = MoveItemFromBiblio($itemnumber, $frombiblionumber, $biblionumber);
|
||||
if ($moveresult) {
|
||||
$template->param(success => 1);
|
||||
} else {
|
||||
$template->param(error => 1,
|
||||
errornonewitem => 1);
|
||||
}
|
||||
my $moveresult = MoveItemFromBiblio( $itemnumber, $frombiblionumber, $biblionumber );
|
||||
if ($moveresult) {
|
||||
$template->param( success => 1 );
|
||||
}
|
||||
else {
|
||||
$template->param(
|
||||
error => 1,
|
||||
errornonewitem => 1
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
} else {
|
||||
$template->param(error => 1,
|
||||
errornoitem => 1);
|
||||
}
|
||||
}
|
||||
else {
|
||||
$template->param(
|
||||
error => 1,
|
||||
errornoitem => 1
|
||||
);
|
||||
}
|
||||
$template->param(
|
||||
barcode => $barcode,
|
||||
itemnumber => $itemnumber,
|
||||
);
|
||||
barcode => $barcode,
|
||||
itemnumber => $itemnumber,
|
||||
);
|
||||
|
||||
} else {
|
||||
$template->param(missingparameter => 1);
|
||||
if (!$barcode) { $template->param(missingbarcode => 1); }
|
||||
if (!$biblionumber) { $template->param(missingbiblionumber => 1); }
|
||||
}
|
||||
else {
|
||||
$template->param( missingparameter => 1 );
|
||||
if ( !$barcode ) { $template->param( missingbarcode => 1 ); }
|
||||
if ( !$biblionumber ) { $template->param( missingbiblionumber => 1 ); }
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue