Skip to content

chore: Handle B2B users scenario #2760

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 4 commits into
base: main
Choose a base branch
from
Draft

Conversation

lucasfp13
Copy link
Contributor

What's the purpose of this pull request?

This PR intends to check for customerId when a user is related to a B2B org.

How to test it?

  • Change account to b2bfaststoredev and run the server;
  • When login and create the cookie, use it on http://localhost:3000 and check IndexedDB for the customerId value.

Starters Deploy Preview

@lucasfp13 lucasfp13 self-assigned this Apr 2, 2025
@lucasfp13 lucasfp13 requested a review from a team as a code owner April 2, 2025 18:03
@lucasfp13 lucasfp13 requested review from hellofanny and renatamottam and removed request for a team April 2, 2025 18:03
Copy link

codesandbox-ci bot commented Apr 2, 2025

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

@lariciamota lariciamota force-pushed the feat/delivery-promise branch from a28d534 to 8fbe4f1 Compare April 8, 2025 12:46
@lucasfp13 lucasfp13 changed the title chore: Handle B2B users chore: Handle B2B users scenario Apr 9, 2025
@hellofanny
Copy link
Contributor

@lucasfp13 this PR is blocked for now right? Can we convert to Draft or add a label until we have the other's team reply pls👍

@lariciamota lariciamota force-pushed the feat/delivery-promise branch from 8805012 to c540749 Compare April 11, 2025 17:59
@lariciamota lariciamota force-pushed the feat/delivery-promise branch from c540749 to b0aa3d3 Compare April 22, 2025 14:00
@lucasfp13 lucasfp13 marked this pull request as draft April 30, 2025 18:07
@lariciamota lariciamota force-pushed the feat/delivery-promise branch 2 times, most recently from 789c99a to b41c2a9 Compare May 12, 2025 18:11
Base automatically changed from feat/delivery-promise to main May 13, 2025 12:51
lucasfp13 and others added 4 commits May 16, 2025 13:49
This PR intends to ensure all location data (`postalCode`,
`geoCoordinates` and `country`) is being synchronized when needed.

It updates geo coordinates when users set a postal code and ensure
location data won't be overwritten if users grant geo location consent
late.

- Enable Delivery Promise on discovery.config;
- Open the localhost store on anon tab (to ensure no stale data);
- First, consent geo location data from popup and look to the IDB
`fs::session` value, it should fill `geoCoordinates` data after
`useGeolocation` hook execution;
- Then try to set a postal code, the `postalCode` should be set and
`geoCoordinates` should be different now (based on the postal code);
- Another test: open another anon tab and, while the popup asking for
geo location consent set a postal code. Then, after the session is
updated with the new location (based on the postal code), grant the geo
location consent and nothing should happen since user have already set
the postal code.

vtex-sites/starter.store#734

---------

Co-authored-by: Fanny Chien <[email protected]>
Co-authored-by: Larícia Mota <[email protected]>
@lucasfp13 lucasfp13 force-pushed the chore/b2b-saved-addresses branch from 87107af to cdb12e7 Compare May 16, 2025 16:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants