Bug 23829

Summary: Software error when checking in an item that has a fine
Product: Koha Reporter: ciarebaha <hamsiah>
Component: CirculationAssignee: Bugs List <koha-bugs>
Status: CLOSED FIXED QA Contact: Testopia <testopia>
Severity: major    
Priority: P5 - low CC: gmcharlt, jonathan.druart, kyle
Version: 18.11   
Hardware: Other   
OS: Other   
GIT URL: Initiative type: ---
Sponsorship status: --- Comma delimited list of Sponsors:
Crowdfunding goal: 0 Crowdfunding committed: 0
Crowdfunding contact: Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:
Attachments: Software error page during check in item that has fine
Grace period setting is "don't include"

Description ciarebaha 2019-10-17 02:38:10 UTC
Created attachment 94359 [details]
Software error page during check in item that has fine

Hello community,

A software error page is returned when trying to Check In an item that has fine (OVERDUE). The error is "Software error: The 'days' parameter (undef) to Datetime::Duration::new which was an 'undef' which is not one of the allowed type: scalar (Duration.pm line 28)". This error happened in koha version 18.11.
Comment 1 Jonathan Druart 2019-10-22 11:16:55 UTC
Do you have a default circulation rule?
What is the value of 'Fine grace period' (firstremind)?
Comment 2 ciarebaha 2019-10-23 01:38:20 UTC
Thank you Jonathan Druart, for your response.

Our organisation doesn't include grace period in our setting. The fine keep on increasing daily. Please refer attachment (latest) for our setting.


(In reply to Jonathan Druart from comment #1)
> Do you have a default circulation rule?
> What is the value of 'Fine grace period' (firstremind)?
Comment 3 ciarebaha 2019-10-23 01:39:24 UTC
Created attachment 94598 [details]
Grace period setting is "don't include"
Comment 4 Jonathan Druart 2019-10-23 13:26:28 UTC
Do you have a default circulation rule?

Go to "Home › Administration › Circulation and fine rules"

If you can connect to the server it would help to know what are the value of a couple of rules:
  SELECT firstremind, finedays from issuingrules;
Comment 5 ciarebaha 2019-10-25 08:56:38 UTC
This error is fixed. Even if we select "don't include" for fine grace period, we still have to set value grace period as zero @ '0' in circulation rule setting. If we leave it '' or blank, this kind of error will occur.

Thanks for giving me some sort if idea to make this things working fine.