[Koha-bugs] [Bug 33901] Only one issue shown in Test prediction pattern
bugzilla-daemon at bugs.koha-community.org
bugzilla-daemon at bugs.koha-community.org
Thu Jun 8 22:40:53 CEST 2023
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33901
Katrin Fischer <katrin.fischer at bsz-bw.de> changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #152105|0 |1
is obsolete| |
--- Comment #6 from Katrin Fischer <katrin.fischer at bsz-bw.de> ---
Created attachment 152217
-->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=152217&action=edit
Bug 33901: (bug 30718 follow-up) Predition pattern - don't set end date to
today
If the end date is not set we should not set it to today.
On bug 30718 the following change was wrong:
-$enddate = eval { output_pref( { str => $enddate, dateonly => 1, dateformat =>
'iso' } ); };
+$enddate = dt_from_string($enddate)->ymd;
output_pref returns undef if str is empty
After the change we returned today's date.
Test plan:
1. Go to Serials > Manage numbering patterns
2. Click Edit next to one of the existing patterns (e.g. Number)
3. Enter information in the Test prediction pattern section
- Frequency: choose one (e.g. 1/month)
- First issue publication date: enter a date (e.g. 2023-06-01)
- Subscription length: issues + enter a number of issues (e.g. 12)
- Locale: leave empty
- Begins with: enter a number in the X column, e.g. 42
4. Click Test pattern
=> Without this patch only one issue is shown, no matter how many you enter in
Subscription length
=> With this patch applied the end date is not set to today and the
prediction pattern list is correct
Signed-off-by: Caroline Cyr La Rose <caroline.cyr-la-rose at inlibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83 at web.de>
--
You are receiving this mail because:
You are watching all bug changes.
More information about the Koha-bugs
mailing list