When an employee edits his/her information I want to restrict certain fields not to edit by employee (but can be editable by ADMIN).
Esta pergunta foi sinalizada
2
Respostas
7085
Visualizações
Hi,
You could use the "read" and "write" attributes on field definition, like this one:
_columns = {
'credit_limit': fields.float(string='Credit Limit',
read=['base.group_sale_salesman'],
write=['base.group_sale_manager']),
This will create a field named credit_limit that will be readable by users belonging to base.group_sale_salesman and writable only by base.group_sale_manager users...
Hi Mario, Thanks for the reply. It helped me a lot.
You can apply group on that field.admin exist to that group not user.
like groups="base.group_no_one"
Está gostando da discussão? Não fique apenas lendo, participe!
Crie uma conta hoje mesmo para aproveitar os recursos exclusivos e interagir com nossa incrível comunidade!
Inscrever-se| Publicações relacionadas | Respostas | Visualizações | Atividade | |
|---|---|---|---|---|
|
|
4
ago. 23
|
14510 | ||
|
|
0
nov. 16
|
2514 | ||
|
|
1
mar. 15
|
6511 | ||
|
|
2
mar. 15
|
6612 | ||
|
add a field in employee module
Resolvido
|
|
4
out. 20
|
9100 |