Siirry sisältöön
Menu
Sinun on rekisteröidyttävä, jotta voit olla vuorovaikutuksessa yhteisön kanssa.
Tämä kysymys on merkitty
1 Vastaa
5157 Näkymät

It seems there is no integrity between the department manager in the "Departments" form, and the same field in the "Emplyee" form.

When you assing a name in either forms, it doesn;t reflect in the other!!!

 

Avatar
Hylkää
Tekijä

(about the answer) I can't get your point !!!

Paras vastaus

Hello,

The manager in "Departements form" will be the default value into "employee form" when you will set a department ... (on_change_department_id function)

But the manager id will be saved into the Employee table. 

To get what you explains... you need to replace this "manager field (parent_id)" with a related to department_id.manager_id

 

Update : 

 

In department form, you define the default manager for this department.

So when you are in employee form, when you set the department, by default the manager field is fill in with the default value. But you are allowed to edit this one, that just a default value... So, 2 employees from the same department can have 2 distincts managers !

It's not a bug, it's the behavior that Odoo wants...

 

If your idea, is to define only the department to an employee and only show for information the manager of the current deparment, you need to use a "related field" to keep the relation between department/manager. With this solution, if you change the manager in employee form, your are changing the default manager for this department...

 

JKE

Avatar
Hylkää

Op does not understand your answer but can't post comments on your answer due to low karma.

Aiheeseen liittyviä artikkeleita Vastaukset Näkymät Toimenpide
3
maalisk. 15
7529
3
maalisk. 15
4761
1
lokak. 25
388
1
syysk. 25
417
3
syysk. 25
638