{
	"name": "form/nc/erp-sync/4d/column/order-sales-report.json",
	"report": [
		{
			"name": "Sales by company",
			"paper_type": "A4 landscape",
			"null_allowed-": ["pr.calc.stock_balance", "pr.calc.average_unit_price", "pr.calc.error"],
			"subtotal": {
				"total": {
					"calculate": [["pr.calc.stock_value", "+"]]
				},
				"subtotal": [
					{
						"field": "ord.company_id",
						"sort_direction": ">",
						"calculate": [["ordr.price_without_vat", "+"]],
						"page_break": false
					},
					{
						"field": "pr.product_group",
						"sort_direction": ">",
						"calculate": [["pr.calc.stock_value", "+"]],
						"page_break": false
					},
					{
						"field": "pr.product_id",
						"sort_direction": ">"
					}
				],
				"order": [{ "field": "pr.product_id", "sort_direction": ">" }]
			}
		},
		{
			"name": "Sales by product group",
			"paper_type": "A4 landscape",
			"null_allowed-": ["pr.calc.stock_balance", "pr.calc.average_unit_price", "pr.calc.error"],
			"subtotal": {
				"total": {
					"calculate": [["pr.calc.stock_value", "+"]]
				},
				"subtotal": [
					{
						"field": "pr.product_group",
						"sort_direction": ">",
						"calculate": [["pr.calc.stock_value", "+"]],
						"page_break": false
					},
					{
						"field": "ord.company_id",
						"sort_direction": ">"
					}
				],
				"order": [{ "field": "pr.product_id", "sort_direction": ">" }]
			}
		}
	]
}
