[FIX] *: unsupported type for graph views

In the new implementation, the type is checked to prevent loading
a view type that does not exist.

In the old implementation, the type was ignored resulting in a graph view.

So, before this commit, some views were no longer loaded.

The 'pivot' type should not be used since there is a dedicated pivot
view.
This commit is contained in:
Adrien Dieudonne
2017-04-11 19:44:38 +02:00
committed by Aaron Bohy
parent 875ea7964c
commit f624e8a575
6 changed files with 7 additions and 7 deletions
@@ -16,7 +16,7 @@
<field name="name">asset.asset.report.graph</field>
<field name="model">asset.asset.report</field>
<field name="arch" type="xml">
<graph string="Assets Analysis" type="pivot">
<graph string="Assets Analysis">
<field name="asset_category_id" type="row"/>
<field name="gross_value" type="measure"/>
<field name="unposted_value" type="measure"/>
@@ -6,7 +6,7 @@
<field name="name">hr.holidays.graph</field>
<field name="model">hr.holidays</field>
<field name="arch" type="xml">
<graph string="Appraisal Analysis" type="pivot" stacked="True">
<graph string="Appraisal Analysis" stacked="True">
<field name="employee_id" type="row"/>
<field name="holiday_status_id" type="row"/>
<field name="date_from" type="col"/>
@@ -111,7 +111,7 @@
<field name="model">mail.mass_mailing.contact</field>
<field name="priority">10</field>
<field name="arch" type="xml">
<pivot string="Contacts" type="pivot" stacked="True">
<pivot string="Contacts" stacked="True">
<field name="create_date" type="row"/>
</pivot>
</field>
@@ -122,7 +122,7 @@
<field name="model">mail.mass_mailing.contact</field>
<field name="priority">10</field>
<field name="arch" type="xml">
<graph string="Contacts" type="pivot" stacked="True">
<graph string="Contacts" stacked="True">
<field name="create_date" type="row"/>
</graph>
</field>
@@ -32,7 +32,7 @@
<field name="name">crm.partner.assign.report.graph</field>
<field name="model">crm.partner.report.assign</field>
<field name="arch" type="xml">
<graph string="Opportunities Assignment Analysis" type="pivot" stacked="True">
<graph string="Opportunities Assignment Analysis" stacked="True">
<field name="grade_id" type="row"/>
<field name="nbr_opportunities" type="measure"/>
<field name="turnover" type="measure"/>
+1 -1
View File
@@ -225,7 +225,7 @@
<field name="name">forum.post.graph</field>
<field name="model">forum.post</field>
<field name="arch" type="xml">
<graph string="Graph of Posts" type="pivot">
<graph string="Graph of Posts">
<field name="write_date" interval="month" type="col" />
<field name="forum_id" type="row" />
</graph>
@@ -146,7 +146,7 @@
<field name="name">slide.slide.graph</field>
<field name="model">slide.slide</field>
<field name="arch" type="xml">
<graph string="Graph of Slides" type="pivot">
<graph string="Graph of Slides">
<field name="date_published" interval="month" type="col"/>
<field name="channel_id" type="row"/>
</graph>