Custom report for sales

This is for order items report, i want to do sales items report, how to change?

Sorry, what do you want to report?

This Script is for order items report, i want to sales items report, how to change?
I view Custom Report Tags in detail
not see ā€œREPORT SALES DETAILSā€ tagsā€¦

So what would you say needs to be included in Sales? I ask this because SambaPOS doesnt save sales anywhere you have to generate your own Sales reports.

You would probably use REPORT ORDER DETAILS but you need to specify report expressions to suite your reporting needs.
The default v5 report uses REPORT TICKET TYPES
{REPORT TICKET TYPES:!PreOrder && TotalAmount >= 0}
Although am not sure on the parameters of this tag as must hard coded ignore void etc. well it would as is going to be based on ticket totalsā€¦

Likewise for the order group sumary; (v5 sourced)
{REPORT ORDER DETAILS:O.ItemGroup,O.ExactTotal.Percent,O.ExactTotal.Sum}

You need to understand your order states in your system to accurately get what you want.
Ie submitted orders would include void as void orders are submitted with gift state of void.

Item sales report specifies ODI=True which is order decrease inventory I believe but again this would depend on your refund and void setup etc.

Explain what you want and can offer advice but ā€˜Sales Reportā€™ is a broad term and any custom config could influence the outcome of a report.

What you suggested seems more like item sales than salesā€¦
Default V5 item sales report is;

[Sales:5, 2, 2,1]
@{REPORT ORDER DETAILS:O.MenuItemName,O.ExactTotal.Sum.desc:(ODI=True):{0}:,}
{REPORT ORDER DETAILS:O.MenuItemName,O.Quantity.Sum.desc,O.ExactTotal.Sum.desc:(ODI=True) and O.MenuItemName="$1"}
{REPORT ORDER DETAILS:'     '+[O.PortionName],O.Quantity.Sum.desc,O.ExactTotal.Sum.desc:(ODI=True) and O.MenuItemName="$1":2}
1 Like

Most sales comes from REPORT TICKET DETAILS tag