Magento2: 2.1.2 Admin Promotional Cart Rule Conditions issue with Category

Created on 21 Nov 2016  路  15Comments  路  Source: magento/magento2

Apply Discount to Category for Admin orders does not function as expected.

I'm looking to products by the category they are in and have the discount code also be available for an Admin order. This does not work as expected, the coupon does work on the Front-end as expected. Additionally, I'm not sure if the issue is related to configurable or non-visable products but I included that as my precondition as that is how all products are configured.

Preconditions

  1. Magento version 2.1.2
  2. Ngnix, PHP7
  3. Existing Configurable Products
    4.) Existing Categories
    5.) Children of Configurable products are not visible individually

Steps to reproduce

  1. Create Category (ID for example is 8)
  2. Create Configurable Product with Multiple Children (Assign to Category with ID 8)
    Parent SKU is ParentA
    Children SKU are as follows:
    SKUA
    SKUB
    SKUC
  3. Create "Cart Rule" with Coupon Code "TEST"
  4. Conditions for Cart Rule are Default Apply to All
  5. Actions Set to
    Apply "Percent of Product Price"
    Discount Amount "90"
    Remaining set to defaults

Apply the Rule to the cart items....
If ALL of these conditions are TRUE :
Category is 8

Note: Also tried "Category is one of 8", and MAGETWO-55184 is still an issue so I had to enter the category ID manually because the selector does not work.

  1. Create order in Admin Panel, with product of SKU ParentA with Child Selected of SKUA

Apply Coupon Code: of TEST.

Expected result

  1. SKUA would receive a 90% discount

Actual result

  1. Magento responds with Coupon is not valid.

Note: This same coupon code works correctly on the front-end of the site. Admin is the only area where this is effected.

test_rule

Tax needs update bug report

Most helpful comment

@veloraven, I understand that you feel this issue should be closed, but the issue is not solved. This is still an issue in the latest release. 2.1.3

All 15 comments

Hi, thank you for your report. This issue was fixed in 2.1.3 version. So please check fix just after release and close issue if problem fixed for you

I will test and inform on Monday.
Thank you

Is there a commit related to this fix?

I can only share the link to commit from develop branch a86eda since 2.1.3 is not available in public yet. If you want to apply it for 2.1.3(will be available soon), use this link but skip changes to file SalesRule/Model/Rule/Condition/Product/Combine.php (develop branch specific only)

Thank you, I will keep watch out, I will request to close this ticket once I'm able to test 2.1.3 or your commit hash you sent me works as expected.

@olysenko is there a release time period for 2.1.3 yet? ie in the next month?

@olysenko, this does not solve the issue I am experiencing at least by applying the commit to 2.1.2

@duffner, sorry the link to fix in develop branch was incorrect, the correct one is this a86eda

According to contributor guide, tickets without response for two weeks should be closed.
If this issue still reproducible please feel free to create the new one: format new issue according to the Issue reporting guidelines: with steps to reproduce, actual result and expected result and specify Magento version.

@veloraven, I understand that you feel this issue should be closed, but the issue is not solved. This is still an issue in the latest release. 2.1.3

@duffner, I will check this issue in release 2.1.3 again

Is there any fix available for this in 1.9.1.1?

@nikhilSBL this repo is for Magento 2 only.

I could not find magento 1 repo. I am in urgent need of a resolution of the same issue but for 1.9.1.1
Could you please give me some direction?

There is no official Magento 1 repo. You can try to search for a solution in any unofficial repo but I doubt it was ever fixed by somebody.

Just get an idea from

I can only share the link to commit from develop branch https://github.com/magento/magento2/commit/a86eda34f882d9254f707a09f9e209b5c54ee632 since 2.1.3 is not available in public yet. If you want to apply it for 2.1.3(will be available soon), use this link but skip changes to file SalesRule/Model/Rule/Condition/Product/Combine.php (develop branch specific only)

fix and apply it to your codebase.

Was this page helpful?
0 / 5 - 0 ratings