Assigning multiple Member Types to a user

Starting in BuddyPress 7.0.0, community administrators will be able to assign more than one member type directly from the user’s WP-Admin/Extended profile page.

The regular select box of the Member Type metabox has been replaced by a multiple select box so that you can assign as many member types as you need to a single user.

Be aware of a change we made to the Member Types bulk actions behavior.

Community Administrators can bulk assign a member type to a list of users from the corresponding Administration screen by:

  1. activating the corresponding checkboxes at the left of users avatars.
  2. selecting the Member Type name from the Member Types dropdown list that is located over or under the users table.
  3. clicking on the change button immediately at the right of this dropdown list.

This strictly means you are changing the existing member type(s) of a user to the selected member type. In other words, if the user nicknamed imath was selected, he would be reassigned to the Lead Developer member type only (and lose the Pizza lover one 🍕).

If you choose the “No Member Type” option, then all the assigned member types of the selected user(s) will be removed.

If you want to read about how this change was made and thank the contributors who made it happen, head over this trac ticket.

By the way, did you know you’ll be able to create, edit, delete Member & Group Types directly from your WordPress Administration in BuddyPress 7.0.0 ?

#7-0-0, #member-types

BP Dev-Chat Summary: October 21, 2020

7.0.0-beta1 feedbacks

7.0.0-beta1 was released on October 16. So far, nothing specific to it was posted into our support forums. At the time we had the meeting, @im4th, thanks to @IAmTheWebb tests, had reported an issue (now fixed) with the Activity Embed block into our Trac environment. This last Friday @k3690 reported a wrong usage of the member term into a Group Type meta property (now fixed).

7.0.0 remaining tickets

  • #8292 @vapvarun submitted a patch during the meeting 💪, @im4th reviewed it some time after, brought some minor improvements and it has been fixed yesterday. It’s now possible to assigned more than one member types to users from their WP Admin Extended Profile 🙌 .
  • About #8179, @im4th asked @vapvarun to update the ticket with 2 squared corner avatars with these dimensions: 150px x 150px (full) & 50px x 50px (thumb). @im4th will try to progress on a patch in the meantime.
  • We’ve postponed #8093 (Profile Field visibility improvements) to a next milestone.
  • #8375 was reopened by the reporter, as the filter we’ve added wasn’t matching its needs. @dcavins @johnjamesjacoby & @im4th have been discussing about it last week in #BuddyPress and came to the conclusion a possible better place to allow the invitation table’s name filtering was to include the {$bp_prefix}bp_invitations table name into the global_tables property of the BP_Members_Component object. @dcavins will investigate this week about that possible change.
  • Finally shortly after our meeting, @boonebgorges reported a new ticket about improving the xprofile_get_field() function so that it only pulls up the data for a field when necessary. The patch he suggested as a first step looks safe to @im4th who thinks it should be included into the 7.0.0 release: it’s always great to improve DB performance. Please have a look at #8378 and send him some feedbacks about your thoughts.

7.0.0 release schedule update

We are going to package a new 7.0.0-beta to include as much fixes as possible considering the previous chapter. Packaging will happen shortly after our next BP Dev-Chat.

  • 7.0.0-beta2: November 4th
  • 7.0.0-RC1: around November 18 (string freeze).
  • 7.0.0: December 1st 🎯

7.0.0 release tasks

The following list of tasks needs to be achieved before we package our next major release (7.0.0).

TasksOwner
BP REST API documentation updates@im4th
BP Survey results@im4th
7.0.0 Release note@vapvarun
7.0.0 Credits update:
– BuddyPress Trac
– BP REST GitHub repository

@dcavins
@im4th
7.0.0 Pizza Restaurant name@dcavins
7.0.0 Announcement post@im4th

NB: we’ll also need to add a patch to #8376 to update our “Hello BuddyPress” modal.

GitHub default branch naming for BuddyPress repositories

This point was moved to a future development meeting. @johnjamesjacoby shared his thoughts about it. Possibilities are main or trunk. FYI WordPress contributors decided to use trunk for repositories of the WordPress organization on August 19.

Open floor

@dcavins asked a question about using the new BuddyPress development environment: when making changes to the BuddyPress source code, he was wondering how is updated the running environment? In other words, do we need to run some specific commands to update it?

@im4th replied changes were automatically taken in account without doing anything more than saving the BuddyPress source code changes. @IAmTheWebb confirmed: “the folder you see outside docker is mapped to inside, so changes you make should appear automagically

Next Dev-Chat

It will happen on November 4 at 19:00 UTC and of course in #BuddyPress. If you have ideas or questions, feel free (and we are strongly encouraging you) to comment this summary to share them!

#7-0-0, #dev-chat, #summary

BP Dev-Chat Agenda: October 21, 2020

Our next development meeting will happen tomorrow on October 21 at 19:00 UTC in #BuddyPress. Here’s our agenda:

  • 7.0.0-beta1 feedbacks.
  • 7.0.0 release tasks (BP REST API documentation updates, BP Survey results, release note, credits, announcement post).
  • GitHub default branch naming for our repositories.
  • Open floor.

If you have anything you wish to add (or remove) to this agenda or specific items related to those listed above, please leave a comment below.

#7-0-0, #agenda, #dev-chat

BuddyPress 7.0.0-beta is now available for testing!

Hi BuddyPress contributors,

Please help us polish the 7.0.0 release testing its first beta https://buddypress.org/2020/10/buddypress-7-0-0-beta1/ 🙏

Thanks in advance 😉

#7-0-0, #beta, #release

The last_activity user metadata is not mirrored by default anymore as of BuddyPress 7.0.0

Hi BuddyPress Plugin/Theme developers,

Since BuddyPress 2.0.0, the primary storage location for the user last_activity information is the activity DB table. For backward compatibility reasons, we used to mirror that data into the usermeta DB table.

This means you could get the last date the user was active on the community site in 2 ways:

  • The right one using the bp_get_user_last_activity( $user_id ) function.
  • The deprecated one using bp_get_user_meta( $user_id, 'last_activity', false ) function.

Please note, starting in BuddyPress 7.0.0, we will stop mirroring the last_activity user metadata, meaning the only way to get the last date the user was active is by using bp_get_user_last_activity( $user_id ).

If your development absolutely needs this piece of information to also be available into the usermeta DB table, then you’ll need to use the following filter to keep it there:

add_filter( 'bp_use_legacy_user_query', '__return_true' );

To read more about this change, see #7882.

#7-0-0, #developers

Here are the 3 new BP Blocks to expect from BuddyPress 7.0.0 🎁 🎁 🎁

The BuddyPress blocks
New BP Blocks arriving in BuddyPress 7.0.0

1. Activity Embed

The Activity Embed block let authors embed an activity into their post or page. It’s very similar to the WordPress Embed block except that it is specific to BuddyPress Activities. Copy the permalink to the Activity single view page, add the Embed an activity block to your post or page, paste the activity link into the placeholder’s input and click on the “Embed” button to have it rendered.

Once rendered, you can adjust its alignment and include a caption under the embedded activity.

2. BP Members Block

Use this BP Block to select community members you want to feature into a post or a page. It’s a different approach than what we’re doing into our Members widgets. These are sorting members rather than allowing the author to pick the ones he’d like to include in his custom list.

It looks very similar to the BP Member block at first sight 😉. But as soon as you’ve added the first member, the Autocompleter control will still be available at the bottom of the block. Use it to add as many members as you need.

From the block’s settings you can choose whether to display the user names, mention names, the full/thumb version of profile photos or no photo at all.

Grid display

From the block’s toolbar you can select the display mode to use : List or Grid. If you chose the grid one, you’ll be able to customize the number of columns to use for this grid from the block’s settings. You can also choose to add extra BuddyPress information about the displayed members. For this grid display, only the information about the last time members were active is available.

List display

When you select the List display, you can include the latest activity the members posted 🏄🏻‍♀️.

If you need to remove a member from the list, Simply click on the x button at the right of the member’s line or cell.

3. BP Groups Block

Use this BP Block to select the groups you want to feature into a post or a page. It’s a different approach than what we’re doing into our Groups widget. Instead of sorting groups according to the date they were created, to the last time they were active, to their amount of members or alphabetically, authors can pick the ones they’d like to include in their custom list.

Just like the BP Members block, once you’ve added your first group, the Autocompleter control will still be available at the bottom of the block to let you choose as many groups as you wish.

Using the block’s toolbar you can select whether to display the groups in a list or in a grid. If you chose the Grid display, you’ll be able to define the number of columns to use from the block’s settings.

Still from these block’s settings, you can show or hide the group names, decide to use the full or the thumb version of the group profiles photo and include some extra information about the Group.

The List display lets you select any of the available extra pieces of information :

  • the group descriptions,
  • or the last time the groups were active,
  • or the amount of group members.

When the grid mode is active, only the two last pieces of extra information will be available.

Finally, if you need to remove a group from the list, Simply click on the x button at the right of the group’s line or cell.

BuddyPress 7.0.0-beta1 is scheduled for tomorrow, please do test it to help us buil a wonderful 7.0.0 stable release 🤝

#7-0-0, #blocks

BP Dev-Chat Summary: October 7, 2020

7.0.0 cycle updates

@vapvarun announced he will work on 2 tickets in the coming weeks:

  • Multiple member types users table issue (See #8292)
  • Field Visibility Not Honored in PHP 7.1 & above (See #8093)

@dcavins committed fixes, shortly after the dev-chat, to the 2 tickets he assigned himself to during our previous dev chat:

  • The function groups_get_invites_for_user() can return inconsistent total (See #8297)
  • bp_has_groups() should accept status parameter (See #8310)

@im4th informed he will work on the following points during this week:

  • Introduce 3 new BP Blocks into BuddyPress core (See #8369)
  • Fix some issues slated for the 7.0.0 milestone
  • Package the 7.0.0 first beta release (October 15, as initially scheduled)

7.0.0 release schedule

  • 7.0.0-beta1: October 15 👈 🥁
  • 7.0.0 : December 1st

Open floor

@vapvarun is working on making his BuddyX awesome standalone BuddyPress theme hosted on the official WordPress Themes directory. 👨🏾‍🎨

We’ve been talking about the Full Site Editing WordPress feature (announced to be included into WordPress 5.6).

And finally @im4th asked everyone to start thinking about the Pizza restaurant name we will use to name our 7.0.0 release. If you have ideas about it, don’t hesitate to submit them into these post comments 🍕.

#7-0-0, #dev-chat, #summary

WP CLI BuddyPress – 2.0

BuddyPress 7.0 will come with several updates for the 2.0 version of the wp-cli-buddypress package.

For those of us living in the command line, it is important to have a tool to facilitate tasks that would require several clicks, tabs, and time. That’s the beauty of WP-CLI, you can perform those tiresome tasks from the command line without much hassle.

Taking advantage of this technology, the Buddypress team created a CLI package to perform those tasks. The 1.0.0 version was launched in 2014 and since then, a lot of changes were made to make it better and more stable.

Since we lauched the 2.0 version a few weeks ago, I’d like to share a few things that were changed, improved, and fixed.

New Commands

We are introducing a few more commands to the package that might be helpful. Mainly:

wp bp group meta

The group meta command can be used to manage BuddyPress Group Meta (custom fields). Here a few commands that can be used to manage the meta information from a group:

$ wp bp group meta
usage: wp bp group meta add <id> <key> [<value>] [--format=<format>]
   or: wp bp group meta delete <id> [<key>] [<value>] [--all]
   or: wp bp group meta get <id> <key> [--format=<format>]
   or: wp bp group meta list <id> [--keys=<keys>] [--fields=<fields>] [--format=<format>] [--orderby=<fields>] [--order=<order>]
   or: wp bp group meta patch <action> <id> <key> <key-path>... [<value>] [--format=<format>]
   or: wp bp group meta pluck <id> <key> <key-path>... [--format=<format>]
   or: wp bp group meta update <id> <key> [<value>] [--format=<format>]

wp bp activity meta

Just like the wp bp group meta command, the activity meta command can be used to manage BuddyPress Activity Meta (custom fields).

wp bp tool signup

This command can be used to activate or deactivate the BuddyPress signup feature.

$ wp bp tool signup 1

wp bp scaffold tests

This command can be used to create BuddyPress specific testing code for plugins. It is targeted at BuddyPress plugin authors that need to set up BuddyPress specific unit tests.

Package Improvements

We made some major internal changes. The big one was removing our legacy Behat set up. We opted to use the WP-CLI composer package: wp-cli/wp-cli-tests.

This was an important change since we don’t need to manage that ourselves, also outsourcing that job to that package, we can benefit from changes and improvements made there. This package is also used in several, if not all, WP-CLI core packages.

Contributions will be much easier now since they won’t need to understand our previous custom set up.

Other Improvements

Besides those new commands and major internal changes, we took the time to improve the code base for reliability:

  • we bumped the PHP version from PHP 5.4 into PHP 5.6.
  • we made sure all Behat tests were passing correctly, fixing bugs where we found them.
  • we improved the readme documentation to better explain a few commands.
  • we forced the creation of the signups table when using the wp bp signup command. This was important in cases where the table was not present and would cause the CLI to fail.
  • we also updated the commands to return proper success/error messages when using tge parent::_delete or parent::_update helper methods.
  • we improved the commands PHPDocs: very useful when using the help param to find out what a command does.
  • we updated to fetch values from PHPDoc instead of PHP.
  • updated or removed the default values from several commands (most of them were wrong, lol).

And several other minor changes to improve the codebase and make sure the commands would run smoothly.

#7-0-0

BP Dev-Chat Agenda: October 7, 2020

Our next development meeting will happen on October 7 (tomorrow) at 19:00 UTC in #BuddyPress. Our agenda:

  • 7.0.0 release cycle updates : 8 days to first beta release (really 👈)
    • BP REST API & BP WP CLI
    • BP Blocks
    • 19 tickets remaining into 7.0.0 milestone.
  • Open floor

If you have anything you wish to add (or remove) to this agenda or specific items related to those listed above, please leave a comment below.

#7-0-0, #agenda, #dev-chat

BP Dev-Chat Summary: September 23, 2020

First, here’s a clarification regarding the context in which this meeting took place : @im4th thought we were a week before 7.0.0-beta1 release 😆 and urge BuddyPress contributors to review the remaining tickets scheduled for the 7.0.0 milestone! We’re now (October 3rd) 2 weeks away from this beta release 😇.

Postponed features

Due to lack of time, we’ve decided to work on the following features during the 8.0.0 development cycle:

  • Attachments for BuddyPress (#8022)
  • BP Members Invitations (#8139)
  • Block based Activity post form (#8319) *
  • Activity Scheduling (#7953) *

* FYI: the BP Blocks plugin used to develop BP Blocks is also used to develop these two features. You can early play with the Block Based Activity post form and the activity scheduling feature, thanks to this plugin, on a testing site. Contributions are always welcome!

7.0.0 updates

  • BP Types UI have been included into Core. It’s now possible to manage Group & Member types from the WordPress administration. More information about it here.
  • The BP REST API now includes a new endpoint to let logged in users to create new blogs (if the network settings allow it). See this GitHub PR.

7.0.0 remaining tickets

7.0.0 BP Blocks

There will be a new block to embed an activity into a post. During the dev chat we agreed it was important to add 2 more blocks : BP Members & BP Groups blocks. See #8369. (The members one has since been built!)

Some great code improvements has been added by @espellcaste into the BP Blocks plugin. He also suggested we start having regular meetings specific to BuddyPress blocks. So here’s a poll to see if you’re interested about it.

Here are some topics we could discuss about during these specific meetings:

  • How to attract WP Block developers to have fun with BP ones?
  • How to smoothly prepare the Block Based Activity post form merge into Core so that BuddyPress Plugins developer can start working on migrating the feature they add to the legacy post form into the block based one?
  • How BuddyPress could benefit from React, WP React components + BP REST API to improve the user experience?
  • What about a “Block ready” Template pack or a BuddyPress standalone theme?

7.0.0 release schedule

  • 7.0.0-beta1: October 15 💆🏻
  • 7.0.0 : December 1st

Open floor

We’ve been discussing about how to improve the way we communicate towards contributors about features/code improvements added to upcoming BuddyPress releases. @im4th suggested to use this blog to post these kind of updates making sure to use the “Development notes” a sub-category of it for the version number. For instance you can quickly read important changes to expect in BuddyPress 7.0.0 from there: Development notes/7.0.

@IAmTheWebb asked us about how he could update some BP Codex pages. Regular contributors we trust like him can ping me @imath on WP Slack or request an access during our Core dev-chats to make this happen! We are very interested into welcoming new Documentation contributors 🙌 🤝.

Next Dev-Chat

It will happen on October 7 at 19:00 UTC and of course in #BuddyPress. If you have ideas or questions, feel free (and we are strongly encouraging you) to comment this summary to share them!

#7-0-0, #dev-chat, #summary