I have the "reviewer" field available in my task, and I want to switch the reviewer with the task assignee automatically when the task is moved from the 'In progress' stage to the 'Review' stage. I have the following Python code in my server action: picture of the code in context
def assignrev(self): for record in self: if record['project.task.type.stage_id.name']=='Review': a=self.res.users.reviewer_id.name b=self.res.users.user_id.name record['res.users.user_id.name']=a record['res.users.reviewer_id.name']=b and below are links to pictures of my automated action settings: Server action to run
Unfortunately, changing the task stage to 'Review' does not give the expected results. Any suggestion please?
Kazu
