Order Discounts

Order Discounts

cvwat
New Member
5 0 0

We are a collective store and I want to be able to offer discounts from the store, but when I do an order discount the discount gets evenly split between all of the products (and product vendors). Is there a way for the discount to come off the order but not affect the product price? 

Replies 8 (8)

cvwat
New Member
5 0 0

Added note, these are for an in store POS system.

Ahmad31
Excursionist
19 3 0

 

Apply the discount at the order level, without altering the individual product prices.

You can add a "discount line item" in the checkout process to reduce the total order price. This way, the product prices remain the same, and vendors receive the correct revenue for their products.

 

cvwat
New Member
5 0 0

Is that the same as a "Custom Cart Discount"? I don't see "discount line item" listed.

Ahmad31
Excursionist
19 3 0

 

A custom cart discount applies a percentage or fixed amount discount at the checkout stage. Shopify natively supports this via discount codes or automatic discounts.

The discount is applied to the total order value, which gets distributed across all the products in the cart. This may reduce the final amount each vendor receives in a multi-vendor store.

 

Ahmad31
Excursionist
19 3 0

You can write a custom script that applies a discount at the cart level without changing individual product prices. This ensures that the discount reduces the total cost but doesn't impact the product breakdown for vendors.
Example of script:


DISCOUNT_RATE = 0.20


Input.cart.line_items.each do |line_item|

next if line_item.variant.product.gift_card?


line_item.change_line_price(line_item.line_price * (1 - DISCOUNT_RATE), message: "20% Cart Discount")
end

Output.cart = Input.cart

cvwat
New Member
5 0 0

Oh man, this is way over my head! 😬

cvwat
New Member
5 0 0

Thank you for all your help! Are you able to tell me where I can locate the "discount line item" that you previously mentioned?

Ahmad31
Excursionist
19 3 0
  1. Log in to Your Shopify Admin Panel: Go to your Shopify store admin by logging in at your-store-name.myshopify.com/admin.

  2. Navigate to Discounts:

    • On the left sidebar, click on "Discounts."
    • This will take you to a page where you can view all existing discounts and create new ones.
  3. Create a New Discount:

    • Click on "Create discount" on the top right.
    • You can choose between:
      • Discount code: A code that customers enter at checkout.
      • Automatic discount: Automatically applied at checkout without needing a code.
  4. Configure the Discount:

    • For discount codes:
      • Enter a code (e.g., SAVE10).
      • Set the discount type (percentage, fixed amount, free shipping, etc.).
      • Specify the amount, usage limits, and any applicable conditions.
    • For automatic discounts:
      • Specify the discount type and conditions for when it should be applied.
  5. Save the Discount:

    • After filling in the required fields, click "Save" to activate the discount.

For Shopify Plus Users:

  1. Log in to Your Shopify Admin Panel: Use the same link as above to access your admin panel.

  2. Navigate to Discounts:

    • Click on "Discounts" in the left sidebar.
  3. Create or Edit Discounts:

    • You can create discounts just like standard Shopify users, but Plus users also have the option to create more advanced discounts using Shopify Scripts.
  4. Use Shopify Scripts:

    • Go to "Apps" in the left sidebar, then select "Script Editor."
    • From here, you can create scripts that apply discounts dynamically based on various conditions (e.g., cart value, specific products, customer tags).
  5. Write the Script:

    • Use the Ruby code to specify your discount logic (like the examples I provided earlier).