跳至内容
菜单
此问题已终结
3 回复
11422 查看

At Point of Sale Orders, I wanted to add a Graph View where it can be grouped by (Shop)

I've successfully added the field 'shop_id' to the tree view, then to the group by at search view. through inherited views for each.

I've created a graph view for the object: pos.order

Architecture: <graph string="POS Orders" type="bar"> <field name="shop_id"/> <field name="amount_total" operator="+"/> </graph>

Later I've added a graph view in the action, so the graph view button appears right after the list view (tree)

problem is ...

The graph appears without proper data.

Par type shows 0 sales, though there are posted orders Pie type shows NaN%

regardless of trying to group by other fields.

I noticed that this problem also happens at the account.account model graph view

Could you please help me with this case ?

形象
丢弃

I'm not sur the operator attribute work on >v7 ):

in this line you specified <field name="amount_total" operator="+"/>

what is the use of operator ="+"

最佳答案

 in this line you specified <field name="amount_total" operator="+"/> 

what is the use of operator ="+" 

形象
丢弃
最佳答案

I hope that, if you want to group by shop_id, check if the following code works,

Replace

<field name="shop_id"/>

by

<field name="shop_id" group="True"/>

i.e., Group by shop_id... We have to add the attribute group set to True.

 

 

形象
丢弃
相关帖文 回复 查看 活动
0
6月 15
3508
4
1月 24
23149
2
1月 24
2440
0
8月 23
2299
5
9月 21
17497