Announcement

#1 2014-07-24 20:55:58

Nikolaus Krismer
Guest

Permissions (and inheritance album permissions)

Hi,

I do have a question about the new permission inheritance introduced in version 2.6.

After adding "$conf['inheritance_by_default'] = true" to my local configuration the permissions are inherited to newly created albums (so the feature works fine), but in fact I want the newly created albums to have only a subset of the users from the parent album.

The reason is the following:
I have an album named 2014 (containing all my albums of this year).
It contains subalbums like 2014-05-31, 2014-06-02, 2014-07-01, ... (and many more).
Now I want all albums these albums to be accessible by users "Niko" and "UserD" and some more accessible by user "UserA" and "UserR" (but the last two users should not get access to all new albums, just to some albums which I want to assign by hand).

Now when I create a new album "2014-07-21" then all the users (Niko, UserA, UserD and UserR) can access this album. The reason seems that they all have access to the album "2014". If I remove the access for UserA and UserR from 2014 they can not access the albums assigned by hand in 2014 anymore.

Is there any possibility to realize my worklow?
I was thinking of somehing like "default persmissions for newly created subalbums" in the album edit page (for users and for user groups), but I guess that needs many implementation changes.
____

Piwigo version: 2.6.3
PHP version: 5.4.16
MySQL version: 5.5.37-Mariadb
____

Kind Regards,
Niko

 

#2 2014-07-24 21:01:47

mistic100
Former Piwigo Team
Lyon (FR)
2008-09-27
3277

Re: Permissions (and inheritance album permissions)

Hi

that would be overly complicated complicated for a very limited usage
the current implementation is easy to understand and it doesn't take too mush time to tweak the settings afterward

I suggest you use groups too to speed things up

Offline

 

#3 2014-07-25 10:26:30

Niko_K
Member
Aldrans, Tirol
2013-06-17
4

Re: Permissions (and inheritance album permissions)

I would not think that this becomes complicated.
Maybe the solution could be a bit different (maybe only one field in the album edit page but with two kinds of users - users assigned by hand (e.g. shown in black) and users assigned through permissions on a subalbum (shown in another color)). Then one could decide in the local configuration if all users (default) or only users assigned by hand inherit permissions.

However, is it possible to assign users when calling sync permissions (and setting defaults for sync, since I call this by script) then? This could also fix my problem. I only found the field where I can select (Family, Family and Friends, ...), but no users and/or groups. Wouldn't groups make more sense here?

Offline

 

#4 2014-07-25 10:36:35

mistic100
Former Piwigo Team
Lyon (FR)
2008-09-27
3277

Re: Permissions (and inheritance album permissions)

Niko_K wrote:

However, is it possible to assign users when calling sync permissions (and setting defaults for sync, since I call this by script) then? This could also fix my problem. I only found the field where I can select (Family, Family and Friends, ...), but no users and/or groups. Wouldn't groups make more sense here?

I don't understand what your are talking about...

there is a Webservice method to manage permissions
pwg.permissions.getList
pwg.permissions.add
pwg.permissions.remove

Offline

 

#5 2014-07-25 11:13:08

Niko_K
Member
Aldrans, Tirol
2013-06-17
4

Re: Permissions (and inheritance album permissions)

mistic100 wrote:

Niko_K wrote:

However, is it possible to assign users when calling sync permissions (and setting defaults for sync, since I call this by script) then? This could also fix my problem. I only found the field where I can select (Family, Family and Friends, ...), but no users and/or groups. Wouldn't groups make more sense here?

I don't understand what your are talking about...

there is a Webservice method to manage permissions
pwg.permissions.getList
pwg.permissions.add
pwg.permissions.remove

I am talking about piwigos file synchronization. On the page it is possible to chosse if file, folder or both should be synchronized with an option of "who can see the photos". There is a drop-down where I can select some pre-defined values like "Family", "Family,Friends", ...
I was wondering why I can not use groups (or even single users) here, since this would really make sense to me.

Maybe I'll give the webservice a try (might be a bit tricky, since the sync script I am using was not implemented by myself)

Offline

 

Board footer

Powered by FluxBB

github twitter newsletter Donate Piwigo.org © 2002-2024 · Contact