I've created an @api.depends decorated method for the model project.task, which depends on date_deadline and date_end.
class my_project_task(models.Model):
_inherit = 'project.task'
@api.depends('date_end','date_deadline')
def method_one(...)
Then, I've created another model, inheriting project.task, named project.maintenance (prototype inheritance). Now, I need to create another @api.depends decorated method for this new model project.maintenance, depending on the same fields (date_deadline and date_end).
class maintenance(models.Model):
_inherit = 'project.task'
_name = 'project.maintenance'
@api.depends('date_end','date_deadline')
def method_two(...)
The problem is that, when date_deadline and date_end values are changed for the model project.maintenance, the method triggered is method_one and not method_two.
How can I override method_one in this scenario?