Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

0

How to allow read parent tasks to followers

By
Pablo Manuel Rizzo
on 9/23/13, 5:28 PM 2,023 views

This is somewhat the project.task hierachy:

"TASK 1" -child_ids----parent_ids-"TASK 2"-child_ids----parent_ids-"TASK 3"-message_follower_ids

The filter domain should allow follower of TASK 3 to read TASK 2 and TASK 1:

(1) - followers can read following tasks (2) - followers can read parents/grand parents of followed tasks

This filter allows (1):

[('message_follower_ids','in',[user.partner_id.id])]

How can I allow (2)?

Thanks!

1
Pablo
On 9/23/13, 6:18 PM

We are using a similar rule to allow supervisors to access the records of employees supervised and monitored records for their supervised and has the following syntax

['|','|','|',('department_id.manager_id.user_id','=',user.id),('department_id.manager_id.department_id.manager_id.user_id','=',user.id),('department_id.manager_id.department_id.manager_id.department_id.manager_id.user_id','=',user.id),('department_id.manager_id.department_id.manager_id.department_id.manager_id.department_id.manager_id.user_id','=',user.id)]

Estamos usando una regla similar para que los supervisores puedan acceder a los registros de los empleados supervisados y a los registros de los supervisados por sus supervisados y tiene la siguiente sintaxis

['|','|','|',('department_id.manager_id.user_id','=',user.id),('department_id.manager_id.department_id.manager_id.user_id','=',user.id),('department_id.manager_id.department_id.manager_id.department_id.manager_id.user_id','=',user.id),('department_id.manager_id.department_id.manager_id.department_id.manager_id.department_id.manager_id.user_id','=',user.id)]

Thank you Pablo, but the problem is this is not recursive, it doesn't escalate to N levels of parenting.

Pablo Manuel Rizzo
on 9/23/13, 7:01 PM

Same problem here....Want a solution which is recursive.....any help will be appreciated...Thanks

dirtyHandsPHP
on 8/29/14, 6:04 AM

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)

Stats

Asked: 9/23/13, 5:28 PM
Seen: 2023 times
Last updated: 3/16/15, 8:10 AM