[IMP] pos,website(_sale): link sale.report to pos.order
It's currently not possible to know which `pos.order` is linked to a `sale.report` Solution: Add a field `order_reference` on model `sale.report`. This field refers to either a "sale.order" or a "pos.order" record. The field `order_reference` is used to count the number of distinct orders. We cannot simply use count_distinct on the `order_id` because there can be multiple sale.report with the same `order_id` but related to different models (sale or POS order). Part-of: odoo/odoo#116830
This commit is contained in:
@@ -10,18 +10,18 @@ class SaleReport(models.Model):
|
||||
@api.model
|
||||
def _get_done_states(self):
|
||||
done_states = super()._get_done_states()
|
||||
done_states.extend(['paid', 'pos_done', 'invoiced'])
|
||||
done_states.extend(['paid', 'invoiced'])
|
||||
return done_states
|
||||
|
||||
state = fields.Selection(
|
||||
selection_add=[
|
||||
('pos_draft', 'New'),
|
||||
('paid', 'Paid'),
|
||||
('pos_done', 'Posted'),
|
||||
('invoiced', 'Invoiced')
|
||||
],
|
||||
)
|
||||
|
||||
order_reference = fields.Reference(selection_add=[('pos.order', 'POS Order')])
|
||||
|
||||
def _select_pos(self):
|
||||
select_ = f"""
|
||||
-MIN(l.id) AS id,
|
||||
@@ -51,7 +51,7 @@ class SaleReport(models.Model):
|
||||
count(*) AS nbr,
|
||||
pos.name AS name,
|
||||
pos.date_order AS date,
|
||||
CASE WHEN pos.state = 'draft' THEN 'pos_draft' WHEN pos.state = 'done' THEN 'pos_done' else pos.state END AS state,
|
||||
pos.state AS state,
|
||||
NULL as invoice_status,
|
||||
pos.partner_id AS partner_id,
|
||||
pos.user_id AS user_id,
|
||||
@@ -76,7 +76,7 @@ class SaleReport(models.Model):
|
||||
/ {self._case_value_or_one('pos.currency_rate')}
|
||||
/ {self._case_value_or_one('currency_table.rate')}))
|
||||
AS discount_amount,
|
||||
NULL AS order_id"""
|
||||
concat('pos.order', ',', pos.id) AS order_reference"""
|
||||
|
||||
additional_fields = self._select_additional_fields()
|
||||
additional_fields_info = self._fill_pos_fields(additional_fields)
|
||||
@@ -126,6 +126,7 @@ class SaleReport(models.Model):
|
||||
l.qty,
|
||||
t.uom_id,
|
||||
t.categ_id,
|
||||
pos.id,
|
||||
pos.name,
|
||||
pos.date_order,
|
||||
pos.partner_id,
|
||||
|
||||
@@ -130,7 +130,7 @@ class CrmTeam(models.Model):
|
||||
|
||||
def _extra_sql_conditions(self):
|
||||
if self._in_sale_scope():
|
||||
return "AND state in ('sale', 'done', 'pos_done')"
|
||||
return "AND state in ('sale', 'done')"
|
||||
return super()._extra_sql_conditions()
|
||||
|
||||
def _graph_title_and_key(self):
|
||||
|
||||
@@ -56,7 +56,7 @@ class SaleReport(models.Model):
|
||||
state_id = fields.Many2one(comodel_name='res.country.state', string="Customer State", readonly=True)
|
||||
|
||||
# sale.order.line fields
|
||||
order_id = fields.Many2one(comodel_name='sale.order', string="Order #", readonly=True)
|
||||
order_reference = fields.Reference(string='Related Order', selection=[('sale.order', 'Sales Order')], group_operator="count_distinct")
|
||||
|
||||
categ_id = fields.Many2one(
|
||||
comodel_name='product.category', string="Product Category", readonly=True)
|
||||
@@ -151,7 +151,7 @@ class SaleReport(models.Model):
|
||||
/ {self._case_value_or_one('currency_table.rate')}
|
||||
) ELSE 0
|
||||
END AS discount_amount,
|
||||
s.id AS order_id"""
|
||||
concat('sale.order', ',', s.id) AS order_reference"""
|
||||
|
||||
additional_fields_info = self._select_additional_fields()
|
||||
template = """,
|
||||
|
||||
@@ -30,7 +30,7 @@
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Sales Analysis">
|
||||
<field name="date" widget="date"/>
|
||||
<field name="order_id" optional="show"/>
|
||||
<field name="order_reference" optional="show"/>
|
||||
<field name="partner_id" optional="hide"/>
|
||||
<field name="user_id" optional="show" widget="many2one_avatar_user"/>
|
||||
<field name="team_id" optional="show"/>
|
||||
|
||||
@@ -54,7 +54,7 @@ class TestSaleReportCurrencyRate(SaleCommon):
|
||||
|
||||
# the report should show the amount in company currency
|
||||
report_line = self.env['sale.report'].sudo().search(
|
||||
[('order_id', '=', eur_order.id)])
|
||||
[('order_reference', '=', f"sale.order,{eur_order.id}")])
|
||||
self.assertEqual(report_line.price_total, 20.0)
|
||||
|
||||
def test_sale_report_company_currency(self):
|
||||
@@ -78,5 +78,5 @@ class TestSaleReportCurrencyRate(SaleCommon):
|
||||
|
||||
# the report should match the amount on the SO
|
||||
report_line = self.env['sale.report'].sudo().search(
|
||||
[('order_id', '=', usd_order.id)])
|
||||
[('order_reference', '=', f"sale.order,{usd_order.id}")])
|
||||
self.assertEqual(report_line.price_total, 20.0)
|
||||
|
||||
@@ -40,5 +40,5 @@ class CrmTeam(models.Model):
|
||||
|
||||
def _extra_sql_conditions(self):
|
||||
if self.use_opportunities and self._context.get('in_sales_app'):
|
||||
return "AND state in ('sale', 'done', 'pos_done')"
|
||||
return "AND state in ('sale', 'done')"
|
||||
return super(CrmTeam,self)._extra_sql_conditions()
|
||||
|
||||
@@ -129,7 +129,7 @@
|
||||
},
|
||||
"A32": {
|
||||
"style": 1,
|
||||
"content": "[Top Countries](odoo://view/{\"viewType\":\"pivot\",\"action\":{\"domain\":[[\"country_id\",\"!=\",false],[\"state\",\"not in\",[\"draft\",\"sent\",\"cancel\"]]],\"context\":{\"group_by\":[\"country_id\"],\"pivot_measures\":[\"order_id\",\"price_subtotal\"],\"pivot_column_groupby\":[],\"pivot_row_groupby\":[\"country_id\"]},\"modelName\":\"sale.report\",\"views\":[[false,\"graph\"],[false,\"pivot\"],[false,\"search\"]]},\"threshold\":0,\"name\":\"Sales Analysis\"})",
|
||||
"content": "[Top Countries](odoo://view/{\"viewType\":\"pivot\",\"action\":{\"domain\":[[\"country_id\",\"!=\",false],[\"state\",\"not in\",[\"draft\",\"sent\",\"cancel\"]]],\"context\":{\"group_by\":[\"country_id\"],\"pivot_measures\":[\"order_reference\",\"price_subtotal\"],\"pivot_column_groupby\":[],\"pivot_row_groupby\":[\"country_id\"]},\"modelName\":\"sale.report\",\"views\":[[false,\"graph\"],[false,\"pivot\"],[false,\"search\"]]},\"threshold\":0,\"name\":\"Sales Analysis\"})",
|
||||
"border": 1
|
||||
},
|
||||
"A33": {
|
||||
@@ -179,7 +179,7 @@
|
||||
},
|
||||
"A45": {
|
||||
"style": 1,
|
||||
"content": "[Top Customers](odoo://view/{\"viewType\":\"pivot\",\"action\":{\"domain\":[[\"partner_id\",\"!=\",false],[\"state\",\"not in\",[\"draft\",\"sent\",\"cancel\"]]],\"context\":{\"group_by\":[\"partner_id\"],\"pivot_measures\":[\"order_id\",\"price_subtotal\"],\"pivot_column_groupby\":[],\"pivot_row_groupby\":[\"partner_id\"]},\"modelName\":\"sale.report\",\"views\":[[false,\"graph\"],[false,\"pivot\"],[false,\"search\"]]},\"threshold\":0,\"name\":\"Sales Analysis\"})",
|
||||
"content": "[Top Customers](odoo://view/{\"viewType\":\"pivot\",\"action\":{\"domain\":[[\"partner_id\",\"!=\",false],[\"state\",\"not in\",[\"draft\",\"sent\",\"cancel\"]]],\"context\":{\"group_by\":[\"partner_id\"],\"pivot_measures\":[\"order_reference\",\"price_subtotal\"],\"pivot_column_groupby\":[],\"pivot_row_groupby\":[\"partner_id\"]},\"modelName\":\"sale.report\",\"views\":[[false,\"graph\"],[false,\"pivot\"],[false,\"search\"]]},\"threshold\":0,\"name\":\"Sales Analysis\"})",
|
||||
"border": 1
|
||||
},
|
||||
"A46": {
|
||||
@@ -229,7 +229,7 @@
|
||||
},
|
||||
"A58": {
|
||||
"style": 1,
|
||||
"content": "[Top Sales Teams](odoo://view/{\"viewType\":\"pivot\",\"action\":{\"domain\":[[\"team_id\",\"!=\",false],[\"state\",\"not in\",[\"draft\",\"sent\",\"cancel\"]]],\"context\":{\"group_by\":[\"team_id\"],\"pivot_measures\":[\"order_id\",\"price_subtotal\"],\"pivot_column_groupby\":[],\"pivot_row_groupby\":[\"team_id\"]},\"modelName\":\"sale.report\",\"views\":[[false,\"graph\"],[false,\"pivot\"],[false,\"search\"]]},\"threshold\":0,\"name\":\"Sales Analysis\"})",
|
||||
"content": "[Top Sales Teams](odoo://view/{\"viewType\":\"pivot\",\"action\":{\"domain\":[[\"team_id\",\"!=\",false],[\"state\",\"not in\",[\"draft\",\"sent\",\"cancel\"]]],\"context\":{\"group_by\":[\"team_id\"],\"pivot_measures\":[\"order_reference\",\"price_subtotal\"],\"pivot_column_groupby\":[],\"pivot_row_groupby\":[\"team_id\"]},\"modelName\":\"sale.report\",\"views\":[[false,\"graph\"],[false,\"pivot\"],[false,\"search\"]]},\"threshold\":0,\"name\":\"Sales Analysis\"})",
|
||||
"border": 1
|
||||
},
|
||||
"A59": {
|
||||
@@ -279,7 +279,7 @@
|
||||
},
|
||||
"A71": {
|
||||
"style": 1,
|
||||
"content": "[Top Sources](odoo://view/{\"viewType\":\"pivot\",\"action\":{\"domain\":[[\"source_id\",\"!=\",false],[\"state\",\"not in\",[\"draft\",\"sent\",\"cancel\"]]],\"context\":{\"group_by\":[\"source_id\"],\"pivot_measures\":[\"order_id\",\"price_subtotal\"],\"pivot_column_groupby\":[],\"pivot_row_groupby\":[\"source_id\"]},\"modelName\":\"sale.report\",\"views\":[[false,\"graph\"],[false,\"pivot\"],[false,\"search\"]]},\"threshold\":0,\"name\":\"Sales Analysis\"})",
|
||||
"content": "[Top Sources](odoo://view/{\"viewType\":\"pivot\",\"action\":{\"domain\":[[\"source_id\",\"!=\",false],[\"state\",\"not in\",[\"draft\",\"sent\",\"cancel\"]]],\"context\":{\"group_by\":[\"source_id\"],\"pivot_measures\":[\"order_reference\",\"price_subtotal\"],\"pivot_column_groupby\":[],\"pivot_row_groupby\":[\"source_id\"]},\"modelName\":\"sale.report\",\"views\":[[false,\"graph\"],[false,\"pivot\"],[false,\"search\"]]},\"threshold\":0,\"name\":\"Sales Analysis\"})",
|
||||
"border": 1
|
||||
},
|
||||
"A72": {
|
||||
@@ -519,47 +519,47 @@
|
||||
"C34": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(5,\"order_id\",\"#country_id\",1)"
|
||||
"content": "=ODOO.PIVOT(5,\"order_reference\",\"#country_id\",1)"
|
||||
},
|
||||
"C35": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(5,\"order_id\",\"#country_id\",2)"
|
||||
"content": "=ODOO.PIVOT(5,\"order_reference\",\"#country_id\",2)"
|
||||
},
|
||||
"C36": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(5,\"order_id\",\"#country_id\",3)"
|
||||
"content": "=ODOO.PIVOT(5,\"order_reference\",\"#country_id\",3)"
|
||||
},
|
||||
"C37": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(5,\"order_id\",\"#country_id\",4)"
|
||||
"content": "=ODOO.PIVOT(5,\"order_reference\",\"#country_id\",4)"
|
||||
},
|
||||
"C38": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(5,\"order_id\",\"#country_id\",5)"
|
||||
"content": "=ODOO.PIVOT(5,\"order_reference\",\"#country_id\",5)"
|
||||
},
|
||||
"C39": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(5,\"order_id\",\"#country_id\",6)"
|
||||
"content": "=ODOO.PIVOT(5,\"order_reference\",\"#country_id\",6)"
|
||||
},
|
||||
"C40": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(5,\"order_id\",\"#country_id\",7)"
|
||||
"content": "=ODOO.PIVOT(5,\"order_reference\",\"#country_id\",7)"
|
||||
},
|
||||
"C41": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(5,\"order_id\",\"#country_id\",8)"
|
||||
"content": "=ODOO.PIVOT(5,\"order_reference\",\"#country_id\",8)"
|
||||
},
|
||||
"C42": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(5,\"order_id\",\"#country_id\",9)"
|
||||
"content": "=ODOO.PIVOT(5,\"order_reference\",\"#country_id\",9)"
|
||||
},
|
||||
"C43": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(5,\"order_id\",\"#country_id\",10)"
|
||||
"content": "=ODOO.PIVOT(5,\"order_reference\",\"#country_id\",10)"
|
||||
},
|
||||
"C45": {
|
||||
"style": 8,
|
||||
@@ -572,38 +572,38 @@
|
||||
},
|
||||
"C47": {
|
||||
"style": 9,
|
||||
"content": "=ODOO.PIVOT(4,\"order_id\",\"#partner_id\",1)"
|
||||
"content": "=ODOO.PIVOT(4,\"order_reference\",\"#partner_id\",1)"
|
||||
},
|
||||
"C48": {
|
||||
"content": "=ODOO.PIVOT(4,\"order_id\",\"#partner_id\",2)"
|
||||
"content": "=ODOO.PIVOT(4,\"order_reference\",\"#partner_id\",2)"
|
||||
},
|
||||
"C49": {
|
||||
"style": 9,
|
||||
"content": "=ODOO.PIVOT(4,\"order_id\",\"#partner_id\",3)"
|
||||
"content": "=ODOO.PIVOT(4,\"order_reference\",\"#partner_id\",3)"
|
||||
},
|
||||
"C50": {
|
||||
"content": "=ODOO.PIVOT(4,\"order_id\",\"#partner_id\",4)"
|
||||
"content": "=ODOO.PIVOT(4,\"order_reference\",\"#partner_id\",4)"
|
||||
},
|
||||
"C51": {
|
||||
"style": 9,
|
||||
"content": "=ODOO.PIVOT(4,\"order_id\",\"#partner_id\",5)"
|
||||
"content": "=ODOO.PIVOT(4,\"order_reference\",\"#partner_id\",5)"
|
||||
},
|
||||
"C52": {
|
||||
"content": "=ODOO.PIVOT(4,\"order_id\",\"#partner_id\",6)"
|
||||
"content": "=ODOO.PIVOT(4,\"order_reference\",\"#partner_id\",6)"
|
||||
},
|
||||
"C53": {
|
||||
"style": 9,
|
||||
"content": "=ODOO.PIVOT(4,\"order_id\",\"#partner_id\",7)"
|
||||
"content": "=ODOO.PIVOT(4,\"order_reference\",\"#partner_id\",7)"
|
||||
},
|
||||
"C54": {
|
||||
"content": "=ODOO.PIVOT(4,\"order_id\",\"#partner_id\",8)"
|
||||
"content": "=ODOO.PIVOT(4,\"order_reference\",\"#partner_id\",8)"
|
||||
},
|
||||
"C55": {
|
||||
"style": 9,
|
||||
"content": "=ODOO.PIVOT(4,\"order_id\",\"#partner_id\",9)"
|
||||
"content": "=ODOO.PIVOT(4,\"order_reference\",\"#partner_id\",9)"
|
||||
},
|
||||
"C56": {
|
||||
"content": "=ODOO.PIVOT(4,\"order_id\",\"#partner_id\",10)"
|
||||
"content": "=ODOO.PIVOT(4,\"order_reference\",\"#partner_id\",10)"
|
||||
},
|
||||
"C58": {
|
||||
"style": 8,
|
||||
@@ -617,47 +617,47 @@
|
||||
"C60": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(7,\"order_id\",\"#team_id\",1)"
|
||||
"content": "=ODOO.PIVOT(7,\"order_reference\",\"#team_id\",1)"
|
||||
},
|
||||
"C61": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(7,\"order_id\",\"#team_id\",2)"
|
||||
"content": "=ODOO.PIVOT(7,\"order_reference\",\"#team_id\",2)"
|
||||
},
|
||||
"C62": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(7,\"order_id\",\"#team_id\",3)"
|
||||
"content": "=ODOO.PIVOT(7,\"order_reference\",\"#team_id\",3)"
|
||||
},
|
||||
"C63": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(7,\"order_id\",\"#team_id\",4)"
|
||||
"content": "=ODOO.PIVOT(7,\"order_reference\",\"#team_id\",4)"
|
||||
},
|
||||
"C64": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(7,\"order_id\",\"#team_id\",5)"
|
||||
"content": "=ODOO.PIVOT(7,\"order_reference\",\"#team_id\",5)"
|
||||
},
|
||||
"C65": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(7,\"order_id\",\"#team_id\",6)"
|
||||
"content": "=ODOO.PIVOT(7,\"order_reference\",\"#team_id\",6)"
|
||||
},
|
||||
"C66": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(7,\"order_id\",\"#team_id\",7)"
|
||||
"content": "=ODOO.PIVOT(7,\"order_reference\",\"#team_id\",7)"
|
||||
},
|
||||
"C67": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(7,\"order_id\",\"#team_id\",8)"
|
||||
"content": "=ODOO.PIVOT(7,\"order_reference\",\"#team_id\",8)"
|
||||
},
|
||||
"C68": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(7,\"order_id\",\"#team_id\",9)"
|
||||
"content": "=ODOO.PIVOT(7,\"order_reference\",\"#team_id\",9)"
|
||||
},
|
||||
"C69": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(7,\"order_id\",\"#team_id\",10)"
|
||||
"content": "=ODOO.PIVOT(7,\"order_reference\",\"#team_id\",10)"
|
||||
},
|
||||
"C71": {
|
||||
"style": 8,
|
||||
@@ -671,47 +671,47 @@
|
||||
"C73": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(9,\"order_id\",\"#source_id\",1)"
|
||||
"content": "=ODOO.PIVOT(9,\"order_reference\",\"#source_id\",1)"
|
||||
},
|
||||
"C74": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(9,\"order_id\",\"#source_id\",2)"
|
||||
"content": "=ODOO.PIVOT(9,\"order_reference\",\"#source_id\",2)"
|
||||
},
|
||||
"C75": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(9,\"order_id\",\"#source_id\",3)"
|
||||
"content": "=ODOO.PIVOT(9,\"order_reference\",\"#source_id\",3)"
|
||||
},
|
||||
"C76": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(9,\"order_id\",\"#source_id\",4)"
|
||||
"content": "=ODOO.PIVOT(9,\"order_reference\",\"#source_id\",4)"
|
||||
},
|
||||
"C77": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(9,\"order_id\",\"#source_id\",5)"
|
||||
"content": "=ODOO.PIVOT(9,\"order_reference\",\"#source_id\",5)"
|
||||
},
|
||||
"C78": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(9,\"order_id\",\"#source_id\",6)"
|
||||
"content": "=ODOO.PIVOT(9,\"order_reference\",\"#source_id\",6)"
|
||||
},
|
||||
"C79": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(9,\"order_id\",\"#source_id\",7)"
|
||||
"content": "=ODOO.PIVOT(9,\"order_reference\",\"#source_id\",7)"
|
||||
},
|
||||
"C80": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(9,\"order_id\",\"#source_id\",8)"
|
||||
"content": "=ODOO.PIVOT(9,\"order_reference\",\"#source_id\",8)"
|
||||
},
|
||||
"C81": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(9,\"order_id\",\"#source_id\",9)"
|
||||
"content": "=ODOO.PIVOT(9,\"order_reference\",\"#source_id\",9)"
|
||||
},
|
||||
"C82": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(9,\"order_id\",\"#source_id\",10)"
|
||||
"content": "=ODOO.PIVOT(9,\"order_reference\",\"#source_id\",10)"
|
||||
},
|
||||
"D19": {
|
||||
"style": 8,
|
||||
@@ -988,7 +988,7 @@
|
||||
},
|
||||
"F32": {
|
||||
"style": 1,
|
||||
"content": "[Top Products](odoo://view/{\"viewType\":\"pivot\",\"action\":{\"domain\":[[\"product_tmpl_id\",\"!=\",false],[\"state\",\"not in\",[\"draft\",\"sent\",\"cancel\"]]],\"context\":{\"group_by\":[\"product_id\"],\"pivot_measures\":[\"order_id\",\"price_subtotal\"],\"pivot_column_groupby\":[],\"pivot_row_groupby\":[\"product_id\"]},\"modelName\":\"sale.report\",\"views\":[[false,\"graph\"],[false,\"pivot\"],[false,\"search\"]]},\"threshold\":0,\"name\":\"Sales Analysis\"})",
|
||||
"content": "[Top Products](odoo://view/{\"viewType\":\"pivot\",\"action\":{\"domain\":[[\"product_tmpl_id\",\"!=\",false],[\"state\",\"not in\",[\"draft\",\"sent\",\"cancel\"]]],\"context\":{\"group_by\":[\"product_id\"],\"pivot_measures\":[\"order_reference\",\"price_subtotal\"],\"pivot_column_groupby\":[],\"pivot_row_groupby\":[\"product_id\"]},\"modelName\":\"sale.report\",\"views\":[[false,\"graph\"],[false,\"pivot\"],[false,\"search\"]]},\"threshold\":0,\"name\":\"Sales Analysis\"})",
|
||||
"border": 1
|
||||
},
|
||||
"F33": {
|
||||
@@ -1038,7 +1038,7 @@
|
||||
},
|
||||
"F45": {
|
||||
"style": 1,
|
||||
"content": "[Top Categories](odoo://view/{\"viewType\":\"pivot\",\"action\":{\"domain\":[[\"categ_id\",\"!=\",false],[\"state\",\"not in\",[\"draft\",\"sent\",\"cancel\"]]],\"context\":{\"group_by\":[\"categ_id\"],\"pivot_measures\":[\"order_id\",\"price_subtotal\"],\"pivot_column_groupby\":[],\"pivot_row_groupby\":[\"categ_id\"]},\"modelName\":\"sale.report\",\"views\":[[false,\"graph\"],[false,\"pivot\"],[false,\"search\"]]},\"threshold\":0,\"name\":\"Sales Analysis\"})",
|
||||
"content": "[Top Categories](odoo://view/{\"viewType\":\"pivot\",\"action\":{\"domain\":[[\"categ_id\",\"!=\",false],[\"state\",\"not in\",[\"draft\",\"sent\",\"cancel\"]]],\"context\":{\"group_by\":[\"categ_id\"],\"pivot_measures\":[\"order_reference\",\"price_subtotal\"],\"pivot_column_groupby\":[],\"pivot_row_groupby\":[\"categ_id\"]},\"modelName\":\"sale.report\",\"views\":[[false,\"graph\"],[false,\"pivot\"],[false,\"search\"]]},\"threshold\":0,\"name\":\"Sales Analysis\"})",
|
||||
"border": 1
|
||||
},
|
||||
"F46": {
|
||||
@@ -1088,7 +1088,7 @@
|
||||
},
|
||||
"F58": {
|
||||
"style": 1,
|
||||
"content": "[Top Salespeople](odoo://view/{\"viewType\":\"pivot\",\"action\":{\"domain\":[[\"user_id\",\"!=\",false],[\"state\",\"not in\",[\"draft\",\"sent\",\"cancel\"]]],\"context\":{\"group_by\":[\"user_id\"],\"pivot_measures\":[\"order_id\",\"price_subtotal\"],\"pivot_column_groupby\":[],\"pivot_row_groupby\":[\"user_id\"]},\"modelName\":\"sale.report\",\"views\":[[false,\"graph\"],[false,\"pivot\"],[false,\"search\"]]},\"threshold\":0,\"name\":\"Sales Analysis\"})",
|
||||
"content": "[Top Salespeople](odoo://view/{\"viewType\":\"pivot\",\"action\":{\"domain\":[[\"user_id\",\"!=\",false],[\"state\",\"not in\",[\"draft\",\"sent\",\"cancel\"]]],\"context\":{\"group_by\":[\"user_id\"],\"pivot_measures\":[\"order_reference\",\"price_subtotal\"],\"pivot_column_groupby\":[],\"pivot_row_groupby\":[\"user_id\"]},\"modelName\":\"sale.report\",\"views\":[[false,\"graph\"],[false,\"pivot\"],[false,\"search\"]]},\"threshold\":0,\"name\":\"Sales Analysis\"})",
|
||||
"border": 1
|
||||
},
|
||||
"F59": {
|
||||
@@ -1138,7 +1138,7 @@
|
||||
},
|
||||
"F71": {
|
||||
"style": 1,
|
||||
"content": "[Top Mediums](odoo://view/{\"viewType\":\"pivot\",\"action\":{\"domain\":[[\"medium_id\",\"!=\",false],[\"state\",\"not in\",[\"draft\",\"sent\",\"cancel\"]]],\"context\":{\"group_by\":[\"medium_id\"],\"pivot_measures\":[\"order_id\",\"price_subtotal\"],\"pivot_column_groupby\":[],\"pivot_row_groupby\":[\"medium_id\"]},\"modelName\":\"sale.report\",\"views\":[[false,\"graph\"],[false,\"pivot\"],[false,\"search\"]]},\"threshold\":0,\"name\":\"Sales Analysis\"})",
|
||||
"content": "[Top Mediums](odoo://view/{\"viewType\":\"pivot\",\"action\":{\"domain\":[[\"medium_id\",\"!=\",false],[\"state\",\"not in\",[\"draft\",\"sent\",\"cancel\"]]],\"context\":{\"group_by\":[\"medium_id\"],\"pivot_measures\":[\"order_reference\",\"price_subtotal\"],\"pivot_column_groupby\":[],\"pivot_row_groupby\":[\"medium_id\"]},\"modelName\":\"sale.report\",\"views\":[[false,\"graph\"],[false,\"pivot\"],[false,\"search\"]]},\"threshold\":0,\"name\":\"Sales Analysis\"})",
|
||||
"border": 1
|
||||
},
|
||||
"F72": {
|
||||
@@ -1378,47 +1378,47 @@
|
||||
"H34": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(6,\"order_id\",\"#product_id\",1)"
|
||||
"content": "=ODOO.PIVOT(6,\"order_reference\",\"#product_id\",1)"
|
||||
},
|
||||
"H35": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(6,\"order_id\",\"#product_id\",2)"
|
||||
"content": "=ODOO.PIVOT(6,\"order_reference\",\"#product_id\",2)"
|
||||
},
|
||||
"H36": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(6,\"order_id\",\"#product_id\",3)"
|
||||
"content": "=ODOO.PIVOT(6,\"order_reference\",\"#product_id\",3)"
|
||||
},
|
||||
"H37": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(6,\"order_id\",\"#product_id\",4)"
|
||||
"content": "=ODOO.PIVOT(6,\"order_reference\",\"#product_id\",4)"
|
||||
},
|
||||
"H38": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(6,\"order_id\",\"#product_id\",5)"
|
||||
"content": "=ODOO.PIVOT(6,\"order_reference\",\"#product_id\",5)"
|
||||
},
|
||||
"H39": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(6,\"order_id\",\"#product_id\",6)"
|
||||
"content": "=ODOO.PIVOT(6,\"order_reference\",\"#product_id\",6)"
|
||||
},
|
||||
"H40": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(6,\"order_id\",\"#product_id\",7)"
|
||||
"content": "=ODOO.PIVOT(6,\"order_reference\",\"#product_id\",7)"
|
||||
},
|
||||
"H41": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(6,\"order_id\",\"#product_id\",8)"
|
||||
"content": "=ODOO.PIVOT(6,\"order_reference\",\"#product_id\",8)"
|
||||
},
|
||||
"H42": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(6,\"order_id\",\"#product_id\",9)"
|
||||
"content": "=ODOO.PIVOT(6,\"order_reference\",\"#product_id\",9)"
|
||||
},
|
||||
"H43": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(6,\"order_id\",\"#product_id\",10)"
|
||||
"content": "=ODOO.PIVOT(6,\"order_reference\",\"#product_id\",10)"
|
||||
},
|
||||
"H45": {
|
||||
"style": 8,
|
||||
@@ -1432,47 +1432,47 @@
|
||||
"H47": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(3,\"order_id\",\"#categ_id\",1)"
|
||||
"content": "=ODOO.PIVOT(3,\"order_reference\",\"#categ_id\",1)"
|
||||
},
|
||||
"H48": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(3,\"order_id\",\"#categ_id\",2)"
|
||||
"content": "=ODOO.PIVOT(3,\"order_reference\",\"#categ_id\",2)"
|
||||
},
|
||||
"H49": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(3,\"order_id\",\"#categ_id\",3)"
|
||||
"content": "=ODOO.PIVOT(3,\"order_reference\",\"#categ_id\",3)"
|
||||
},
|
||||
"H50": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(3,\"order_id\",\"#categ_id\",4)"
|
||||
"content": "=ODOO.PIVOT(3,\"order_reference\",\"#categ_id\",4)"
|
||||
},
|
||||
"H51": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(3,\"order_id\",\"#categ_id\",5)"
|
||||
"content": "=ODOO.PIVOT(3,\"order_reference\",\"#categ_id\",5)"
|
||||
},
|
||||
"H52": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(3,\"order_id\",\"#categ_id\",6)"
|
||||
"content": "=ODOO.PIVOT(3,\"order_reference\",\"#categ_id\",6)"
|
||||
},
|
||||
"H53": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(3,\"order_id\",\"#categ_id\",7)"
|
||||
"content": "=ODOO.PIVOT(3,\"order_reference\",\"#categ_id\",7)"
|
||||
},
|
||||
"H54": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(3,\"order_id\",\"#categ_id\",8)"
|
||||
"content": "=ODOO.PIVOT(3,\"order_reference\",\"#categ_id\",8)"
|
||||
},
|
||||
"H55": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(3,\"order_id\",\"#categ_id\",9)"
|
||||
"content": "=ODOO.PIVOT(3,\"order_reference\",\"#categ_id\",9)"
|
||||
},
|
||||
"H56": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(3,\"order_id\",\"#categ_id\",10)"
|
||||
"content": "=ODOO.PIVOT(3,\"order_reference\",\"#categ_id\",10)"
|
||||
},
|
||||
"H58": {
|
||||
"style": 8,
|
||||
@@ -1486,47 +1486,47 @@
|
||||
"H60": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(8,\"order_id\",\"#user_id\",1)"
|
||||
"content": "=ODOO.PIVOT(8,\"order_reference\",\"#user_id\",1)"
|
||||
},
|
||||
"H61": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(8,\"order_id\",\"#user_id\",2)"
|
||||
"content": "=ODOO.PIVOT(8,\"order_reference\",\"#user_id\",2)"
|
||||
},
|
||||
"H62": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(8,\"order_id\",\"#user_id\",3)"
|
||||
"content": "=ODOO.PIVOT(8,\"order_reference\",\"#user_id\",3)"
|
||||
},
|
||||
"H63": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(8,\"order_id\",\"#user_id\",4)"
|
||||
"content": "=ODOO.PIVOT(8,\"order_reference\",\"#user_id\",4)"
|
||||
},
|
||||
"H64": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(8,\"order_id\",\"#user_id\",5)"
|
||||
"content": "=ODOO.PIVOT(8,\"order_reference\",\"#user_id\",5)"
|
||||
},
|
||||
"H65": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(8,\"order_id\",\"#user_id\",6)"
|
||||
"content": "=ODOO.PIVOT(8,\"order_reference\",\"#user_id\",6)"
|
||||
},
|
||||
"H66": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(8,\"order_id\",\"#user_id\",7)"
|
||||
"content": "=ODOO.PIVOT(8,\"order_reference\",\"#user_id\",7)"
|
||||
},
|
||||
"H67": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(8,\"order_id\",\"#user_id\",8)"
|
||||
"content": "=ODOO.PIVOT(8,\"order_reference\",\"#user_id\",8)"
|
||||
},
|
||||
"H68": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(8,\"order_id\",\"#user_id\",9)"
|
||||
"content": "=ODOO.PIVOT(8,\"order_reference\",\"#user_id\",9)"
|
||||
},
|
||||
"H69": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(8,\"order_id\",\"#user_id\",10)"
|
||||
"content": "=ODOO.PIVOT(8,\"order_reference\",\"#user_id\",10)"
|
||||
},
|
||||
"H71": {
|
||||
"style": 8,
|
||||
@@ -1540,47 +1540,47 @@
|
||||
"H73": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(10,\"order_id\",\"#medium_id\",1)"
|
||||
"content": "=ODOO.PIVOT(10,\"order_reference\",\"#medium_id\",1)"
|
||||
},
|
||||
"H74": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(10,\"order_id\",\"#medium_id\",2)"
|
||||
"content": "=ODOO.PIVOT(10,\"order_reference\",\"#medium_id\",2)"
|
||||
},
|
||||
"H75": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(10,\"order_id\",\"#medium_id\",3)"
|
||||
"content": "=ODOO.PIVOT(10,\"order_reference\",\"#medium_id\",3)"
|
||||
},
|
||||
"H76": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(10,\"order_id\",\"#medium_id\",4)"
|
||||
"content": "=ODOO.PIVOT(10,\"order_reference\",\"#medium_id\",4)"
|
||||
},
|
||||
"H77": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(10,\"order_id\",\"#medium_id\",5)"
|
||||
"content": "=ODOO.PIVOT(10,\"order_reference\",\"#medium_id\",5)"
|
||||
},
|
||||
"H78": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(10,\"order_id\",\"#medium_id\",6)"
|
||||
"content": "=ODOO.PIVOT(10,\"order_reference\",\"#medium_id\",6)"
|
||||
},
|
||||
"H79": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(10,\"order_id\",\"#medium_id\",7)"
|
||||
"content": "=ODOO.PIVOT(10,\"order_reference\",\"#medium_id\",7)"
|
||||
},
|
||||
"H80": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(10,\"order_id\",\"#medium_id\",8)"
|
||||
"content": "=ODOO.PIVOT(10,\"order_reference\",\"#medium_id\",8)"
|
||||
},
|
||||
"H81": {
|
||||
"style": 9,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(10,\"order_id\",\"#medium_id\",9)"
|
||||
"content": "=ODOO.PIVOT(10,\"order_reference\",\"#medium_id\",9)"
|
||||
},
|
||||
"H82": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(10,\"order_id\",\"#medium_id\",10)"
|
||||
"content": "=ODOO.PIVOT(10,\"order_reference\",\"#medium_id\",10)"
|
||||
},
|
||||
"I19": {
|
||||
"style": 8,
|
||||
@@ -2390,7 +2390,7 @@
|
||||
"id": "3",
|
||||
"measures": [
|
||||
{
|
||||
"field": "order_id"
|
||||
"field": "order_reference"
|
||||
},
|
||||
{
|
||||
"field": "price_subtotal"
|
||||
@@ -2441,7 +2441,7 @@
|
||||
"id": "4",
|
||||
"measures": [
|
||||
{
|
||||
"field": "order_id"
|
||||
"field": "order_reference"
|
||||
},
|
||||
{
|
||||
"field": "price_subtotal"
|
||||
@@ -2492,7 +2492,7 @@
|
||||
"id": "5",
|
||||
"measures": [
|
||||
{
|
||||
"field": "order_id"
|
||||
"field": "order_reference"
|
||||
},
|
||||
{
|
||||
"field": "price_subtotal"
|
||||
@@ -2543,7 +2543,7 @@
|
||||
"id": "6",
|
||||
"measures": [
|
||||
{
|
||||
"field": "order_id"
|
||||
"field": "order_reference"
|
||||
},
|
||||
{
|
||||
"field": "price_subtotal"
|
||||
@@ -2587,7 +2587,7 @@
|
||||
"id": "7",
|
||||
"measures": [
|
||||
{
|
||||
"field": "order_id"
|
||||
"field": "order_reference"
|
||||
},
|
||||
{
|
||||
"field": "price_subtotal"
|
||||
@@ -2631,7 +2631,7 @@
|
||||
"id": "8",
|
||||
"measures": [
|
||||
{
|
||||
"field": "order_id"
|
||||
"field": "order_reference"
|
||||
},
|
||||
{
|
||||
"field": "price_subtotal"
|
||||
@@ -2675,7 +2675,7 @@
|
||||
"id": "9",
|
||||
"measures": [
|
||||
{
|
||||
"field": "order_id"
|
||||
"field": "order_reference"
|
||||
},
|
||||
{
|
||||
"field": "price_subtotal"
|
||||
@@ -2719,7 +2719,7 @@
|
||||
"id": "10",
|
||||
"measures": [
|
||||
{
|
||||
"field": "order_id"
|
||||
"field": "order_reference"
|
||||
},
|
||||
{
|
||||
"field": "price_subtotal"
|
||||
|
||||
@@ -55,7 +55,7 @@
|
||||
},
|
||||
"A18": {
|
||||
"style": 1,
|
||||
"content": "[Top Products](odoo://view/{\"viewType\":\"pivot\",\"action\":{\"domain\":[\"&\",[\"website_id\",\"!=\",false],[\"state\",\"in\",[\"sale\",\"done\"]]],\"context\":{\"group_by\":[],\"pivot_measures\":[\"order_id\",\"price_total\"],\"pivot_column_groupby\":[],\"pivot_row_groupby\":[\"product_id\"]},\"modelName\":\"sale.report\",\"views\":[[false,\"pivot\"],[false,\"graph\"],[false,\"search\"]]},\"threshold\":0,\"name\":\"Online Sales Analysis\"})",
|
||||
"content": "[Top Products](odoo://view/{\"viewType\":\"pivot\",\"action\":{\"domain\":[\"&\",[\"website_id\",\"!=\",false],[\"state\",\"in\",[\"sale\",\"done\"]]],\"context\":{\"group_by\":[],\"pivot_measures\":[\"order_reference\",\"price_total\"],\"pivot_column_groupby\":[],\"pivot_row_groupby\":[\"product_id\"]},\"modelName\":\"sale.report\",\"views\":[[false,\"pivot\"],[false,\"graph\"],[false,\"search\"]]},\"threshold\":0,\"name\":\"Online Sales Analysis\"})",
|
||||
"border": 1
|
||||
},
|
||||
"A19": {
|
||||
@@ -128,46 +128,46 @@
|
||||
"C20": {
|
||||
"style": 5,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(4,\"order_id\",\"#product_id\",1)"
|
||||
"content": "=ODOO.PIVOT(4,\"order_reference\",\"#product_id\",1)"
|
||||
},
|
||||
"C21": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(4,\"order_id\",\"#product_id\",2)"
|
||||
"content": "=ODOO.PIVOT(4,\"order_reference\",\"#product_id\",2)"
|
||||
},
|
||||
"C22": {
|
||||
"style": 5,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(4,\"order_id\",\"#product_id\",3)"
|
||||
"content": "=ODOO.PIVOT(4,\"order_reference\",\"#product_id\",3)"
|
||||
},
|
||||
"C23": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(4,\"order_id\",\"#product_id\",4)"
|
||||
"content": "=ODOO.PIVOT(4,\"order_reference\",\"#product_id\",4)"
|
||||
},
|
||||
"C24": {
|
||||
"style": 5,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(4,\"order_id\",\"#product_id\",5)"
|
||||
"content": "=ODOO.PIVOT(4,\"order_reference\",\"#product_id\",5)"
|
||||
},
|
||||
"C25": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(4,\"order_id\",\"#product_id\",6)"
|
||||
"content": "=ODOO.PIVOT(4,\"order_reference\",\"#product_id\",6)"
|
||||
},
|
||||
"C26": {
|
||||
"style": 5,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(4,\"order_id\",\"#product_id\",7)"
|
||||
"content": "=ODOO.PIVOT(4,\"order_reference\",\"#product_id\",7)"
|
||||
},
|
||||
"C27": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(4,\"order_id\",\"#product_id\",8)"
|
||||
"content": "=ODOO.PIVOT(4,\"order_reference\",\"#product_id\",8)"
|
||||
},
|
||||
"C28": {
|
||||
"style": 5,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(4,\"order_id\",\"#product_id\",9)"
|
||||
"content": "=ODOO.PIVOT(4,\"order_reference\",\"#product_id\",9)"
|
||||
},
|
||||
"C29": {
|
||||
"content": "=ODOO.PIVOT(4,\"order_id\",\"#product_id\",10)"
|
||||
"content": "=ODOO.PIVOT(4,\"order_reference\",\"#product_id\",10)"
|
||||
},
|
||||
"D19": {
|
||||
"style": 2,
|
||||
@@ -214,7 +214,7 @@
|
||||
},
|
||||
"F18": {
|
||||
"style": 1,
|
||||
"content": "[Top Categories](odoo://view/{\"viewType\":\"pivot\",\"action\":{\"domain\":[[\"state\",\"not in\",[\"draft\",\"cancel\",\"sent\"]]],\"context\":{\"group_by\":[],\"pivot_measures\":[\"order_id\",\"price_subtotal\"],\"pivot_column_groupby\":[],\"pivot_row_groupby\":[\"categ_id\"]},\"modelName\":\"sale.report\",\"views\":[[false,\"graph\"],[false,\"pivot\"],[false,\"search\"]]},\"threshold\":0,\"name\":\"Sales Analysis\"})",
|
||||
"content": "[Top Categories](odoo://view/{\"viewType\":\"pivot\",\"action\":{\"domain\":[[\"state\",\"not in\",[\"draft\",\"cancel\",\"sent\"]]],\"context\":{\"group_by\":[],\"pivot_measures\":[\"order_reference\",\"price_subtotal\"],\"pivot_column_groupby\":[],\"pivot_row_groupby\":[\"categ_id\"]},\"modelName\":\"sale.report\",\"views\":[[false,\"graph\"],[false,\"pivot\"],[false,\"search\"]]},\"threshold\":0,\"name\":\"Sales Analysis\"})",
|
||||
"border": 1
|
||||
},
|
||||
"F19": {
|
||||
@@ -284,43 +284,43 @@
|
||||
"H20": {
|
||||
"style": 5,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(1,\"order_id\",\"#categ_id\",1)"
|
||||
"content": "=ODOO.PIVOT(1,\"order_reference\",\"#categ_id\",1)"
|
||||
},
|
||||
"H21": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(1,\"order_id\",\"#categ_id\",2)"
|
||||
"content": "=ODOO.PIVOT(1,\"order_reference\",\"#categ_id\",2)"
|
||||
},
|
||||
"H22": {
|
||||
"style": 5,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(1,\"order_id\",\"#categ_id\",3)"
|
||||
"content": "=ODOO.PIVOT(1,\"order_reference\",\"#categ_id\",3)"
|
||||
},
|
||||
"H23": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(1,\"order_id\",\"#categ_id\",4)"
|
||||
"content": "=ODOO.PIVOT(1,\"order_reference\",\"#categ_id\",4)"
|
||||
},
|
||||
"H24": {
|
||||
"style": 5,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(1,\"order_id\",\"#categ_id\",5)"
|
||||
"content": "=ODOO.PIVOT(1,\"order_reference\",\"#categ_id\",5)"
|
||||
},
|
||||
"H25": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(1,\"order_id\",\"#categ_id\",6)"
|
||||
"content": "=ODOO.PIVOT(1,\"order_reference\",\"#categ_id\",6)"
|
||||
},
|
||||
"H26": {
|
||||
"style": 5,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(1,\"order_id\",\"#categ_id\",7)"
|
||||
"content": "=ODOO.PIVOT(1,\"order_reference\",\"#categ_id\",7)"
|
||||
},
|
||||
"H27": {
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(1,\"order_id\",\"#categ_id\",8)"
|
||||
"content": "=ODOO.PIVOT(1,\"order_reference\",\"#categ_id\",8)"
|
||||
},
|
||||
"H28": {
|
||||
"style": 5,
|
||||
"format": 1,
|
||||
"content": "=ODOO.PIVOT(1,\"order_id\",\"#categ_id\",9)"
|
||||
"content": "=ODOO.PIVOT(1,\"order_reference\",\"#categ_id\",9)"
|
||||
},
|
||||
"I19": {
|
||||
"style": 2,
|
||||
@@ -626,10 +626,10 @@
|
||||
"content": "=B3+B4"
|
||||
},
|
||||
"B3": {
|
||||
"content": "=ODOO.PIVOT(7,\"order_id\")"
|
||||
"content": "=ODOO.PIVOT(7,\"order_reference\")"
|
||||
},
|
||||
"B4": {
|
||||
"content": "=ODOO.PIVOT(2,\"order_id\",\"is_abandoned_cart\",\"true\")"
|
||||
"content": "=ODOO.PIVOT(2,\"order_reference\",\"is_abandoned_cart\",\"true\")"
|
||||
},
|
||||
"B5": {
|
||||
"content": "=ODOO.PIVOT(5,\"price_subtotal\")"
|
||||
@@ -642,10 +642,10 @@
|
||||
"content": "=C3+C4"
|
||||
},
|
||||
"C3": {
|
||||
"content": "=ODOO.PIVOT(8,\"order_id\")"
|
||||
"content": "=ODOO.PIVOT(8,\"order_reference\")"
|
||||
},
|
||||
"C4": {
|
||||
"content": "=ODOO.PIVOT(3,\"order_id\",\"is_abandoned_cart\",\"true\")"
|
||||
"content": "=ODOO.PIVOT(3,\"order_reference\",\"is_abandoned_cart\",\"true\")"
|
||||
},
|
||||
"C5": {
|
||||
"content": "=ODOO.PIVOT(6,\"price_subtotal\")"
|
||||
@@ -813,7 +813,7 @@
|
||||
"id": "1",
|
||||
"measures": [
|
||||
{
|
||||
"field": "order_id"
|
||||
"field": "order_reference"
|
||||
},
|
||||
{
|
||||
"field": "price_subtotal"
|
||||
@@ -873,7 +873,7 @@
|
||||
"id": "2",
|
||||
"measures": [
|
||||
{
|
||||
"field": "order_id"
|
||||
"field": "order_reference"
|
||||
}
|
||||
],
|
||||
"model": "sale.report",
|
||||
@@ -934,7 +934,7 @@
|
||||
"id": "3",
|
||||
"measures": [
|
||||
{
|
||||
"field": "order_id"
|
||||
"field": "order_reference"
|
||||
}
|
||||
],
|
||||
"model": "sale.report",
|
||||
@@ -1002,7 +1002,7 @@
|
||||
"id": "4",
|
||||
"measures": [
|
||||
{
|
||||
"field": "order_id"
|
||||
"field": "order_reference"
|
||||
},
|
||||
{
|
||||
"field": "price_subtotal"
|
||||
@@ -1187,7 +1187,7 @@
|
||||
"id": "7",
|
||||
"measures": [
|
||||
{
|
||||
"field": "order_id"
|
||||
"field": "order_reference"
|
||||
}
|
||||
],
|
||||
"model": "sale.report",
|
||||
@@ -1246,7 +1246,7 @@
|
||||
"id": "8",
|
||||
"measures": [
|
||||
{
|
||||
"field": "order_id"
|
||||
"field": "order_reference"
|
||||
}
|
||||
],
|
||||
"model": "sale.report",
|
||||
|
||||
@@ -60,7 +60,7 @@
|
||||
<field name="model">sale.report</field>
|
||||
<field name="inherit_id" ref="sale.sale_report_view_tree"/>
|
||||
<field name="arch" type="xml">
|
||||
<field name="order_id" position="after">
|
||||
<field name="order_reference" position="after">
|
||||
<field name="website_id" optional="hide"/>
|
||||
</field>
|
||||
</field>
|
||||
|
||||
Reference in New Issue
Block a user