Group products to get a small Printed Ticket

Hello everyone,

I have a question about grouping products, let’s say that I have the following ticket been printed:

I would like this ticket to be short by grouping products as follow:

Notice that in this case I want Coffee (1$), Juice (1$) and Coke (1$) values added together as Beverages to show their added value (3$), the same for the restaurant and bar group products, then beverages, restaurant and bar groups are added together to show the grand total.

The problem is that the paper I will be printing the tickets is not too long so if I need to group the products to print them as one invoice in a short format.

I have read tutorial to group products as drinks, main courses, desserts, etc. But in my case I want to get their costs added to get a total amount price for each group and later the grand total. Can this be accomplished? Any help will be appreciated.

Hmmmm, interesting question, pretty sure it could be done with script but dont think the built in printer template tags will allow this, is more of a report that a ticket template.

1 Like

Simple… See how I defined grouping by product group. I’ve disabled [ORDERS] section by commenting it but added a single char (-) at the end not to entirely disable it.

A little more fine tuning will probably needed but I think you’ll get the idea. You can also define your custom grouping instead of product groups by using custom product tags.

You can read more about it here…

http://www.sambapos.org/en/content/grouping-ticket-printer-template

Here is my full template

[LAYOUT]
-- General layout
<T>Ticket
<L00>Date:{TICKET DATE}
<L00>Time:{TIME}
{ENTITIES}
<L00>Ticket No:{TICKET NO}
<F>-
{ORDERS}
<F>=
<EB>
{DISCOUNTS}
[<J10>Total Gift:|{ORDER STATE TOTAL:Gift}]
{SERVICES}
<J10>Total:|{TICKET TOTAL}
{PAYMENTS}
<DB>
<F>=
<C10>T H A N K   Y O U

[DISCOUNTS]
<J00>{CALCULATION NAME} %{CALCULATION AMOUNT}|{CALCULATION TOTAL}

[SERVICES]
<J00>{CALCULATION NAME}|{CALCULATION TOTAL}

[PAYMENTS]
<J00>{PAYMENT NAME}|{PAYMENT AMOUNT}

[ORDERS GROUP|PRODUCT GROUP]
<J>- {QUANTITY SUM} {GROUP KEY} |{GROUP SUM}

[ORDERS]
-- Default format for orders
-- <J00>- {QUANTITY} {NAME}|{TOTAL PRICE}
-- {ORDER TAGS}
-

[ORDERS:Gift]
-- Format for gifted orders
<J00>- {QUANTITY} {NAME}|**GIFT**
{ORDER TAGS}

[ORDERS:Void]
-- Nothing will print for void lines

[ORDER TAGS]
-- Format for order tags
<J00> * {ORDER TAG NAME} | {ORDER TAG PRICE}

[ENTITIES:Table]
-- Table entity format
<L00>Table: {ENTITY NAME}

[ENTITIES:Customer]
-- Customer entity format
<J00>Customer: {ENTITY NAME} | {ENTITY DATA:Phone}
2 Likes

Thanks @emre this is just what i needed, at the beginning I got nothing show in the ticket but then I took – out of {ORDER TAGS} at the end of [ORDERS] and everything worked fine, thanks a lot for your time!