[buddypress-trac] [BuddyPress Trac] #3460: Support custom post types in activity stream
buddypress-trac
noreply at wordpress.org
Tue Mar 25 15:04:43 UTC 2014
#3460: Support custom post types in activity stream
-------------------------------------------------+-------------------------
Reporter: boonebgorges | Owner:
Type: enhancement | boonebgorges
Priority: low | Status: new
Component: Activity | Milestone: 2.1
Severity: normal | Version: 1.2.8
Keywords: 2nd-opinion has-patch needs-testing | Resolution:
-------------------------------------------------+-------------------------
Comment (by imath):
Replying to [comment:72 boonebgorges]:
> You mean A can opt in while B can opt out, without disabling tracking
altogether? I know that B can disable tracking by making his site private.
But if A checks the Foo box, while B unchecks it, won't it be the case
that all Foo posts across the network are still recorded? I don't see
where in the patch it's checking the settings that are specific to the
site.
Yes exactly each blog can define what post type can be tracked, and
untrack a post type that is track by root blog.
{{{
if ( $blog_id != bp_get_root_blog_id() ) {
$trackable = (array) apply_filters(
'bp_blogs_is_blog_post_type_trackable', bp_blogs_blog_trackable_post_type(
array(), $blog_id ), $blog_id );
}
}}}
the function {{{bp_blogs_blog_trackable_post_type()}}} gets the option of
the child blog
> Ah, you're right. I missed that (the `is_public` check). But even this
is a bit confusing, because the menu simply disappears when changing what
appears to be an unrelated setting ('Discourage search engines').
Well, we could create a specific option that would not make the tracking
rely on this setting. And during the update fill that option with the
Discourage one. Or we could rely on the fact that unchecking each post
type will make my site "untrackable" which would be the same result than
checking Discourage search engines
> Could be, but I have a hard time imagining a network that has more than
a few dozen post types. (Think about how many plugins you'd be running if
you had more than this!)
Yes i guess you're right and even if themes in the network might create
"exotic" post types, as they won't be in the root one and not network
available they will fall in my fallback 'posted a new item'
> ==
>
> I had another thought as I was writing this. What, if anything, should
we do about plugins that handle their own activity items? Say, bbPress.
Ideally, we would keep them out of the list of checkboxes, or else they'd
be duplicated in the activity stream. What do you think?
I think, you're right!! i forgot this case, well i used to handle it in
previous patch somehow by checking for a post type argument (bp_tracking
set to false). That's a problem, because this means we'll need to handle
it without relying on a post type argument because i doubt plugins would
be all ready to add this custom argument.
--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/3460#comment:73>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac
More information about the buddypress-trac
mailing list