Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I had a situation where I need to give commerce discount depending on the products type. I found another issue discussing similar feature request here.
This is a screenshot of the functionality that it adds.
The attached patch is against the dev version of the module.
Comment | File | Size | Author |
---|---|---|---|
#4 | inline_conditions-add_product_type_condition-2155893-4.patch | 4.24 KB | jkuma |
#1 | inline_conditions-add_product_type_condition-2155893.patch | 4.18 KB | pontus_nilsson |
commerce_discount_product_type.png | 15.03 KB | pontus_nilsson |
Comments
Comment #1
pontus_nilssonComment #2
pontus_nilssonComment #3
pontus_nilssonComment #4
jkuma CreditAttribution: jkuma commentedHello pontus_nilsson,
Thanks for the patch, it's well written, and it's working good to me. I've just added this line to allow granted users to easily update the product type criterion from the rule condition itself.
Pushed in 7.x-1.x branch. diff
Comment #5
pontus_nilssonNice catch! Thanks.