跳至內容
選單
此問題已被標幟
2 回覆
10016 瀏覽次數

Hello,

I am facing a problem in kanban view. I can explain it by taking Customer example.

In Customer form contacts are represented by Kanban view. For one Customer(company) there are many contacts. I want to group those contacts by country(country_id) in kanban view so that I can move contacts from one country to another country.

<kanban default_group_by="country_id">

If I group it by country_id, It displays all contacts present in database which belong to same country. 

Is it possible to add filter so that it only display contacts belonging to parent record?

 

頭像
捨棄
最佳答案

Hello @Michael pol,

<field name="context">{"search_default_group_country":1}</field>


The solution can be obtained by using the above context in action view.

Regards,




Email: odoo@aktivsoftware.com

Skype: kalpeshmaheshwari

   

頭像
捨棄
最佳答案

Hello Michael Pol,


Add group by in search view of particular model like below.

<filter name="group_country_id" string="Country" icon="terp-partner" context="{'group_by':'country_id'}"/>


Then add group in context of Action.

<field name="context">{'search_default_group_country_id': 1}</field>


Hope it will helps you.

Thanks,

頭像
捨棄