Hello
I really love the feature integrated within the module. It goes beyond the basic public/private paradigm, and offers a level of customization really needed and interesting. Also the fact the feature is in d.o means it has an issue queue ! This rocks !
I was wondering : can your feature hide Features menu entries where all posts are private for the visiting user ? So if I'm anonymous/non-member of group A, and all blog posts of group A are marked private through the feature, it "automagically" hides the blog entry menu so I don't even see it. I don't know if it's possible or clean. I suppose it would require a check to all nodes' privacy (not very efficient), and a kind of unset('blog menu entry'); or hook_menu_alter() (is it clean ?). What do you think ?
Comments
Comment #1
Grayside commentedInteresting thought.
What would need to happen is to implement
hook_menu_alter()and replace the access callbackspaces_menu_access()with something that:There are two things in the way of seeing this kind of functionality in the og_privacy_atrium feature itself:
I would be happy to link to any modules/features that add this functionality separately without meeting those requirements.
Comment #2
DjebbZ commentedFor the 2 things that are in the way of seeing this in your feature :
I will try this week or next, so I'll get back for updates or call for help if needed :)
Thanks a lot for the precise answer.
Comment #3
Grayside commentedI've done some further thinking, and I've got a direction for you. The core of which should not be hosted as part of this project. Here's the "vision":
A "Menu Access Control" module providing a hook_menu_access_policy_info() after the fashion of hook_og_privacy_policy_info(), to be invoked in hook_menu_alter().
og_privacy_atrium or some other module could implement
atrium_menu_access_policy_info()with a callback that would check the path of each of Atrium's core features, with a hook so other added Features can get a foot in the door if so inclined.If the policy is tested and access is denied, well, access is denied. However, if access is granted it should then default to the existing access settings.
There are aspects of this design that bear some careful thinking, because I'm not sure if OG Privacy's pattern makes sense for menu access.
Comment #4
that0n3guy commentedI'll through up a vote for this. I'm getting fairly comfortable with node_access, but have never done menu access stuff... just saying that I might not be the guy that does this :).