Symptoms: - closed invoices are displayed as "Open" on details page (acqui/invoice.pl), - it's not possible to reopen the closed invoice using "Edit" button. (see also bug 3050 comment #11)
Ouch; it's not an "Edit" button, should be "Save" button instead in comment #1..
Created attachment 28303 [details] [review] Bug 12274 - Closed invoices not properly handled on invoice details page Trivial fix for small regression (closed invoices are displayed as "Open" on details page, and it's not possible to reopen the closed invoice using "Save" button) introduced by bug 10613. Test plan: 1) Create and close some invoices 2) Note that closed invoices are erroneously displayed as "Open" on individual invoice[s] details page 3) Apply patch 4) Check previously closed invoices; their status on details page should now be properly displayed as "Closed on ..." (and an option for reopening would reappear as well) 5) Ensure that "Close" / "Reopen" checkboxes followed by "Save" button do work as expected for individual open / closed invoices respectivelly.
Created attachment 28351 [details] [review] Bug 12274 - Closed invoices not properly handled on invoice details page Trivial fix for small regression (closed invoices are displayed as "Open" on details page, and it's not possible to reopen the closed invoice using "Save" button) introduced by bug 10613. Test plan: 1) Create and close some invoices 2) Note that closed invoices are erroneously displayed as "Open" on individual invoice[s] details page 3) Apply patch 4) Check previously closed invoices; their status on details page should now be properly displayed as "Closed on ..." (and an option for reopening would reappear as well) 5) Ensure that "Close" / "Reopen" checkboxes followed by "Save" button do work as expected for individual open / closed invoices respectivelly. Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Created attachment 28352 [details] [review] Bug 12274: Invoice detail: billingdate is badly formated Bug 10613 sent the billingdate as a string. The template waits a DateTime object. To reproduce: 1/ Go on a invoice detail page 2/ Select a billing date 3/ Boom without the patch [Tue May 20 13:39:18 2014] invoice.pl: Template process failed: undef error - The 'day' parameter ("2014") to DateTime::new did not pass the 'an integer which is a possible valid day of month' callback. Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
And I found another bug introduced by bug 10613. This is critical for the release, I raise the severity.
Created attachment 28395 [details] [review] [PASSED QA] Bug 12274 - Closed invoices not properly handled on invoice details page Trivial fix for small regression (closed invoices are displayed as "Open" on details page, and it's not possible to reopen the closed invoice using "Save" button) introduced by bug 10613. Test plan: 1) Create and close some invoices 2) Note that closed invoices are erroneously displayed as "Open" on individual invoice[s] details page 3) Apply patch 4) Check previously closed invoices; their status on details page should now be properly displayed as "Closed on ..." (and an option for reopening would reappear as well) 5) Ensure that "Close" / "Reopen" checkboxes followed by "Save" button do work as expected for individual open / closed invoices respectivelly. Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> Works as described.
Created attachment 28396 [details] [review] [PASSED QA] Bug 12274: Invoice detail: billingdate is badly formated Bug 10613 sent the billingdate as a string. The template waits a DateTime object. To reproduce: 1/ Go on a invoice detail page 2/ Select a billing date 3/ Boom without the patch [Tue May 20 13:39:18 2014] invoice.pl: Template process failed: undef error - The 'day' parameter ("2014") to DateTime::new did not pass the 'an integer which is a possible valid day of month' callback. Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> Not all dates will make it go 'boom' but 31/07/2014 did.
Pushed to master. Thanks, Jacek and Jonathan!