Bugzilla – Attachment 66674 Details for
Bug 19194
Internal server error when receiving an order with no itemtype
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 19194: Check itemtype is defined when receiving an order
Bug-19194-Check-itemtype-is-defined-when-receiving.patch (text/plain), 1.56 KB, created by
Lee Jamison
on 2017-08-31 16:07:13 UTC
(
hide
)
Description:
Bug 19194: Check itemtype is defined when receiving an order
Filename:
MIME Type:
Creator:
Lee Jamison
Created:
2017-08-31 16:07:13 UTC
Size:
1.56 KB
patch
obsolete
>From 1d2d4c8fdac6dae57dd12b022f640c38d2cf1ae5 Mon Sep 17 00:00:00 2001 >From: Aleisha Amohia <aleishaamohia@hotmail.com> >Date: Tue, 29 Aug 2017 04:51:40 +0000 >Subject: [PATCH] Bug 19194: Check itemtype is defined when receiving an order > >To test: >1) Find a record with an item that has no itemtype (or remove the >itemtype of an item) >2) Go to Acquisitions -> Find a vendor or make a new one -> create a new >basket >3) Add the record from Step 1 to your basket >4) Close the basket >5) Go back to the vendor and click 'Receive shipments' >6) Put in an invoice number, click Next >7) Click the Receive link for your item >8) Confirm you see an internal server error >9) Apply the patch and refresh the page >10) The error should be gone and behaviour should continue as expected > >Sponsored-by: Catalyst IT > >Signed-off-by: Lee Jamison <ldjamison@marywood.edu> >--- > acqui/orderreceive.pl | 4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) > >diff --git a/acqui/orderreceive.pl b/acqui/orderreceive.pl >index ee244d7..116277d 100755 >--- a/acqui/orderreceive.pl >+++ b/acqui/orderreceive.pl >@@ -147,7 +147,9 @@ if ($AcqCreateItem eq 'receiving') { > $item->{materials} = $descriptions->{lib} // ''; > > my $itemtype = Koha::ItemTypes->find( $item->{itype} ); >- $item->{itemtype} = $itemtype->description; # FIXME Should not it be translated_description? >+ if (defined $itemtype) { >+ $item->{itemtype} = $itemtype->description; # FIXME Should not it be translated_description? >+ } > push @items, $item; > } > $template->param(items => \@items); >-- >2.1.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 19194
:
66573
|
66674
|
66682