Skip to Content
Menu
Musisz się zarejestrować, aby móc wchodzić w interakcje z tą społecznością.
To pytanie dostało ostrzeżenie
3 Odpowiedzi
5055 Widoki

I tried two ways to display many2many field in list view but none of them worked:

1) <field name="test_ids"/> --> It shows just the number of records.(i.e. (3 records))

2) <field name="test_ids" widget="many2many"/> --> It shows the ids of records. (i.e. 2,3,4)

How to achive this?

Awatar
Odrzuć
Najlepsza odpowiedź

use ==> widget="many2many_tags"

Awatar
Odrzuć
Autor

I already tried this but not working. It shows the ids of records. (i.e. 2,3,4)

Autor

Tnx. There was some issue in my db. I created new db and it worked.

Najlepsza odpowiedź

Hello Rakesh,

.py - field_name = fields.Many2many('res.partner', string="many2many_tags")

.xml - <field name="field_name" widget="many2many_tags"/>


Hope it helps,

Regards,

Mayank Gosai

Awatar
Odrzuć
Autor

Tnx. There was some issue in my db. I created new db and it worked.

Powiązane posty Odpowiedzi Widoki Czynność
1
cze 20
13895
1
paź 16
3931
1
wrz 15
10525
0
gru 23
1416
1
maj 23
2928