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

I have a model with a partner id in it. There is a list view accessible from a menu which also appears in the portal. What is the recommended way to show employees all records (and include a partner_id column), but portal users only their own records (hiding the partner_id column for them). 

Awatar
Odrzuć
Autor

@Jordi: thank you. Did not know it would be so easy. For portal users, how would I restrict the list to show only their records? Do I use filter_domain, domain, or force_domain?

Autor

Sorry, I meant 'domain_force'. Something I found while grepping the odoo sources.

Najlepsza odpowiedź

Hi Ron,

In that case you should make sure that the 'partner_id' field in your view definition has the the following attribute and value:

groups="base.group_user" 

This will restrict this field to appear only for employees.

Portal users belong to a group "Portal" that does not include the group "Employees".

Regards,

Jordi Ballester

www.eficent.com

Awatar
Odrzuć
Powiązane posty Odpowiedzi Widoki Czynność
1
wrz 23
5248
0
mar 21
2728
1
mar 18
6623
2
sie 25
2427
2
lip 25
1415