@api.onchange("name_teacher")
def _onchange_name_teacher(self):
for rec in self:
return{
'domain': {'name_subject': [('name_teacher', 'in', rec.name_teacher.name_subject.ids)]}
}
error:
WARNING odoo16 odoo.models: onchange method TeacherSubject._onchange_name_teacher
returned a domain, this is deprecated
No data is showing on table