Skip to content

Feature minimum order amount notice issue #13039

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

Merged
merged 7 commits into from
Jan 10, 2018
Merged

Feature minimum order amount notice issue #13039

merged 7 commits into from
Jan 10, 2018

Conversation

neeta-wagento
Copy link
Contributor

@neeta-wagento neeta-wagento commented Jan 7, 2018

During currency switch notice message shows wrong calculation of minimum order amount.

Description

This is about notice message of min order amount on cart page.When we have set min order amount and on cart page someone change currency, user see same amount and only currency symbol changed. It should recalculate amount also.
Instead of currency convert, we use price helper then it gives us re calculated price amount in notice message.

Fixed Issues (if relevant)

  1. magento/magento2#<issue_number>: Issue title
  2. ...

Manual testing scenarios

Preconditions

Any Product must be created and enabled in frontend with the price greater then 0 or less then 1000
Steps to reproduce

Enable Minimum Order Amount
Login to [Magento Admin Panel]/ Stores -> Configuration -> Sales -> Sales -> Minimum Order Amount and do the following
Set Enable "Yes"
Enter Amount for example 1000
Leave Description Message text blank
Leave Error to Show in Shopping Cart blank
Save the Configurations by clicking on "Save Config" button on top right corner
Now setup Multiple currencies for that follow below steps
Go to section Stores -> Configuration->General->Currency Setup

Now select multiple currencies from Allowed Currencies by pressing ctrl key
select Brazilian Real, Indian Rupee, Japanese Yen, Russian Ruble, US Dollar

Import Currency Rates
Go to Stores -> Under Currency Title click on Currency Rates.
Select any of service and click on import rates it will import live currency rates.
Go to Frontend Add any product in shopping cart add any product 1 qty which has price less then 1000.
Go to cart page "View and Edit Cart" link which you can see on Minicart Popup or by browsing url [Magento base url]/heckout/cart/
You can see the default message on "Minimum order amount is $1,000.00"
Now change the currencies from header upper right corner. You can see Minimum order amount is $1,000.00 in any currency you selected

Expected Result

32069992-def1c89c-ba58-11e7-8e7e-bdece0d6f268
32069993-df303d34-ba58-11e7-8d97-a021f5f5b31f

Contribution checklist

  • Pull request has a meaningful description of its purpose
  • All commits are accompanied by meaningful commit messages
  • All new or changed code is covered with unit/integration tests (if applicable)
  • All automated tests passed successfully (all builds on Travis CI are green)

*/
public function __construct(
\Magento\Framework\App\Config\ScopeConfigInterface $scopeConfig,
\Magento\Store\Model\StoreManagerInterface $storeManager,
\Magento\Framework\Locale\CurrencyInterface $currency
\Magento\Framework\Locale\CurrencyInterface $currency,
\Magento\Framework\Pricing\Helper\Data $priceHelper
Copy link
Contributor

@ishakhsuvarov ishakhsuvarov Jan 7, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This argument should be optional to maintain backward compatibility
More info available in devdocs

@dmanners dmanners added the mm18in label Jan 7, 2018
@ishakhsuvarov ishakhsuvarov self-assigned this Jan 7, 2018
@ishakhsuvarov ishakhsuvarov added this to the January 2018 milestone Jan 7, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants