Magento2: Tiered pricing and quantity Increments do not work with decimal inventory

Created on 29 Dec 2017  Â·  35Comments  Â·  Source: magento/magento2


Preconditions


  1. Magento 2.2.2
  2. PHP 7.0
  3. MySQL 5.6

Steps to reproduce


Tiered Pricing Issue:

  1. Create Simple Product
  2. Set Inventory to 100
  3. Set "Qty Uses Decimals" in Advanced Inventory to "Yes"
  4. Set Base Price to 3.99
  5. Open Advanced Pricing tab
  6. Set a Tiered Price for Qty of .5 and price of 2.99
  7. Save

Quantity increment issue:

  1. Open Advanced Inventory
  2. Set "Enable Qty Increments" to "Yes"
  3. Set "Qty Increments" to ".5"
  4. Save

Expected result

  1. During each of the above scenarios, the product should save and allow tiered pricing and qty increments to work with decimal-based inventory

Actual result

  1. Product does not save, admin user is given error stating "Please enter a valid number"

screen shot 2017-12-28 at 8 57 43 pm
screen shot 2017-12-28 at 9 00 18 pm

This feature works as expected in Magento 1 EE, and is the basis for many of our customers who sell by .5, .25 lb increments but inventory by the 1lb of product. This prevents a customer from selling .25 lbs for $3.00 but selling 1lb for $10.00 as tiered pricing does not allow decimals. Additionally, since many customers sell in quantity increments under 1, a user should not be able to order .001 lbs as it's too little to measure.

Cannot Reproduce Clear Description Format is valid Ready for Work Reproduced on 2.1.x Reproduced on 2.2.x Reproduced on 2.3.x

Most helpful comment

@alexbogias working on the PR travis issues... I believe in the next month it's gonna be merged for sure.

All 35 comments

For reference, an Enterprise Support ticket was also filed: Ticket #03228956

@duffner, thank you for your report.
We've created internal ticket(s) MAGETWO-86164 to track progress on the issue.

AdditIonal note: This same issue also affects bundle product options. If you add a simple product that allows decimal inventory to a bundle product’s bundle options the same “please enter a valid number in this field” error appears.

Hi!
@duffner , I'm on my way of fixing this.

During issue solving I also found that after saving the product with _Qty Decimals_ enabled, _Qty Increments_ and _Tier Price Quantity_ are integer numbers. This will be fixed as well.

@magento-engcom-team, could you please assign the issue to me ?

Thanks & Cheers!

@vasilii-b, awesome! I appreciate your quick response! 👍

@vasilii-b, it also appears that your noted issue with integer vs decimal numbers affects the front-end in the same way, e.g. mini cart and checkout

Thanks for letting me know, @duffner

@vasilii-b , is there a commit relating to the January 2018 milestone? I'd be glad to test as well

@duffner I'm preparing the PR for tomorrow.

When will this be released?

@okorshenko, do we know what release version this issue will be corrected in?

Any news on the release date for this yet?

Any news on this @vasilii-b?

@alexbogias working on the PR travis issues... I believe in the next month it's gonna be merged for sure.

Thanks for letting us now @vasilii-b

Any update as to which release this resolution is likely to appear in? I'm interested as it resolves an issue I raised some time ago that was incorrectly reclassified as a "feature request"..

https://community.magento.com/t5/Magento-2-x-Feature-Requests-and/Product-Bundle-Items-can-t-have-a-decimal-default-quantity/idi-p/73599

Cheers.

this is resolved or not ??

This is not resolved

Thank you @engcom-backlog-nazar! Any update on fixing this issue, and if not is there a special code that we can add to temporarily fix this?

@magento-engcom-team, unfortunately, I left the Magento Partner I was at, but Magento EE support has a fix for this that they've shared with me previously, however, I no longer have access and I'm hoping they can provide this to the community!

@duffner Thank you very much for the reply. Could you provide us with contact info of Magento EE? This issue seems to be left here forever with no udpates :( .

Or do you think we could apply another approach? Will the new Magento version work with this feature?

@KatPham0304, unfortunately, Magento EE support is private. I was hoping that be referencing Magento Eng team they would look up this ticket and share.

@vasilii-b, this was fixed via the EE support team I believe, but I don't know if this fix ever made it back to the community.

Has any progress been made here? This is blocking a merchant who sells be weight from migrating from m1 to m2.

Has any solution been found yet?

I just pulled Magento 2.3 vanilla and this is still an issue. The issue with decimal based inventory now works on the front-end for standard pricing, but the second case of my original issue still exists.

It appears that the issue maybe now just validation related on the inputs within the Admin, but the following use case which exists as a feature in m1 does not work almost 3 years later!!!!

Enter the following values into the product

Base Price 10.00
Advanced Pricing
Qty .5 ----> Discount "Percentage " value 10%
Qty .75 ----> Discount "Percentage " value 25%
Qty 1 -----> Discount "Percentage " value 50%

screen shot 2018-12-07 at 6 04 08 pm

Then Save the product

Review Advanced Pricing: And the following result is displayed.
Qty 0 ----> Discount "Percentage " value 25% (error displayed)
Qty 1 -----> Discount "Percentage " value 50%

screen shot 2018-12-07 at 6 07 19 pm

Tiered pricing with decimals does not save.

Once this is corrected, the tiered pricing "Buy .5 and save 10%" will likely not work as well. Any business that sells by weight in decimal quantities cannot leverage Magento. This was a Magento feature in m1 for almost 10 years! Let's not let it die in m2.

@magento-engcom-team, @vasilii-b it would be great to know what's going to happen here!

Thank you,

Robert

I assume that now this issue is unassigned we are unlikely to see a resolution any time soon? It sounded so promising for a while but regrettably it is still a showstopper for me to be able to migrate my web shop across to Magento. If I had any clue about coding I'd have a go myself but that isn't where my skills lie unfortunately..

@thatguynz there is actually a pull request #13359 to fix it, but as you can see from its history its not going to be merged - we are kindly forced to cover with tests...

So in a nutshell - at this stage nothing is likely to happen with it until someone else picks it up which would seem to be fairly unlikely?

@vasilii-b, these types of things make it so frustrating to like Magento. This is a blatantly missing feature and Magento is more focused about Unit Tests than missing/broken functionality. Not your fault at all, but every ticket I've created seems to go this same way. At some point, why should the community care?

@magento-engcom-team , is this the plan?

I assume there has been no further development here? Seems that Magento is a beautiful platform if you're selling widgets that are dealt with in Integers but as soon as a Decimal requirement exists, it falls down badly..

@magento-engcom-team, Do we have any updates here?

Do we have any updates here?

Hi @engcom-Alfa. Thank you for working on this issue.
Looks like this issue is already verified and confirmed. But if you want to validate it one more time, please, go though the following instruction:

  • [ ] 1. Add/Edit Component: XXXXX label(s) to the ticket, indicating the components it may be related to.
  • [ ] 2. Verify that the issue is reproducible on 2.4-develop branch

    Details- Add the comment @magento give me 2.4-develop instance to deploy test instance on Magento infrastructure.
    - If the issue is reproducible on 2.4-develop branch, please, add the label Reproduced on 2.4.x.
    - If the issue is not reproducible, add your comment that issue is not reproducible and close the issue and _stop verification process here_!

  • [ ] 3. If the issue is not relevant or is not reproducible any more, feel free to close it.


Hi, @duffner. Thank you for your reporting.

We are not able to reproduce this issue on the fresh 2.4-develop instance. Everything works well.
So we have to close it.

Please feel free to comment, reopen or create new ticket according to the Issue reporting guidelines
if you are still facing this issue on the latest 2.4-develop branch.
Thank you for collaboration.

Was this page helpful?
0 / 5 - 0 ratings