Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [rules]

The tag has no usage guidance.

3
votes
2answers
119 views

Magento 2 Can't get the sales rules conditions in my ui form submit

I have a UI form which contains 2 fields one is 'name' and the other is the 'conditions'. I have tried the below code to display the conditions section and it is working fine. But I did not get the ...
2
votes
0answers
12 views

Magento 2 : Category products dynamic rules get scope between 10% and 20% discount

We have a category where we need to add all products from another category with between 10% and 20% discount. The problem is that some of the products have a special price AND a price-rule which ...
0
votes
1answer
22 views

Magento 1.9 multiple pricerules pick the highest discount

At our magento site we have some different price rules where some of the products affected are the same. But it should not apply all rules to the product only one, we want it to set the discount ...
1
vote
1answer
32 views

How to duplicate sales rule programmatically in Magento2

Im try to duplicate some salesrule exist, i can duplicate this, but i can't use setConditionsSerialized and setActionsSerialized with getCondition and getActionCondition, its dont working use ...
2
votes
0answers
31 views

Different discount for category products

I want to know is there a way to get different discount for the products in the same category if quantity exceeds a limit. For example: I have these products with these prices: A=10 B=15 C=12 And ...
0
votes
1answer
60 views

Cart Rules - Not logged in

I've set up a cart rule that applies if: payment method is Bank Transfer. It is always applied, except when an order is placed as a guest. Can you help me? NB: All the user groups present are ...
1
vote
0answers
110 views

Magento 2.3.0 How to display only product attribute in custom rule condition into the custom admin form using the ui component

I have implement custom condition Rule to my custom module Take refrance from this link and it is working fine. But it is display also other rule like cart attribute, customer attribute, other ...
0
votes
1answer
186 views

Magento 2 How to put a rule condition into the custom admin form using the ui component

Magento 2 custom extension how to put a rule condition into the custom admin form using the ui component with data base interaction. please refer the following rule condition image
1
vote
0answers
51 views

How to get acting to product price rule in Magento 2

/magento-catalog/templates/product/price/final_price.phtml <span class="old-price"> <?php /* @escapeNotVerified */ echo $block->renderAmount($priceModel->getAmount(), [ '...
1
vote
0answers
134 views

How to Reset Magento Admin Permission

Admin role have no permissions, when I log in I just see only a extensions. How to reset permission in database MAGENTO 2 version?
0
votes
1answer
18 views

How to set discount code for one country using only?

Can anyone help to teach me how to set specific discount code only for specific country only? Thanks!
3
votes
1answer
44 views

Apply discount for For every $X spent Programatically in magento 2

I want to apply the discount on every $X spent amount. For example, if $5 discount for every $10, and my cart total is $34 then, I will get the discount of $15. Is it possible by programmatically ...
1
vote
1answer
251 views

Magento 1.9 : How to add product with discount automatically in the shopping cart?

Hope you're all doing well. I need some guidance in how or if some tool already exist for this: If an specific product enters the shopping cart, automatically one other specific product appears in ...
0
votes
1answer
325 views

Related Product Rules not showing up in magento2?

I am trying to create Related product rules by following below link. https://www.bluefishgroup.com/insights/ecommerce/related-products-rules-in-magento-2/ When i navigate into Marketing i can see ...
2
votes
0answers
102 views

Magento 2: How to validate cart price rule in product view?

I'm trying to show the price rules in the product view, but I can not find a way to validate if a product meets the rule... At the moment I just get all the rules. Block: class RuleDescription ...
0
votes
0answers
46 views

Magento 2 : Make Field Required on Dropdown Selection Yes or No

I have added a timer yes/no dropdown in catalog rule module. When I select yes End date should become required field, if no then it should be optional.
0
votes
2answers
107 views

Catalog Price Rules: "Stop Further Rules Processing' (not cart rules) - how does this work? M1

Catalog Price Rules: "Stop Further Rules Processing" (not cart rules) - how does this work? So, How does "Stop Further Rules Processing" work? does this work in product level? set a flag: stop ...
8
votes
1answer
367 views

Restricting customers to max of (some number) purchases for a certain product in Magento

Is there any good modules out there that can handle this? Or would this be a custom event / observer that needs to be written? Here's an image on a non magento site that shows specifically what i'm ...
1
vote
1answer
1k views

Magento 2 - Cart price rules promotion rule based on specific category products added specified

I am new to Magento 2 and working with cart price rules but unable to get the required results. 1- I would like to apply 5% discount if more than 30 and less than 60 units added from specified ...
1
vote
0answers
30 views

Using QTY in Rule-Based Product Relations

Using Magento EE 1.14 and would like to be able to use the inventory quantity for rule-based product relations (related, upsell, cross sell). However, I don't see a way to make the quantity available ...
0
votes
1answer
25 views

How to set up a promotion rule which enable users to get additional discount for certain bank card holder?

Does anyone know how to set up a promotion rule which enable users to get additional discount for certain bank card holder? Can we create it in Magento 2 default or can anyone suggest an extension if ...
1
vote
1answer
137 views

How to create 2 shopping cart rule in magento 1.9.3.2

We are selling dress where with different Category A and B. Category A need to give buy 2 or more to get 15% Off. Category B is flat 10% off on all products. If people buy Category A 1 product and ...
1
vote
1answer
315 views

How to filter Products with activated Flag?

I use the Use for Promo Rule Conditions flag. How can I filter only products having this flag set to yes? Is there a table where it is set so that I can use it for filtering?
2
votes
0answers
601 views

How to set shipping rule in magento2?

How to set below rule? Shipping & Handling Fee is 20% if the order is between $50 to $150, 15% if the order is between $150 to $300.
1
vote
2answers
64 views

How to label products to indicate cart rule has been applied?

I want to display a product label if a cart rule has been applied to a product but the label is being displayed for all products even those who don't qualify for the cart rules. Here is the code I am ...
1
vote
1answer
28 views

Bypass Minimum order ammount for downlodable products

It is possible in a store with 500€ minimum order ammount to set a custom cart rule that allow to bypass the minimum order for a certain type of product or a category? I tried to set up a shopping ...
1
vote
1answer
1k views

How to give user agent rule for iPad and Tablet in Magento 2.1?

I have two themes, one for mobile and other for desktop. I have created 2 user agent rules for Mobile and iPad. All mobiles are showing mobile theme. But iPad and Tablets are also showing mobile theme....
0
votes
0answers
164 views

Used coupon not displaying in admin order

I have generated shopping cart rule which is applied for free shipping. If other rules are applied then it's displaying in order details in admin but free shipping rules is not. I need to know which ...
0
votes
2answers
1k views

magento set “catalog price rules” *only* if special price was not set

I am looking at magento "catalog price rules" and although I have added the special_price to filter conditions: I dont think I can do the following question: How can I only apply the "catalog price ...
4
votes
1answer
503 views

What are the differences between the promotion actions?

I've two location to set my cart promotion rules, what are the differences? I can set the rules in Conditions and Actions. For example: Conditions tab Actions Tab
0
votes
1answer
281 views

Magento 2: Override Price of shipping if customer is logged in?

How would I override the price of shipping if a customer is logged in? For example, Flat rate shipping for guest checkout is $4.99 but if you are logged in you can get it for $2.99. I do no ...
1
vote
0answers
77 views

How can I add to user a products roles?

I created a user, and I can't add any role to him.. I want to add this roles to my user... my code is below... and when I save the user and the role, I don't see this green "V" on my role.. I just ...
0
votes
0answers
221 views

How to add Condition for apply Promotion rules while create order Programmatically in Magento?

I want to add a condition (whether to apply the promotion rule or not as per the configuration settings) before the Promotion rule applied while create order Programmatically. Can anyone suggest?
1
vote
1answer
36 views

Magento 2.1 Tax Set Up

I would like to make tax rules in my store: All foreign customers: 0% Tax All Dutch customers: a) up to 10000 Euro: 21% Tax b) from 10000 Euro: 0% Tax How should i do this and is it even possible ...
0
votes
1answer
44 views

problem VAT for muti views

My website run with the version 2.1.2 I created two views. one for switzerland and one other for France. So, i would like to get two VAT different. 8% for switzerland and 20% for France. But ...
4
votes
1answer
1k views

How to extend rules.js in magento 2?

I try to overwrite rules.js from vendor/Magento_Ui/web/js/lib/validation/rules.js in my custom theme but it dosen't work. I found this solution but it's not working for me : Magento 2 How to extend ...
1
vote
1answer
292 views

Price Rules Free Shipping problems

Is there anyway to configure Magento's Price rules so that if Free shipping is given for purchases which in total are equal to or greater than X AND if a coupon reduces X to a lesser value customer ...
0
votes
1answer
285 views

Exclude Category from Catalog Price Rules

I want to make a discount for only ONE category in Catalog Price Rules but I dont understand the Conditions tab.
1
vote
1answer
1k views

Magento 2: Cart Price Rules - Buy X get Y free (discount amount is Y) is Not Working

I'm using Magento 2 CE Version 2.12 I have followed the below one, as well other tutorials. https://www.mageplaza.com/kb/how-setup-buy-x-get-y-free-in-magento-2.html Still, it's not working.
4
votes
1answer
1k views

How to get maching products based on rule conditions

how to get matching products based on rule conditions i need to filter product grid according to rule condition in my custom module I have used it as a filter Array ( [conditions] => Array ...
3
votes
1answer
3k views

How to apply simpler password constraints for customers in magento 2

When setting up a new password, a customer may read the following message : Minimum of different classes of characters in password is 3. Classes of characters: Lower Case, Upper Case, Digits, Special ...
1
vote
0answers
138 views

how to restore deleted Shopping Cart Price Rules in magento 1.8

I accidentally deleted shopping cart price rule "xyz". By doing so all the codes and their statues was also deleted. Can we retrieve this ?
0
votes
1answer
1k views

How to create Tax rule programmatically in controller magento 2

I have try with this code make tax rule programmatically. but it's not working infact model not loaded. you can see this code : $objectManagers = \Magento\TestFramework\Helper\Bootstrap::...
3
votes
2answers
2k views

How do I programmatically load a specified sales rule in Magento 2?

In Magento 1 EE, I was able to get sales rule information from product list page with the following: $rule = Mage::getModel('salesrule/rule')->load($ruleId); $isActive = $rule->getIsActive(); $...
8
votes
2answers
5k views

Magento Add Condition Rule In A Custom Form in magento 2

I want to add condition action in custom module admin form. How can I achieve this? Refer link for Magento 1.9 Replacement of above link for Magento 2.
2
votes
0answers
109 views

Magento salesrule override not working

I want to override the SalesRule model for my custom module, but it already used in another third party module. But the problem is my override is loading always first. And the third party module's ...
1
vote
1answer
174 views

Shopping Cart Price Rule for European Union Countries

In Shopping Cart Price Rule I can set condition as "Shipping Country" "is" or "is not". I need to extend this condition to all European Union Countries. Since Magento has this configuration in ...
0
votes
1answer
60 views

Cart Promo Rule

How can i set up a cart promo rule : If a customer buy 3 items from products without special price, then he/she get a discount 15% only for items in cart which haven't special price?
0
votes
0answers
309 views

Magento 1.9. Sales rules with quantity in cart not working

Magento sales rules with the next configuration ( Quantity in cart equals or greater than 1 AND Quantity in cart equals or less than 4) not working, it's applyng for product even there are 7 ...
0
votes
2answers
717 views

need to create shopping cart price rule for buy 2 get 5% off and buy 3 get 10% off

I wanted to give an offer to the users. If they buy the same product with qty 2 then 5% off and if they buy 3 then 10% off. I tried it with shopping cart price rules but only one shopping cart price ...