Discussing Shopify Functions development, deployment, and usage in Shopify apps.
I have two applications on my store and both of them have their own Product Discount Function to give discounts to cart line items
But only one of them is working
Is that actual behavior or all of the applications' Production Discount Functions should work simultaneously?
If they should work simultaneously, which discount will be applied if their return result will cross?
When discounting the same product, the most advantageous discount is applied. It doesn't matter if it's a special discount or a Shopify Standard discount. The image I added will help you.
Thank you for your response, I think the image that you provided illustrates how it behaves on the single Product Discount Function
My question is a bit different, how do they behave if there are two Product Discount Functions in a store
In my case, only one of them is working, is it expected behavior? I didn't find any information about this limitation
Yes, expected behavior. Even if you make a discount with functions, the situation will not change. As a result, you are trying to give 2 discounts on one product. A maximum of one discount is given to a product. The discount offered the most is applied.
If a second discount is necessary, you can view the discount with cart transform. If you have the Plus plan. If not, you can't do it.