Change State when product is selected


We use loyalty cards that are stamped with each purchase and customer receives cash off after 5 purchases.

I have setup each Loyalty value as a product with a negative value and set them to fast menu (see below)

This works fine for our purpose.
My question is how can I change a state “LStatus” to ‘Loyalty’ when one of the Loyalty buttons is pressed.
The reason being that when a loyalty card is used we print 2 tickets (one for us and one for customer), so I want to test for the LStatus in the Execute Print Bill.

Possibly not the correct way to achieve this, but it is simple and works up to the printing 2 tickets.


There are 3 ways you could do this…

  1. You probably could trigger this to happen “when the button is clicked” using an automation command assigned to that menu item.
  2. Create an “order added to ticket” rule with a constraint of Product Name Starts “Loyalty” and then add an “Update Order State” action to your rule to set the state correctly.
  3. Finally, by far the easiest way to achieve this is to go to Admin > Products > Menu and then click on “Edit Product Properties” and in that table you can set the order state by putting LStatus=Loyalty in the Order State column.

I hope this helps :slight_smile:

1 Like

You might need to set and check a Ticket State instead. Because how is the Print Bill button supposed to know which Order State for which Order that you want to check?

So when you click a Loyalty button, have it set a Ticket State and then when Print Bill happens, check that Ticket State.

1 Like

Good point, I completely forgot to think how this would actually solve the core problem!

You could also check the value of {ORDER STATE TOTAL:Loyalty} if greater than 0 then print 2 copies.

1 Like

Firstly thank you to all who have replied

I can not find a way to change a ticket state when i select a product.


Use Update Ticket State action. Use the rule you prefer… sounds like you may want Order Added to Ticket rule…

1 Like

I am trying to use number 2 option, but I cannot work out the expression to find the word “Loyalty” contained in the Product Name.

What would the constaint expression be to do this.


On order added you have containes as a constraint in middle dropdown.
And sure product name will be a preset first dropdown.
And type loyalty on the 3rd box rather than using dropdown.