https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41306
--- Comment #9 from Matt Blenkinsop <[email protected]> --- Created attachment 209293 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=209293&action=edit Bug 41306: Only offer months in the date picker for running a harvest Harvests run per calendar month: Bug 41294 splits any date range into one job per month, so the exact days asked by the "Run now" dialog were noise. The dialog now asks for a begin month and an end month, sends the first and the last day of those months, and only offers months up to the previous one, since the current month is not complete. The end picker starts at the begin month, through the data-date_to link of the staff date pickers, so a begin month after the end month cannot be picked. Typed input is off: the staff date mask does not accept a month name. The calendars are rendered next to their inputs, inside the modal: a calendar at the end of the body takes the focus out of the modal, and the Bootstrap focus trap then reopens the begin picker after a month is picked in the end picker. The body of the confirmation dialog no longer scrolls, so the calendar overlays the footer. The static calendar wraps its input: the dialog gives the wrapper the width the input had and the input fills it. A read-only picker input keeps the calendar icon instead of the lock of a locked field. The dialog was duplicated in the data providers list and the provider page. It now lives in the composable vue/composables/sushiHarvester.js, which both call; this also fixes the provider name that was undefined in the dialog of the provider page. FlatPickrWrapper gains an optional config prop, merged over the staff flatpickr defaults, so a caller can add a plugin or a bound without losing the defaults. Test plan: 1. On the data providers list, click "Run now": the dialog asks for a begin month and an end month. The inputs show the full month name with a calendar icon, and the end month is prefilled with the previous month 2. Open the begin picker: the current month and later are greyed out. The calendar overlays the dialog footer instead of scrolling the dialog 3. Typing in an input is not possible; a month can only be picked 4. Pick a begin month of last year, then open the end picker: the months before the begin month are greyed out, and a click in the end picker does not reopen the begin picker 5. Pick an end month and click "Yes, run": the message lists one job per report type and month, from the begin month to the end month 6. Open a provider page and click "Run now" there: the dialog names the provider and behaves the same 7. Open the job of the first month: the harvest period runs from the first to the last day of that month 8. yarn cypress run --spec t/cypress/integration/ERM/DataProviders_spec.ts Sponsored-by: Karlsruhe Institute of Technology (KIT) Assisted-by: Fable 5.1 (Anthropic) -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list -- [email protected] To unsubscribe send an email to [email protected] website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
