The button should be visible only to the employee who logged in but not be visible on the other employee card in employee module? please help
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- Księgowość
- Zapasy
- PoS
- Project
- MRP
To pytanie dostało ostrzeżenie
You have to create a New Group in users, you give it a name, "Extra Buttons" for instance, then add the user o users in this group to whom you want to display the button, and in view:
<button name="My Extra Button" groups="Extra Buttons" .../>
So the users in that group can see the button.
but i need through attrs
when he logs in he must be accessible, the button cannot be viewed on other employee details?
i need through attrs
Then add a new boolean field in employee model is_custom_employee, and
<field name="extrabutton" attrs="{'invisible':[('is_custom_employee', '=', False)]}" />
Podoba Ci się ta dyskusja? Dołącz do niej!
Stwórz konto dzisiaj, aby cieszyć się ekskluzywnymi funkcjami i wchodzić w interakcje z naszą wspaniałą społecznością!
Zarejestruj sięPowiązane posty | Odpowiedzi | Widoki | Czynność | |
---|---|---|---|---|
|
2
mar 23
|
10031 | ||
Cacher le bouton "créer" d'une liste
Rozwiązane
|
|
2
mar 23
|
2440 | |
Add class to button from function
Rozwiązane
|
|
2
maj 22
|
4404 | |
|
0
mar 22
|
1583 | ||
|
1
maj 21
|
4366 |