Skip to Content
Menu
You need to be registered to interact with the community.
This question has been flagged
2 Odgovori
8931 Prikazi

Hello

By default, a user having the access rights from the group 'Project/User' is allowed to read/write on any project or task.

I would like that a project user can only read and write the projects and tasks assigned to him.

I googled a bit and also have a look at the 'Setting>Users>Groups' and  'Setting>Security>Record Rules' sections but did not get a clear understanding of the direction into which I should move

Any help would be appreciated

 

Many thanks

Franck

Avatar
Opusti
Best Answer

You are on the right track.

Add a record rule for object Project with 'apply for read' and 'apply for write'.

Use the following domain: [('members', '=', user.id)]

And select the Project / User group.

 

This way, users of group.project_users will only have read and write access if they are member in the project.

 

Regards.

 

Avatar
Opusti
Avtor Best Answer

Nice & swift answer !!

Is there a list of ojects properties (such as 'members') available somewhere ?

I browsed the developpers doc but did not find any list

Many thanks

franck

Avatar
Opusti

You can check the columns of any table in the database. (Using pgAdmin i.e.). Or you can check the python code for the _columns attribute. Or you can see all fields of any database object in the webclient under Settings -> Technical -> Databse Structure -> Models. Select the object you want and see the fields-tab. (Technical Features must be activated in the users Access Rights)

Avtor

I went through the database stucture and wanted to define a rule allowing only tasks assigned to project users to be displayed in list of tasks (project>project> tasks). I thus created a record rule for Project.task with 'apply for read' and 'apply for write'. and the following domain: [('user_id', '=', user.id)] for Project / User group.. It doesn't do what I was expecting... There is something I did not understood

Avtor

I finally managed to make it by making the rule above as global.

Related Posts Odgovori Prikazi Aktivnost
3
okt. 25
3173
2
sep. 25
806
2
sep. 25
1635
1
jul. 25
1247
2
jun. 25
3659