Edit Report:Pick Slip + Invoices by Day
Menu Anchors
'customers', 'orders', 'sales', 'payables', 'warehouse', 'dispatching', 'receivables', 'payables-dash', 'inventory', 'purchases', 'generallendger', 'users',-- Pick Slip + Invoices by Day
-- PLACE HOLDER REPORT DESCRIPTION
-- PLACE HOLDER REPORT FILTERS AND DRILL DOWN
-- VARIABLE: {
-- name: "range",
-- display: "Report Range",
-- type: "daterange",
-- default: { start: "first day of last month", end: "yesterday" }
-- }
-- VARIABLE: {
-- name: "salesperson",
-- display: "SalesPerson Number",
-- type: "text",
-- }
-- ROLLUP: {
-- columns: {
-- "Invoice Total": "Invoice Total: {{sum}}"
-- }
-- }
-- FILTER: {
-- column: "DEBTORNO",
-- filter: "drilldown",
-- params: {
-- macros: { "debtorno": { column: "DEBTORNO" } },
-- report: "drilldown/customer-invoices.sql"
-- }
-- }
-- ignore
SELECT
DATE(trandate) AS 'Date',
DAYNAME(trandate) AS 'Day',
loccode,
count( distinct orderno ) AS 'Invoice Total'
FROM
stocktrans
WHERE
trandate BETWEEN '{{ range.start }}' AND '{{ range.end }}'
AND loccode = '00'
and type = 10
GROUP BY
DATE(trandate)
ORDER BY
trandate asc