Ir al contenido
Menú
Se marcó esta pregunta
1 Responder
800 Vistas

I need an python function to select all task which are in open stage how can I do that using python code I am using odoo16

Avatar
Descartar
Mejor respuesta

Hi,

You can get all the tasks that are in the open state by using the following Python code 
open_tasks = self.env['project.task'].search([('stage_id.id', '=', 'open_stage_id' )])

In the above code change the value of open_stage_id with the corresponding id of the stage where the task is in open.

Hope it helps

Avatar
Descartar
Publicaciones relacionadas Respuestas Vistas Actividad
3
ago 25
2307
1
may 25
2538
1
abr 25
3510
1
abr 25
4343
1
abr 25
1818