Bug 23826

Summary: Manual Invoice does not use new accounttype and status for fines
Product: Koha Reporter: Andrew Fuerste-Henry <andrewfh>
Component: Fines and feesAssignee: Martin Renvoize <martin.renvoize>
Status: CLOSED FIXED QA Contact: Josef Moravec <josef.moravec>
Severity: blocker    
Priority: P5 - low CC: bwsdonna, fridolin.somers, josef.moravec, kelly
Version: Main   
Hardware: All   
OS: All   
See Also: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22563
Change sponsored?: --- Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
19.11.00,19.05.05
Bug Depends on: 22521    
Bug Blocks:    
Attachments: Bug 23826: Correction for missing "F" -> "OVERDUE" change
Bug 23826: Correction for missing "F" -> "OVERDUE" change
Bug 23826: Correction for missing "F" -> "OVERDUE" change

Description Andrew Fuerste-Henry 2019-10-16 14:19:15 UTC
Bug 22521 changes the accounttype values for fines and adds a new status field. maninvoice.pl does not use these new values.

To test:
- find a patron and create a manual invoice of type "Fine"
- look at the database to see that manual fine is accounttype=F and status=NULL

That should be accounttype=OVERDUE. I'm not sure what status should be. NULL? RETURNED?  Prior to 19.05, a manually created fine is indistinguishable from a normal fine.
Comment 1 Martin Renvoize 2019-10-16 15:05:26 UTC
OK, so this is a case I wasn't expecting at all :(.

I'll have a quick ponder as to the best solution as I'm currently working towards the unification and clarification of these manual invoice types in bug 23049 and will need to account for this use case there as well as building something for working with here separately.
Comment 2 Martin Renvoize 2019-10-16 15:16:27 UTC Comment hidden (obsolete)
Comment 3 Martin Renvoize 2019-10-16 15:23:22 UTC
Created attachment 94306 [details] [review]
Bug 23826: Correction for missing "F" -> "OVERDUE" change

When replacing F and FU with 'OVERDUE' + status in bug 22521 I missed
the cases inside the maninvoice template. This patch should correct
that mistake.
Comment 4 ByWater Sandboxes 2019-10-16 15:31:16 UTC
Created attachment 94322 [details] [review]
Bug 23826: Correction for missing "F" -> "OVERDUE" change

When replacing F and FU with 'OVERDUE' + status in bug 22521 I missed
the cases inside the maninvoice template. This patch should correct
that mistake.

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
Comment 5 Andrew Fuerste-Henry 2019-10-16 15:32:44 UTC
- created Manual Invoice of type Fine
- ran report to see that accountlines entry
- confirmed it is accounttype=OVERDUE, status=NULL

Thanks again, Martin!
Comment 6 Josef Moravec 2019-10-16 19:54:59 UTC
Created attachment 94355 [details] [review]
Bug 23826: Correction for missing "F" -> "OVERDUE" change

When replacing F and FU with 'OVERDUE' + status in bug 22521 I missed
the cases inside the maninvoice template. This patch should correct
that mistake.

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Comment 7 Martin Renvoize 2019-10-17 13:54:54 UTC
Nice work!

Pushed to master for 19.11.00
Comment 8 Fridolin Somers 2019-11-08 15:09:37 UTC
Conflict on 19.05.x because there is :
<option value="L">Lost item</option>
instead of 
<option value="LOST">Lost item</option>

Looks like its from Bug 22563 not in 19.05.x :
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=91345

Pushed to 19.05.x for 19.05.05