Skip to content
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

TH-174: Aura > Cart Page > Format product price by the Dotshop object's locale code #64

Open
wants to merge 14 commits into
base: master
Choose a base branch
from

Conversation

eihabkhan1
Copy link
Collaborator

@eihabkhan1 eihabkhan1 commented Oct 16, 2024

JIRA Ticket

Ticket: TH-174.

Prerequisites

  • Have Aura active

QA Steps

Multi Currency OFF

  • From the multi currency settings in seller area, turn off multi currency and enable precision
  • Go to your store's general settings /admin/settings/general#details
  • Change the store language to English - United States
  • Change the store currency to Moroccan Dirhams
  • Change the currency symbol to MAD
  • Go to your product page
  • Add it to the cart
  • Add another product to your cart
  • From the cart drawer, click on "Checkout" to go to the cart page
  • The prices below should be correctly formatted:

Screenshot 2024-10-21 at 3 34 43 PM

  • Go back to your store, change the language to French - France
  • Go back to storefront / cart page, hit refresh
  • The price should be formatted accordingly and the currency symbol should be on the right
  • Go back to your store, this time change the currency symbol to a random currency symbol (ex: Wiwi)
  • Go back to storefront, hit refresh, and open the cart
  • The price should be formatted accordingly and the currency symbol should still be on the right

Multi Currency ON

  • From the multi currency settings in seller area, turn on multi currency and enable precision
  • Turn on your VPN
  • Go to your product's page in storefront
  • Add it to the cart
  • Make sure that:
    • The price for each item in the cart is formatted based on your VPN's country + your browser's language
    • The price is converted to your VPN's country currency
    • The currency symbol displayed is the VPN's country currency symbol
    • The subtotal is also formatted accordingly
  • Go to your browser's language settings, If you're using Chrome just click ⌘ + ,
  • Search for language
Screenshot 2024-10-08 at 8 43 12 AM
  • Click the three dots next to any language and move it to the top to make it your language of choice
  • Go back to your storefront, hit refresh and open your cart
  • The price value(s) and subtotal should be formatted based on your VPN + your browser's language

Note

Note that if your IP address while using VPN is in UK, and you have Arabic as the browser language, then you might see a flash where the price is displayed in indic numerals at first then Arabic numbers ١٢٣.٩٩ ' -> 123.99`. This is likely an issue with how PHP handles ar-GB vs how javaScript handles it. Will tackle this issue in a separate PR.

Note

Leave empty when you have nothing to say.

@eihabkhan1 eihabkhan1 self-assigned this Oct 16, 2024
@eihabkhan1 eihabkhan1 added the in progress Currently being developed. label Oct 16, 2024
@eihabkhan1
Copy link
Collaborator Author

cart.js needs to be refactored: https://youtu.be/mWMFTfaJaWM

@eihabkhan1 eihabkhan1 marked this pull request as ready for review October 21, 2024 14:37
@eihabkhan1 eihabkhan1 added Ready for review Requires a review from another developer. and removed in progress Currently being developed. labels Oct 21, 2024
@ibrilBadreddine
Copy link
Contributor

cart.js needs to be refactored: https://youtu.be/mWMFTfaJaWM

https://www.youtube.com/watch?v=PUhncAezGUQ

@eihabkhan1 eihabkhan1 added in progress Currently being developed. and removed Ready for review Requires a review from another developer. labels Dec 10, 2024
@eihabkhan1 eihabkhan1 marked this pull request as draft December 10, 2024 13:20
@eihabkhan1 eihabkhan1 assigned bj-anas and unassigned eihabkhan1 Dec 17, 2024
@bj-anas bj-anas marked this pull request as ready for review December 17, 2024 15:06
@bj-anas bj-anas added Ready for review Requires a review from another developer. and removed in progress Currently being developed. labels Dec 17, 2024
@bj-anas bj-anas changed the title TH-174-aura: Aura > Format prices in cart page TH-174: Aura > Cart Page > Format product price by the Dotshop object's locale code Dec 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Ready for review Requires a review from another developer.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants