@W-18811979 BOPIS (buy online pick up in store)#2646
Merged
patricksullivansf merged 157 commits intodevelopfrom Jul 1, 2025
Merged
@W-18811979 BOPIS (buy online pick up in store)#2646patricksullivansf merged 157 commits intodevelopfrom
patricksullivansf merged 157 commits intodevelopfrom
Conversation
…angesForPickupInStore Signed-off-by: snilakandan13 <119348013+snilakandan13@users.noreply.github.com>
…tps://github.com/SalesforceCommerceCloud/pwa-kit into t/commerce/W-18669904/pdpChangesForPickupInStore
…ch page for products
alexvuong
reviewed
Jun 27, 2025
packages/template-retail-react-app/app/contexts/store-locator-provider.jsx
Outdated
Show resolved
Hide resolved
alexvuong
reviewed
Jun 27, 2025
packages/template-retail-react-app/app/hooks/use-selected-store.js
Outdated
Show resolved
Hide resolved
…902403/fixPDPRadioBehavior @W-18902403 - Select Off of Pickup in Store Option on PDP if New Store is Out of Stock
* W-18779257 bopis review rename selectedStore * W-18779257 bopis review rename pickup methods * W-18779257 bopis review minor comments addressed * W-18779257 bopis review store locator i18n
…902413/fixErrorMessageForAddToCartWithNoVariantSelected @W-18902413 - Fixed Incorrect Add to Cart Error
Implement feature toggle for BOPIS in PWA Kit
Contributor
Author
it's gated by |
Contributor
Author
if the extensions are not installed we expect |
* @W-18942954 BOPIS revert unneeded swatch change * @W-18942954 BOPIS revert unneeded add to cart test change * @W-18942954 BOPIS constant for radio labels
kzheng-sfdc
approved these changes
Jul 1, 2025
Alex is on PTO today and it's been expressed we want to move this forward without waiting
bfeister
approved these changes
Jul 1, 2025
Contributor
bfeister
left a comment
There was a problem hiding this comment.
let's get this merged 🚢
| { | ||
| "path": "build/main.js", | ||
| "maxSize": "57 kB" | ||
| "maxSize": "60 kB" |
Contributor
Author
There was a problem hiding this comment.
this keeps growing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Implements Buy Online Pick up In Store (BOPIS) also known as "Shop the Store for Composable Storefront".
The Store Locator is enhanced
to accept location data from Search Engine deep links, and the shopper can use the Store Locator to select a store. After a store is selected the shopper can browse that store's inventory on the PLP and PDP. While the cart is empty the shopper can choose between "Deliver to Address" and "Pick up in Store" when addingto the cart on the PDP. The cart, checkout, and order confirmation pages are updated to support the Pick-up In Store flow.
The principal changes for the implementation are:
We assume these SFRA BOPIS system-objecttype-extensions.xml are in place.
We are using the
STORE_LOCATOR_IS_ENABLEDfeature toggle to enable/disable the BOPIS feature.We will enable SE discovery of the BOPIS experience by seeding the SE with deep links to explicit Store Locator page URLs. Example:site.com/store-locator?city=New York&country=USThis includes support for location-based URL parameters such as latitude, longitude, city, zip, country, and store, enabling deep-linking and automatic pre-selection of stores when users arrive via search engines or shared links (e.g., “Shoes near me” or “Store X near me”). Once selected, the store is persisted in localStorage and visually highlighted in the Store Locator UI. Store selection parameters are then removed from the URL post-selection to maintain clean shareable links.
We will leverage the cached nature of
useCurrentBasket#totalItemsto determine if the cart is empty so we can disable store selection appropriately across the PWA Kit. Worth noting this implies adding it as a new dependency to some components like the Store Locator.We will conditionally add the refine
ilids=<selected store inventory ID>to the product-search API made from the PLP; this refinement filters out results that are not in the store’s stock. However, we will not add this to the PLP URL, because we want the search constrained by the shopper’s store preference when sharing URLs, and because the UX should display store names not inventory IDs. This special handling of refinements will be net new code.We will add the
inventoryIds=<selected store inventory ID>to the products API made from the PDP; this adds the in store inventory to the response so we can show both the global and selected store inventory simultaneously.We will conditionally add the
inventoryId=<selected store inventory ID>to the PDPaddItemToNewOrExistingBaskethandler so the correct inventory for this item is referenced during the rest of the order process.We will also conditionally add an additional step to the PDP
addItemToNewOrExistingBaskethandler to conditionally set the shipping method to “Pick Up in Store” and the shipping address to the selected store’s shipping address. We will use the existing sandboxc_storePickupEnabled: truecustom field to identify the correct shipping method ID to use; however, the initial setup for this Shipping method needs further investigation. Finally, we set thec_fromStoreId: <store ID>in the shipping section.For Cart, Checkout and Order pages we will use the existing sandbox
c_storePickupEnabled: trueand custom shipping method field andc_fromStoreIdcustom shipping field to identify when BOPIS is enabled for a cart and update the UX options to: show the delivery address as the pick up in store address and to disable alternate shipping method selection.Types of Changes
Changes
How to Test-Drive This PR
A BOPIS test environment for this PR is cc-sparks-patrick
Checklists
General
Accessibility Compliance
You must check off all items in one of the follow two lists:
or...
Localization