# How to create a Promotion based on basket item quantity

**URL:** https://forum.shopware.com/t/how-to-create-a-promotion-based-on-basket-item-quantity/65128
**Category:** General Questions (EN)
**Created:** [2. März 2020 um 12:41 UTC](https://forum.shopware.com/t/how-to-create-a-promotion-based-on-basket-item-quantity/65128 "2020-03-02T12:41:54Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![davit\_sargsyan](https://avatars.discourse-cdn.com/v4/letter/d/7ba0ec/32.png) [@davit\_sargsyan](https://forum.shopware.com/u/davit_sargsyan)
#### Post date: [2. März 2020 um 12:41 UTC](https://forum.shopware.com/t/how-to-create-a-promotion-based-on-basket-item-quantity/65128/1 "2020-03-02T12:41:54Z")

</div>

How to create a Rule so that for each item in the basket with certain tag, the user will get a discount for a certain about.

Example:

If there are 3 units of 1 item with tag „abc“ and 2 units of another item with tag „abc“, then he will get (3+2) times 2$ discount, so 5\*2=10$ discount.

---

<div class="post-metadata">

### Author: ![davit\_sargsyan](https://avatars.discourse-cdn.com/v4/letter/d/7ba0ec/32.png) [@davit\_sargsyan](https://forum.shopware.com/u/davit_sargsyan)
#### Post date: [7. März 2020 um 12:15 UTC](https://forum.shopware.com/t/how-to-create-a-promotion-based-on-basket-item-quantity/65128/2 "2020-03-07T12:15:21Z")

</div>

I did a research and want to share my findings.

It seems that in GoodsCountRule.php they forgot to count the number of same items. They only count the different products. It can be fixed by multiplying the item quantity for each item.
