Ticket #6609: 6609.02.patch
File 6609.02.patch, 2.8 KB (added by , 10 years ago) |
---|
-
src/bp-activity/admin/css/admin.css
44 44 } 45 45 #bp-activities-form .column-response img { 46 46 float: left; 47 margin-bottom: 5px; 47 48 margin-right: 10px; 48 49 margin-top: 1px; 49 50 } -
src/bp-activity/bp-activity-admin.php
1601 1601 */ 1602 1602 function column_response( $item ) { 1603 1603 // Is $item is a root activity? 1604 ?> 1605 1606 <div class="response-links"> 1607 1608 <?php 1609 // Activity permalink 1610 $activity_permalink = ''; 1611 if ( ! $item['is_spam'] ) { 1612 $activity_permalink = sprintf( __( '<a href="%1$s" class="comments-view-item-link">View Activity</a>', 'buddypress' ), bp_activity_get_permalink( $item['id'], (object) $item ) ); 1613 } 1604 1614 1605 1615 /** 1606 1616 * Filters default list of default root activity types. … … 1611 1621 * @param array $item Current item being displayed. 1612 1622 */ 1613 1623 if ( empty( $item['item_id'] ) || ! in_array( $item['type'], apply_filters( 'bp_activity_admin_root_activity_types', array( 'activity_comment' ), $item ) ) ) { 1624 echo $activity_permalink; 1625 1614 1626 $comment_count = !empty( $item['children'] ) ? bp_activity_recurse_comment_count( (object) $item ) : 0; 1615 1627 $root_activity_url = bp_get_admin_url( 'admin.php?page=bp-activity&aid=' . $item['id'] ); 1616 1628 1617 1629 // If the activity has comments, display a link to the activity's permalink, with its comment count in a speech bubble 1618 1630 if ( $comment_count ) { 1619 1631 $title_attr = sprintf( _n( '%s related activity', '%s related activities', $comment_count, 'buddypress' ), number_format_i18n( $comment_count ) ); 1620 printf( '<a href="%1$s" title="%2$s" class="post-com-count "><span class="comment-count">%3$s</span></a>', esc_url( $root_activity_url ), esc_attr( $title_attr ), number_format_i18n( $comment_count ) );1632 printf( '<a href="%1$s" title="%2$s" class="post-com-count post-com-count-approved"><span class="comment-count comment-count-approved">%3$s</span></a>', esc_url( $root_activity_url ), esc_attr( $title_attr ), number_format_i18n( $comment_count ) ); 1621 1633 } 1622 1634 1623 1635 // For non-root activities, display a link to the replied-to activity's author's profile 1624 1636 } else { 1625 1637 echo '<strong>' . get_avatar( $this->get_activity_user_id( $item['item_id'] ), '32' ) . ' ' . bp_core_get_userlink( $this->get_activity_user_id( $item['item_id'] ) ) . '</strong><br />'; 1638 echo $activity_permalink; 1626 1639 } 1640 ?> 1627 1641 1628 // Activity permalink1629 if ( ! $item['is_spam'] ) 1630 printf( __( '<a href="%1$s">View Activity</a>', 'buddypress' ), bp_activity_get_permalink( $item['id'], (object) $item ) );1642 </div> 1643 1644 <?php 1631 1645 } 1632 1646 1633 1647 /**