Bug 21554

Summary: Using Subscription Batch Edit produces Software Error
Product: Koha Reporter: Kelly McElligott <kelly>
Component: SerialsAssignee: Jonathan Druart <jonathan.druart>
Status: CLOSED FIXED QA Contact: Julian Maurice <julian.maurice>
Severity: major    
Priority: P5 - low CC: andrewfh, colin.campbell, fridolin.somers, jonathan.druart, julian.maurice, katrin.fischer, martin.renvoize, nick
Version: Main   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Bug Depends on: 18426    
Bug Blocks:    
Attachments: Bug 21554: Add missing use statement in subscription-batchedit
Bug 21554: Add missing use statement in subscription-batchedit
Bug 21554: Add missing use statement in subscription-batchedit

Description Kelly McElligott 2018-10-11 23:20:18 UTC
Using the Subscription Batch Edit produces the software error of this:
Undefined subroutine % C4::Serials::can_edit_subscription called at /subscription-batchedit.pl line 72. 

This is missing C4::Serials from the code.
Comment 1 Katrin Fischer 2018-10-12 05:31:20 UTC
I just tested on master - it works for me without error, but we had this happen a few times now. Working for some, not for others.
Comment 2 Katrin Fischer 2018-10-12 05:35:21 UTC
On master and 18.05 the line is:
        next unless C4::Serials::can_edit_subscription( $subscription->unblessed ); # This should be moved to Koha::Subscription->can_edit

It looks like it should work?
Comment 3 Jonathan Druart 2018-10-12 14:27:04 UTC
Kelly, can you give the exact version of Koha you are using?
As well, could you confirm plack is enabled on this installation?
Comment 4 Jonathan Druart 2018-10-12 14:27:48 UTC
Created attachment 80512 [details] [review]
Bug 21554: Add missing use statement in subscription-batchedit
Comment 5 Kelly McElligott 2018-10-12 14:31:14 UTC
Jonathan,
We are not running plack and it was Koha version 18.05.02
Comment 6 Mark Tompsett 2018-10-15 15:08:09 UTC
Created attachment 80607 [details] [review]
Bug 21554: Add missing use statement in subscription-batchedit

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Comment 7 Julian Maurice 2018-10-18 14:00:21 UTC
Created attachment 80848 [details] [review]
Bug 21554: Add missing use statement in subscription-batchedit

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Comment 8 Nick Clemens 2018-10-19 17:40:41 UTC
Awesome work all!

Pushed to master for 18.11
Comment 9 Martin Renvoize 2018-11-05 14:43:47 UTC
Pushed to 18.05.x for 18.05.06
Comment 10 Fridolin Somers 2018-11-26 08:26:29 UTC
Depends on Bug 18426 not in 17.11.x