Trigger a Print Job

Hi Guys

I’m trying to make a print job trigger when a condition is met.

My items on my menu are tagged with either Main, Starter, Dessert etc using a custom product tag.

I want the system to know for example when 2 Main meals have been sold prints a discount voucher for money off there next bill etc.

What is the custom constraint I need to use to trigger a print job for the vouchers.

Hope Ive made sense with what ive described.



Think you can just setup a new rule for order added to ticket

Set custom constraint as { ITEM TAG:Main } greater than 2

Add your print job that you want to print

So when you add two orders where their product tags are both Main it should print your print job

or maybe actually do it in a ticket closed/closing rule with remaining balance equals zero so it will only print was ticket is paid, otherwise as soon as you add the two orders the order added rule will print your job. Which then leaves a possible misuse issue where the orders are then removed so potentially discount vouchers given out with no actual order made

I dont think that would work as order added would only relate to that addition, a report expression will be needed.

You would want to use a report expression to count the orders of specific condition and use this number as a constraint.
Your ‘trigger’ would most likely want to be on ticket closing with constrains similar to the final payment ‘mark ticket closed’ rule so remaining balance < 0 and total > 0.
So on ticket closing rule
remaining balance <0 (ticket has been paid)
ticket total >0 (ticket had a value - ie not a all void ticket)
report expresion to count main orders > 1 (2 or more)

1 Like

Hi Guys,

Simply when an Order is added to a ticket they are tagged with MAIN, STARTER, DESSERT etc so that the kitchen print out is put in the right order.

All I want to be able to do is when my Waiters click print bill the System works out how many mains have been sold and if its greater than 2 execute a print job that prints a free meal voucher for the next day.

Ive tried so far {ITEM TAG:MAIN} Greater than 2 as explained this does not trigger the rule.

Ive Tried {ITEM TAG TOTAL:MAIN} Greater than 2 this also doesnt trigger the rule.

I do not understand the report expression method that JTRTech mentioned.

Am I running along the right lines or is what i want a rather complicated process.



Tried where?

Remember if its on print bill waiter may print bill multiple times for multiple vouchers - hence suggestion of ticket closing.

The report expression used would likely be {TICKET QUANTITY TOTAL EXP:X}



Change MT.Course (corse part) to whatever your custom menu item tag is called.

1 Like

Hi Ive tried this on the Print Bill Function the way I use Sambapos this isnt a problem for me.

However Ive Tried this in the custom constraint section.

what am i doing wrong as this still isnt working.

My Order Tag Group is called “Course Tags”

Thanks for your help


Greater than 2 would be 3 or more not 2 you know right? Just you said 2 or more mains before…

Ok So I have changed it to Greater than 1 but it still prints nothing am I entering the expression in the right place.

Wrap it in a TN()


Just so you can see the example order im using as you can see both lines are tagged with Main.

So Thankful for your help

Ill try wrapping it in TN now and get back to you.


How are you applying the tag?
MT refers to custom product tag (the columns on the product tag editor/fields under portions of product page)

They are in a Order Tag and when the item is selected it runs an automation to tag the order with the relevant title.

Show how?
As I said MT is not order tag its product/menu item tag…

Your selecting manually?

If only using order tag try changing to OTC.

ill give it a go

The Automation Commands are using Tag Order Actions

I do similar but use product tags and states (states dont show unless defined and user doesnt generally need to see the course…

Using OTC. might work for your setup.

Arghhh no OTC doesnt work either any more ideas??



Show how you used?

This is my equivilent using states for free drink on next visit offer when ordering a main over £10;

[=TN('{TICKET ORDER QUANTITY TOTAL EXP:(OS.Kitchen Course=Mains) && O.Price>9.95}')] > 0