Events

Event Codes

Event Code
Description
init
When the Reserve In-store system is ready.
reserve_modal.create
When the new reservation modal is created.
reserve_modal.show
When the new reservation modal is shown.
reserve_modal.hide
When the new reservation modal is hidden.
reserve_modal.submit
When a customer/shopper submits a new reservation request through the modal.
choose_location_modal.create
When the choose preferred location modal is created.
choose_location_modal.show
When the choose preferred location modal is shown.
choose_location_modal.hide
When the choose preferred location modal is hidden.
variant.change
When the currently being considered variant is changed (IE shopper switches sizes, colors, etc).
product.change
When the currently being viewed/considered product is changed.
location.change
When the preferred location of the shopper is changed, either because the shopper changed it from the choose locations modal or the system detected a location change locally another way.
stock_status.change
When the stock status indicator changes, generally because a location or variant has changed on the page.

Example Usage

This code will trigger the function when the reserve modal is submitted:
1
// using the "push" method because we're not sure if RIS has loaded yet.
2
window.ris = window.ris || [];
3
window.ris.push('on', {
4
event: 'reserve_modal.submit',
5
callback: function() {
6
alert("New reservation created!");
7
}
8
});
Copied!
Last modified 2yr ago
Copy link