Pop-up button to print invoice YES or NO

Hello community, it is possible that when registering the payment of a table (cash, Voucher, or Card), before sending to print, ask the cashier if they want to print YES or NO.

If the cashier indicates NO, release the table.
If the cashier indicates YES, print the ticket and release the table.

I look forward to your support and guidance to achieve this functionality, the idea is to save paper, but also if you need to give the option to print the invoice, no matter if the account was previously printed.

Yes, in your Payment Processed rule you would put an Ask Question action.

And then you would execute print bill rule with the constraint Match All

Automation Command EQUALS Print Bill
[:CommandValue] EQUALS Yes

-Create action
-Name: Print Receipt
-Type of action: Ask a question
-Parameters same as picture
-Locate rule, Before closing ticket
-Add the action Print receipt
-Follow the steps in the image
ready, that worked for me, I hope it helps.

Now create an automation command executed rule for that command. But you didnt set a command name in the action so it wont work yet.

Set a command name then createa rule for that command name and use a constraint for Command Value = Print Bill and then make it execute that print bill action

You do not have to do anything if No is pressed it will not execute the rule if you do the constraint correctly.

Thank you very much @Posflow , I will do the process you indicate.

Thank you very much @DavidGM, all comments from the community that help, very grateful.

1 Like

Thank you very much @Jesse , I will review what you kindly tell us. Thank you community for your support.

I am testing the suggestion that you kindly shared, it works very well at checkout. Print the invoice when you say yes, and release the table without printing the ticket when I give you NO. Excellent!!

Now I have the detail when I want to print the ticket directly from the window where the products are, it ran out of the action of printing, I click it and nothing happens, it does not print the ticket.

So to be able to print in the ticket window I thought of predetermining the value “Yes” in the automation command to print Invoice; This to comply with the code and it works very well, it prints the ticket, but it does not send me to the tables window, and it leaves me the ticket empty as shown in the following image:

Comment: The order is never lost, when choosing from the table map the order is correct.
My question would be how once the ticket is printed, it returns me to the table map as SambaPOS normally works.

For your great support of all very grateful.

Thats why in my example I had a clone of the action called AMC Print Bill as to not replace the default Print Bill button.

Is your department set as Create Ticket or Select Entity?

Ahh ok, then I will try to make a clone so as not to alter the rest.

It is configured as Create Ticket

Choose Select Entity instead, log out and try and see if that works for you better

Thanks @Posflow, I will try to do what you tell me.

Thank you all, for your comments, each one helped me to solve. I achieved the desired functionality.
He shared on how my configuration finally looks:

1.- First I cloned the automation command “Print Invoice” as “AMC Print Invoice”. Since this command would be useful when registering the Payment, the visibility was defined only in “Payments” as shown in the image, for the unpaid states, Isclosed.

2 -.- Therefore, edit the original automation command and it was only visible for tickets and with statuses of new orders and not paid, as shown in the image. This allowed me to separate the Print Invoice command and the cloned AMC Print Invoice command.

3.- Next, an action called “Print Ticket” was created with the action type “Ask a question” and the parameters that are shown, including Automation Command Name: AMC Print Invoice created previously.

4.- A rule “AMC Print Invoice Rule” is created, in my case I cloned the rule “Print Invoice Rule” and the parameters shown in the image were changed.

5.- Finally, the action “Print Ticket” performed in step 3, within the Rule “Verify Ticket Payment” is added.

Hope it serves someone and reduces the learning curve. Again I thank everyone and I only share my experience.