SambaPOS Is Live!

I’ve finally put SambaPOS into production! Yay!
Thanks to everyone for their help.

I do have 1 small issue with my coffee rewards system. Essentially everything works but I just need a constraint which I can’t figure out.

Here is my order screen:

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:

Free Coffee Rule

So that 1 and only 1 coffee has to be selected for the ‘Free Coffee’ button to be actionable?

OK, so not too much rush on this now, the NZ Government has just shut all cafe’s and restaurants etc down for 4 weeks, eek!


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:


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

1 Like

Rick is right about it would work for any product.

However the matches is ok as matches is and for different conditions but or where condition is similar.

1 Like

Thanks for the suggestions, I’ll try them out in the morning. :+1:

I already have the tag ‘coffee point’ so I’ll use that. :grinning:

1 Like

Joe’s suggestion has worked as is so I’m using that now.

Using {SELECTEDORDERS} equals 1 or {SELECTED ORDERS} equals 1 seems to cause the entire rule not to fire.

If I add a constraint for the Menu Item Tag = CoffeePoint


The rule doesn’t fire either.

Menu Item Tag is the generic tag field on product.
If you created a custom tag field you should use {ITEM TAG:<TagName>} equals TagValue

I used the existing Tag field:


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}

1 Like

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!

Thanks heaps for the help guys!!! :+1:

1 Like

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.

Yes, I did think of that and:

{QUANTITY} Equals 1

Does the trick!

1 Like

A few tweaks:


Takes care of multiple coffees on one order line. Both adding and subtracting:


This takes care of just giving 1 free coffee at a time: