97 lines
5.3 KiB
XML
97 lines
5.3 KiB
XML
|
<?xml version="1.0" encoding="utf-8"?>
|
||
|
<odoo>
|
||
|
|
||
|
<record id="view_order_product_pivot" model="ir.ui.view">
|
||
|
<field name="name">sale.report.pivot</field>
|
||
|
<field name="model">sale.report</field>
|
||
|
<field name="arch" type="xml">
|
||
|
<pivot string="Sales Analysis" disable_linking="True">
|
||
|
<field name="team_id" type="col"/>
|
||
|
<field name="confirmation_date" interval="month" type="row"/>
|
||
|
<field name="price_subtotal" type="measure"/>
|
||
|
</pivot>
|
||
|
</field>
|
||
|
</record>
|
||
|
|
||
|
<record id="view_order_product_graph" model="ir.ui.view">
|
||
|
<field name="name">sale.report.graph</field>
|
||
|
<field name="model">sale.report</field>
|
||
|
<field name="arch" type="xml">
|
||
|
<graph string="Sales Analysis">
|
||
|
<field name="date" type="row"/>
|
||
|
<field name="price_subtotal" type="measure"/>
|
||
|
</graph>
|
||
|
</field>
|
||
|
</record>
|
||
|
|
||
|
<!-- Custom reports (aka filters) -->
|
||
|
<record id="filter_sale_report_sales_funnel" model="ir.filters">
|
||
|
<field name="name">Sales Funnel</field>
|
||
|
<field name="model_id">sale.report</field>
|
||
|
<field name="domain">['&', ('date','<=', time.strftime('%%Y-12-31')), '&', ('date','>=',time.strftime('%%Y-01-01')), ('state','not in',('cancel',))]</field>
|
||
|
<field name="user_id" eval="False"/>
|
||
|
<field name="context">{'group_by': ['state'], 'measures': ['price_subtotal']}</field>
|
||
|
</record>
|
||
|
<record id="filter_sale_report_salespersons" model="ir.filters">
|
||
|
<field name="name">By Salespersons</field>
|
||
|
<field name="model_id">sale.report</field>
|
||
|
<field name="user_id" eval="False"/>
|
||
|
<field name="context">{'group_by': ['date:month', 'user_id']}</field>
|
||
|
</record>
|
||
|
<record id="filter_sale_report_salesteam" model="ir.filters">
|
||
|
<field name="name">By Salesteam</field>
|
||
|
<field name="model_id">sale.report</field>
|
||
|
<field name="user_id" eval="False"/>
|
||
|
<field name="context">{'group_by': ['date:month', 'team_id']}</field>
|
||
|
</record>
|
||
|
<record id="filter_isale_report_product" model="ir.filters">
|
||
|
<field name="name">By Product</field>
|
||
|
<field name="model_id">sale.report</field>
|
||
|
<field name="user_id" eval="False"/>
|
||
|
<field name="context">{'group_by': ['date:month', 'product_id']}</field>
|
||
|
</record>
|
||
|
|
||
|
<record id="view_order_product_search" model="ir.ui.view">
|
||
|
<field name="name">sale.report.search</field>
|
||
|
<field name="model">sale.report</field>
|
||
|
<field name="arch" type="xml">
|
||
|
<search string="Sales Analysis">
|
||
|
<field name="date"/>
|
||
|
<filter string="This Year" name="year" invisible="1" domain="[('date','<=', time.strftime('%%Y-12-31')),('date','>=',time.strftime('%%Y-01-01'))]"/>
|
||
|
<filter name="Quotations" string="Quotations" domain="[('state','in', ('draft', 'sent'))]"/>
|
||
|
<filter name="Sales" string="Sales" domain="[('state','not in',('draft', 'cancel', 'sent'))]"/>
|
||
|
<separator/>
|
||
|
<field name="partner_id"/>
|
||
|
<field name="product_id"/>
|
||
|
<field name="user_id"/>
|
||
|
<group expand="0" string="Extended Filters">
|
||
|
<field name="categ_id" filter_domain="[('categ_id', 'child_of', self)]"/>
|
||
|
<field name="company_id" groups="base.group_multi_company"/>
|
||
|
</group>
|
||
|
<group expand="1" string="Group By">
|
||
|
<filter string="Salesperson" name="User" context="{'group_by':'user_id'}"/>
|
||
|
<filter string="Sales Channel" context="{'group_by':'team_id'}"/>
|
||
|
<filter string="Partner's Country" name="country_id" context="{'group_by':'country_id'}"/>
|
||
|
<filter string="Customer" name="Customer" context="{'group_by':'partner_id'}"/>
|
||
|
<filter string="Product Category" name="Category" context="{'group_by':'categ_id'}"/>
|
||
|
<filter name="status" string="Status" context="{'group_by':'state'}"/>
|
||
|
<filter string="Company" groups="base.group_multi_company" context="{'group_by':'company_id'}"/>
|
||
|
<separator/>
|
||
|
<filter string="Order Month" context="{'group_by':'date:month'}" help="Ordered date of the sales order"/>
|
||
|
</group>
|
||
|
</search>
|
||
|
</field>
|
||
|
</record>
|
||
|
|
||
|
<record id="action_order_report_all" model="ir.actions.act_window">
|
||
|
<field name="name">Sales Analysis</field>
|
||
|
<field name="res_model">sale.report</field>
|
||
|
<field name="view_type">form</field>
|
||
|
<field name="view_mode">graph,pivot</field>
|
||
|
<field name="view_id"></field> <!-- force empty -->
|
||
|
<field name="search_view_id" ref="view_order_product_search"/>
|
||
|
<field name="context">{'search_default_Sales':1, 'group_by_no_leaf':1,'group_by':[]}</field>
|
||
|
<field name="help">This report performs analysis on your quotations and sales orders. Analysis check your sales revenues and sort it by different group criteria (salesman, partner, product, etc.) Use this report to perform analysis on sales not having invoiced yet. If you want to analyse your turnover, you should use the Invoice Analysis report in the Accounting application.</field>
|
||
|
</record>
|
||
|
</odoo>
|