https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37707
--- Comment #45 from Martin Renvoize (ashimema) <[email protected]> --- Created attachment 192009 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=192009&action=edit Bug 37707: (follow-up) Refactor place_booking.js for maintainability Extract utility functions and reduce code duplication: - Add toInt(), startOfDay(), datesOverlap(), isDateInRange() helpers - Simplify containsAny() using Set and Array.some() - Refactor isItemAvailableForPeriod() to use new utilities - Refactor getAvailableItemsOnDate() and isDateDisabledForSpecificItem() - Extract submit handler helpers: getAvailableItemsForPeriod(), buildBookingPayload(), createTimelineItem(), showBookingError(), showBookingSuccess(), refreshBookingsTable(), setPickerDates() - Replace parseInt() calls with toInt() for consistency - Simplify modal reset handler with jQuery method chaining No functional changes - prepares codebase for future Vue conversion. -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list [email protected] https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
