[buddypress-trac] [BuddyPress] #2673: Plugins Management for Groups
buddypress-trac
noreply at wordpress.org
Fri Sep 6 16:14:42 UTC 2013
#2673: Plugins Management for Groups
-------------------------------------------------+------------------
Reporter: michaelha | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: 1.9
Component: Groups | Version:
Severity: normal | Resolution:
Keywords: has-patch 2nd-opinion needs-testing |
-------------------------------------------------+------------------
Changes (by boonebgorges):
* milestone: Future Release => 1.9
Comment:
Thanks for the really interesting patch, imath. I have some conceptual
questions for the whole group, and then some technical feedback on the
patch.
Concept: In general, I really like the idea of allowing extensions to be
toggled on a group-by-group basis. This patch both does less and more than
this: it does more by allowing for a global default setting for each
extension (the Groups > Extensions panel), and it does less by not
allowing group admins to handle this task. If I'd been the one to write
the first draft, I would have set it up a bit differently:
- I would have created a front-end UI for group admins to toggle
extensions. To my mind, the real power of this functionality is to let
group admins have it.
- I would have left out the global defaults. They're a bit confusing: as
imath wrote the patch, they provide global fallback settings. But they're
just fallbacks - there's no way to force an extension toggle across all
groups. So, it seems to me like it's of limited use, especially given that
we're adding an entire admin panel for it. A more fleshed out version of
the admin panel would do a bit more: it would allow super admins to set
the *default* value for each extension, and it would let the admin toggle
whether group admins would have granular control over that given
extension's toggle.(This is how xprofile field visibility works: admins
can set a default level, and can also say whether individuals can modify
it.) IMHO, it's only worth adding this panel if we provide this kind of
rich functionality. If it's just for fallbacks, the same thing can be done
with filters.
What do others think? Is this the kind of power we want to give to group
admins as well as super admins? IMO, the answer is yes; moreover, if we're
only going to give it to super admins, I think it'd be better handled by a
plugin, not by BP itself. I'd also tentatively suggest that we table the
Extension admin panel (and the idea of global defaults) at first, and
think about adding it after the UI for individual groups has been set.
Technical considerations: imath, you wrote much of this like a plugin,
which is to say you added a bunch of functions, but didn't change anything
about BP. This is good for a plugin :) but it makes for some ugly hacks.
So, instead of fishing around in `$wp_filter`, we should just register all
new extensions at the time that `bp_register_group_extension()` is called.
`BP_Group_Extension` already creates ReflectionClass objects for each
extension, so your ReflectionClass stuff (which is clever, btw) should be
moved there instead. See 2673.02.patch for a mostly-working version of
these suggestions.
I'm moving this to 1.9 for preliminary consideration. Let's talk about it
at the next dev chat to see if it's something we can agree on conceptually
in time for 1.9.
--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/2673#comment:4>
BuddyPress <http://buddypress.org/>
BuddyPress
More information about the buddypress-trac
mailing list