As you can see I can select one coffee then press the ‘Free Coffee’ button which makes that coffee free. However if I select all the coffees they all become free (ouch). So how do I add a constraint to my rule:
So that 1 and only 1 coffee has to be selected for the ‘Free Coffee’ button to be actionable?
It’s a little dirty but
Using this [='{SELECTED ORDERS}'.indexOf(',')] Less than 0
Selected orders gives a comma seperate list of I think order numbers.
So there is only a comma if 2 or more selected.
If none selected the button wont be visable anyway.
So should work.
In the rule you posted I would change MATCHES to MATCHES ALL
then add another custom constraint of:
{SELECTEDORDERS} equals 1
Then your free coffee button would only work if it is pressed when 1 order is selected and they have more than 6 points
Just a thought would that rule not fire if any drink is selected? You could add a product tag to all the drinks in your product list that you want the offer to apply to and add that as another rule constraint so only the selected drinks in the offer can be given free
This works for adding the points. The Menu Item Tag is available in the dropdown if I use the ‘Order Added to Ticket’ event. Do I have to reference it differently when using the ‘Automation Command Executed’ event?
Is this on the automation command rule?
You have to use either the build in variables (the ones written as text) or template type tags. You cant manually use written type variables from other rule events where they are not available in the drop down.
Guessing you have used that on order added where Menu Item Tag is built in. It isnt built in in automation command as its not nececerally a product related event.
For generic tag firld you would use {ITEM TAG}
Yes.
I’m thinking it’s going to be better to have CoffeePoint as a custom tag overall, it will be less confusing in the future if all the tags are the same type.
OK, here’s what I have now and it all seems to work fine.
Adding a point:
Using a custom tag rather than the generic one. And
Giving a free coffee away:
This only fires when the customer has enough points and a single coffee is selected. The added bonus is that if the customer has enough points they can get 2 or more (depending on the points total) free coffees on the same order as long as the coffee to be free is individually selected. This way the staff can’t give multiple coffees or other menu items away by mistake!
Pleas ebe sure to check flow of multiple quantities, ie 2x coffee as I beleive this isnt accounted for.
Selected items I’m pretty sure will show 2x as one order I’d.