Skip to main content
  1. Posts/

Drupal 8 Commerce Promotions - Buy X or more of the same product and get % off that order item

·164 words·1 min·
Drupal 8 Drupal Drupal Commerce Commerce Promo Drupal Development

Currently “Buy X and Get Y” discount is only related to the whole order and not at the order item level.

I needed order item level discounts. e.g. buy 10 or more of the same product and get 10% off that order item.

The new promotion will only discount at the order item level for order items with a quantity of 10 or more.

Example - Buy 10 or more and get a 10% discount. Order Item 1 - Quantity of 5 - No Discount Order Item 2 - Quantity of 11 - 10% off discount Order item 3 - Quantity of 10 - 10% off discount Order Item 4 - Quantity of 1 - No Discount

I have created a patch for this type of discount. The discount is labeled: “Buy X per order item get a percentage off.” The new promotion only allows only for a percentage off discount and does not include a fixed amount discount.

Drupal Commerce Issue Queue: https://www.drupal.org/project/commerce/issues/3066724

Michael Michalak
Author
Michael Michalak
Experienced Drupal consultant and Fractional CTO with over 13 years of expertise in backend development, optimization, and securing Drupal applications, specializing in custom module development, migrations, and enterprise integrations across various industries.