Bug 28963: Use Flatpickr on calendar page
authorOwen Leonard <oleonard@myacpl.org>
Mon, 4 Oct 2021 16:33:25 +0000 (16:33 +0000)
committerJonathan Druart <jonathan.druart@bugs.koha-community.org>
Tue, 12 Oct 2021 09:15:32 +0000 (11:15 +0200)
commit0111632f1e5edd4f7d23a1888e2e2e576d757c43
tree42de4194bce991b0a718430fd131271eee112490
parente81f6de26e6bd5dbd0f38041615929eb0a86f9e2
Bug 28963: Use Flatpickr on calendar page

This patch replaces the use of jQueryUI's datepicker widget on the
Calendar page.

In order to ease customization of the static calendar which shows the
current calendar, I've converted the calendar.css file to SCSS. This
allows us to define new SCSS variables to pass to the Flatpickr SCSS.

Also changed: Removed some unecessary comments in the template.

To test, apply the patch and rebuild the staff interface CSS
(https://wiki.koha-community.org/wiki/Working_with_SCSS_in_the_OPAC_and_staff_client).

- Go to Tools -> Calendar.
- Confirm that entering holidays works correctly for all types: Single,
  weekly, yearly, ranges, repeated ranges.
- Confirm that holidays are deleted as expected.
- Confirm that the colors of each type of holiday is correct.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
koha-tmpl/intranet-tmpl/prog/css/src/_flatpickr.scss
koha-tmpl/intranet-tmpl/prog/css/src/_flatpickr_vars.scss [new file with mode: 0644]
koha-tmpl/intranet-tmpl/prog/css/src/_vars.scss [deleted file]
koha-tmpl/intranet-tmpl/prog/css/src/calendar.scss [new file with mode: 0644]
koha-tmpl/intranet-tmpl/prog/en/modules/tools/holidays.tt