From 53d5b23b8120687089f3426b82a3796d02a7b1ab Mon Sep 17 00:00:00 2001
From: Victor Grousset <victor.grousset@biblibre.com>
Date: Thu, 22 Mar 2018 15:44:00 +0100
Subject: [PATCH] Bug 20461 : Serials: fix ignored params in subscription
 creation form
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

In subscription-add.pl, the two params aren't passed to
NewSubscription() but they are to ModSubscription()

== Test plan ==
1. Enable syspref "makePreviousSerialAvailable"
2. Create a minimal subscription with a value in the "Item type" and
     "item type for older issues" fields.
3. Edit the subscription
4. You should see that the two fields are empty. This is the bug.
5. Apply this patch
6. Do step 2 and 3
7. You should see that the two fields have the right value
8. Express the joy of a successful and easy sign off.
   (this is important, otherwise the sign off spell won't work!)

Signed-off-by: delaye <stephane.delaye@biblibre.com>
Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr>
---
 serials/subscription-add.pl | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/serials/subscription-add.pl b/serials/subscription-add.pl
index 85ebd62..bb9e8cf 100755
--- a/serials/subscription-add.pl
+++ b/serials/subscription-add.pl
@@ -343,7 +343,7 @@ sub redirect_add_subscription {
         join(";",@irregularity), $numberpattern, $locale, $callnumber,
         $manualhistory, $internalnotes, $serialsadditems,
         $staffdisplaycount, $opacdisplaycount, $graceperiod, $location, $enddate,
-        $skip_serialseq
+        $skip_serialseq, $itemtype, $previousitemtype
     );
 
     my $additional_fields = Koha::AdditionalField->all( { tablename => 'subscription' } );
-- 
2.1.4