[buddypress-trac] [BuddyPress Trac] #6306: custom post type support for activities

buddypress-trac noreply at wordpress.org
Thu Mar 19 14:54:30 UTC 2015


#6306: custom post type support for activities
----------------------------------+-----------------------------
 Reporter:  shanebp               |      Owner:
     Type:  defect (bug)          |     Status:  new
 Priority:  normal                |  Milestone:  Awaiting Review
Component:  Component - Activity  |    Version:  2.2.1
 Severity:  normal                |   Keywords:
----------------------------------+-----------------------------
 An activity entry is created when a new cpt post is created.
 But comments on custom post type post are ''not'' appearing in the
 activity stream.

 I am ''not'' creating a component.

 I create a custom post type.
 I add post_type_support:

 {{{
 register_post_type( 'cpt',...
         "supports" => array("title", "editor", "thumbnail", "author",
 "comments", "trackbacks", "buddypress-activity"),
         'bp_activity' => array(
                 'component_id' => 'activity',
                 'action_id'    => 'new_cpt',
                 'contexts'     => array( 'activity', 'member',
 'member_groups' ),
                 'position'     => 100,
         ),
 }}}


 A function hooked to bp_init runs this:

 {{{
    bp_activity_set_post_type_tracking_args( 'cpt', array(
         'component_id'             => 'activity',
         'action_id'                => 'new_cpt',
         'bp_activity_admin_filter' => __( 'CPT', 'bp-domain' ),
         'bp_activity_front_filter' => __( 'CPT', 'bp-domain' ),
         'contexts'                 => array( 'activity', 'member', 'group'
 ),
         'activity_comment'         => true,
         'bp_activity_new_post'     => __( '%1$s created a new <a
 href="%2$s">CPT</a>', 'bp-domain' ),
         'bp_activity_new_post_ms'  => __( '%1$s created a new <a
 href="%2$s">CPT</a>, on the site %3$s', 'bp-domain' ),
         'position'                 => 100,
     ) )
 }}}

 I have ''Site Tracking'' and ''Allow activity stream commenting on blog
 and forum posts'' enabled.
 Comments on regular blog posts appear in the activity stream.

 So why don't comments on cpt posts?
 Bug or mistake on my end?

--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/6306>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac


More information about the buddypress-trac mailing list