Custom tip report calculation

this seems like a good addition, i came up with this, but not quite getting the whole thing together, as this is for just one waitress, i use the all command or the Waitress group to pull all the users in that user role but not quite sure how to

[Server Sales Details: 3,2,3,2,2]
Date:|{DATE}
@Madona Nunez

Server:|$1
TOTAL:|||$[=TN(’{REPORT PAYMENT TOTAL:(TU=$1)}’)-TN(’{REPORT CALCULATION TOTAL:(CT=Tip) AND (TU=$1)}’)]
Tip:|||${REPORT CALCULATION TOTAL:(CT=Tip)AND (TU=$1)}

[Tickets:1,1,1,1,1,]
@Madona Nunez

Server:|$1
Ticket|Date|Time|Total|Tip|
{REPORT PAYMENT DETAILS:T.TicketNumber,T.Date,P.Time,[T.TotalAmount]-[CA.Tip],CA.Tip:(TS.Status=Paid) AND (TU=Ticket) AND (TU=$1)}

You can test your report table side by making a manual comma separated list of users where you currently just have the one name.

For the list report expression check whats on the work period report, that has a list of user sales/payments so see what expression it has used.
Expect its some something like report ticket details with ticket user as first field, ticket total.sum as second then a formatting expression after the colon : to only show first field and separate with comma.

Here is something to set started;

@{REPORT PAYMENT DETAILS:P.User,P.Amount.Sum::{0}:,}

Payments might not be correct report to use as a user might take payment but not be ticket user so mismatch/miss a user if they didn’t take anynor only took payments.
Try and use the same report report type your using in the other part to be sure the user list matches those needed given the scenario mentioned above.

ok i see how to pull the users,

but not really good a coding this , not getting anything on the tickets any ideas?

Cant see your report constraints on the ticket details, looking at the output guessing you don’t have a $1 in it which is why its not repeating, unless it doesn’t like having the headers between the staff name and ticket details…
Also take out the spaces before/after the names, just leave the middle, they need to be the EXACT user names…
Also your using payments, didn’t you change to ticket details on the other topic?

yes, just did the space and ticket corrections, but still no ticket details

[Server Sales Details: 3,2,3,2,2]
Date:|{DATE}
@Alex,Madona Nunez,Yanci Gutierrez,

Server:|$1
TOTAL:|||$[=TN(’{REPORT PAYMENT TOTAL:(TU=$1)}’)-TN(’{REPORT CALCULATION TOTAL:(CT=Tip) AND (TU=$1)}’)]
Tip:|||${REPORT CALCULATION TOTAL:(CT=Tip)AND (TU=$1)}

[Tickets:1,1,1,1,1,]
@Alex,Madona Nunez,Yanci Gutierrez,

Server:|$1
Ticket|Date|Time|Total|Tip|
{REPORT TICKET DETAILS:T.TicketNumber,T.Date,P.Time,[T.TotalAmount]-[CA.Tip],CA.Tip:(TS.Status=Paid) AND (TU=Ticket) AND (TU=$1)}

Try taking out the headers temporarily.

Also see this bit, its also showing 0 on the other so think the extra spaces are effecting…

[Server Sales Details: 3,2,3,2,2]
Date:|{DATE}
@Alex,Madona Nunez,Yanci Gutierrez,

Server:|$1
TOTAL:|||$[=TN('{REPORT PAYMENT TOTAL:(TU=$1)}')-TN('{REPORT CALCULATION TOTAL:(CT=Tip) AND (TU=$1)}')]
Tip:|||${REPORT CALCULATION TOTAL:(CT=Tip)AND (TU=$1)}
[Tickets:1,1,1,1,1,]
@Alex,Madona Nunez,Yanci Gutierrez,
Server:|$1
{REPORT TICKET DETAILS:T.TicketNumber,T.Date,P.Time,[T.TotalAmount]-[CA.Tip],CA.Tip:(TS.Status=Paid) AND (TU=Ticket) AND (TU=$1)}

no that server is not working today

Arrrr. hold on…
Whats this?

(TS.Status=Paid) AND (TU=Ticket) AND (TU=$1)

(TU=Ticket)???

That will probably be your problem…

[Server Sales Details: 3,2,3,2,2]
Date:|{DATE}
@Alex,Madona Nunez,Yanci Gutierrez,

Server:|$1
TOTAL:|||$[=TN('{REPORT PAYMENT TOTAL:(TU=$1)}')-TN('{REPORT CALCULATION TOTAL:(CT=Tip) AND (TU=$1)}')]
Tip:|||${REPORT CALCULATION TOTAL:(CT=Tip)AND (TU=$1)}
[Tickets:1,1,1,1,1,]
@Alex,Madona Nunez,Yanci Gutierrez,
Server:|$1
Ticket|Date|Time|Total|Tip|
{REPORT TICKET DETAILS:T.TicketNumber,T.Date,P.Time,[T.TotalAmount]-[CA.Tip],CA.Tip:(TS.Status=Paid) AND (TU=$1)}

removed that section see below but still not quite there

[Server Sales Details: 3,2,3,2,2]
Date:|{DATE}
@Alex,Madona Nunez,Yanci Gutierrez,

Server:|$1
TOTAL:|||$[=TN(’{REPORT PAYMENT TOTAL:(TU=$1)}’)-TN(’{REPORT CALCULATION TOTAL:(CT=Tip) AND (TU=$1)}’)]
Tip:|||${REPORT CALCULATION TOTAL:(CT=Tip)AND (TU=$1)}

[Tickets:1,1,1,1,1,]
@Alex,Madona Nunez,Yanci Gutierrez,

Server:|$1
Ticket|Date|Time|Total|Tip|
{REPORT TICKET DETAILS:T.TicketNumber,T.Date,P.Time,[T.TotalAmount]-[CA.Tip],CA.Tip:(TS.Status=Paid) AND (TU=$1)}

Ok, but I notice removing the spaces now shows sales for Yanci Gutierrez :stuck_out_tongue:

Try without the
Ticket|Date|Time|Total|Tip|
Line…
Think maybe that there is no $1 in this line it might be stopping the loop…

aaahhh there you go!!!
well once again thank you sr!

I tried in this way but i got nothing

You make sure there wasn’t the tu=ticket part in there corrected further up.

It’s hard to have an idea of an issue when cant see your report template/expressions … Half is out of view, paste your report on forum.
Don’t forget to select and click the code button on post toolbar to keep clean format.

There is defiantly sales with tips in the current work period right?

This is my code bro!


[Server Sales Details: 3,2,3,2,2]
Date:|{DATE}
@Cynthia,Gunther,Jonathan,Nilza,Katherine,Mathias,Maria José,Fernanda,Cristian,Sebastian,Carlos,

Garzon:|$1
TOTAL:|||$[=TN(’{REPORT PAYMENT TOTAL:(TU=$1)}’)-TN(’{REPORT CALCULATION TOTAL:(CT=Propina Sugerida) AND (TU=$1)}’)]
Propina Sugerida:|||${REPORT CALCULATION TOTAL:(CT=Propina Sugerida)AND (TU=$1)}
Propina Manual:|||${REPORT CALCULATION TOTAL:(CT=Propina Manual)AND (TU=$1)}

[Tickets:1,1,1,1,1,]
@Cynthia,Gunther,Jonathan,Nilza,Katherine,Mathias,Maria José,Fernanda,Cristian,Sebastian,Carlos,

Garzon:|$1
{REPORT TICKET DETAILS:T.TicketNumber,T.Date,P.Time,[T.TotalAmount]-[CA.Propina Sugerida],CA.Propina Sugerida:(TS.Status=Paid) AND (TU=$1)}

You defiantly have sales in you current work period for the listed users right?

Are users names and the calculation name exactly the same, case sensitive etc?

Yes because in the first part there are data, but isn’t in the second part, please take a look:

127/5000

I have it, it was just a language problem, in this part: (TS.Status = Paid) … in Spanish it is (TS.Estado = Paid)
Thank you very much.

Works Perfect… :slight_smile:

Instead of hardcoding @Cynthia,Gunther,Jonathan… etc. you can try using a report tag to get a list of users.

For example you can replace user list with

@{REPORT TICKET DETAILS:T.User.asc}
1 Like

This report tag does not work, I still have to hardcode the list and add or remove waiters as we change staff.

If it doesn’t work it’s more likely something in your setup/system as I pretty sure that is in the default work period report… So does your work period report not work?