Bug 37835

Summary: CurbSide pickup - Click on 'Add a new slot' button is not triggering any action
Product: Koha Reporter: Lucas <lucasmontoya>
Component: CirculationAssignee: Phil Ringnalda <phil>
Status: RESOLVED DUPLICATE QA Contact: Testopia <testopia>
Severity: major    
Priority: P3 CC: gmcharlt, jonathan.druart, kyle.m.hall, phil, tomascohen
Version: MainKeywords: regression
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:
Bug Depends on: 35838    
Bug Blocks:    
Attachments: Bug 37835: Saving new slot for curbside pickup fails after tab wrapper rewrite

Description Lucas 2024-09-04 18:54:18 UTC
To reproduce:

- Install CurbSide Pickup plugin (https://github.com/bywatersolutions/koha-plugin-curbside-pickup/releases) Version : koha-plugin-curbside-pickup-2.0.1.kpz

- Enable CurbSide Pickup module ( In Koha Administration look for CurbSide Pickup)

- Then in Koha Administration --> Patrons and Circulation should have appeared the CurbSide Pickup module

- Check 'Enable' for Centerville library

- Pick some random values for each field

- In particular, for new slot set valid values

- Click on 'Add' button 

- Note that nothing happens
Comment 1 Phil Ringnalda 2024-09-05 03:16:06 UTC
No need to install the plugin, since all it does anymore is provide a REST API - curbside is built in, and it fails without the plugin.
Comment 2 Phil Ringnalda 2024-09-05 03:27:15 UTC
Created attachment 171042 [details] [review]
Bug 37835: Saving new slot for curbside pickup fails after tab wrapper rewrite

When you add a new slot for curbside pickup, the JavaScript the Add button
triggers tries to look for something with the class "pickup_hours" inside
something with the id "conf-{branchname}", but the bug 35838 template wrapper
for the tabs changed that id to "conf-{branchname}_panel"

Test plan:
1. Administration - System preferences - set CurbsidePickup to Enable
2. Administration - Curbside pickup - for Centerville add a New slot
   Sunday From 10:00 to 10:20 and click Add
3. Nothing happens, the slot isn't listed above the form
4. Apply patch, reload the page
5. Repeat step 2, but this time the new slot will appear above the form

Sponsored-by: Chetco Community Public Library
Comment 3 Jonathan Druart 2024-09-05 07:37:42 UTC
I've attached a follow-up on bug 35838. I hope it will be pushed very soon.

*** This bug has been marked as a duplicate of bug 35838 ***