[Koha-bugs] [Bug 18064] Long overdue cronjob does not follow the library's calendar and skip closed days

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Fri Jun 17 00:24:21 CEST 2022


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18064

Michal Urban <michalurban177 at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
 Attachment #135888|0                           |1
        is obsolete|                            |

--- Comment #19 from Michal Urban <michalurban177 at gmail.com> ---
Created attachment 136214
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=136214&action=edit
Bug 18064: (follow-up) Get libraries as a list

Output: One line per library as expected, along with the date + 366 days
for libraries without set holidays, and start dates postponed by 366 days
+ the amount of days corresponding to library holidays.

Added random holidays to 3 different libraries, of different variety,
(Holiday Repeating Yearly, Unique Holiday, etc.) and ran longoverdue.pl,
getting the same start days, then ran with patch applied and returned
above result as expected.

Test plan :

1) For clearer vision on what the patch does, have at least "2" libraries
2) Go to Tools/Calendar and place holidays, on each of the libraries
 for example, of any kind (special, repeated, as you want)
3) Manually run the misc/cronjobs/longoverdue.pl script
 with the -v (verbose) argument to get as much information as possible
4) You will see a common "block", with today's date + 366 days
 (by default if you don't pass any arguments to the script),
holidays are not taken into account in this date range
5) Apply my patch
6) Launch the updatedatabase
7) Set the new system preference "LongOverdueNoticeCalendar" to "use calendar"
8) Repeat step 3
9) You will see in output one line per library and according to the
 number of days off in the interval of dates,
the start date of the analysis will have been postponed
 by as many days in order to take these holidays into account.

Signed-off-by: Michal Urban <michalurban177 at gmail.com>

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list