Improve information displayed in a network's sites list table

* Better support for arbitrary domain/path combinations by displaying the URL in the primary column rather than Path or Domain.
* Show a cached count of total users per site as a more useful data point rather than the first 5 users.
* Clear that cached count of users for a site when a user is added to the site via `add_user_to_blog()`.

Props @ocean90.
Fixes #32434.

Built from https://develop.svn.wordpress.org/trunk@32718


git-svn-id: http://core.svn.wordpress.org/trunk@32688 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Jeremy Felt
2015-06-10 06:50:25 +00:00
parent 005d937ce2
commit 93ff65e677
7 changed files with 43 additions and 27 deletions

View File

@@ -204,6 +204,7 @@ function add_user_to_blog( $blog_id, $user_id, $role ) {
*/
do_action( 'add_user_to_blog', $user_id, $role, $blog_id );
wp_cache_delete( $user_id, 'users' );
wp_cache_delete( $blog_id . '_user_count', 'blog-details' );
restore_current_blog();
return true;
}