Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
04/28/2021 11:51:37 PM (6 months ago)
Author:
dcavins
Message:

Member Invites: Add items to WP Admin bar account menu.

Add links to a user's invitations screens to the WP Admin Bar menu.

See #8139.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-members/classes/class-bp-members-component.php

    r12920 r12924  
    561561                'position' => 40
    562562            );
     563        }
     564
     565        return $wp_admin_nav;
     566    }
     567
     568    /**
     569     * Get the members invitations admin bar navs.
     570     *
     571     * @since 8.0.0
     572     *
     573     * @param  string $admin_bar_menu_id The Admin bar menu ID to attach sub items to.
     574     * @return array                     The members invitations admin navs.
     575     */
     576    public function get_members_invitations_admin_navs( $admin_bar_menu_id = '' ) {
     577        $wp_admin_nav = array();
     578        $invite_link  = trailingslashit( bp_loggedin_user_domain() . bp_get_profile_slug() );
     579
     580        if ( ! $admin_bar_menu_id ) {
     581            $admin_bar_menu_id = $this->id;
    563582        }
    564583
Note: See TracChangeset for help on using the changeset viewer.