Multisite: Make view mode sticky for network users and sites list tables.
Fixes #34365. Built from https://develop.svn.wordpress.org/trunk@36562 git-svn-id: http://core.svn.wordpress.org/trunk@36529 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
e7a7f08c8b
commit
3e14571132
|
@ -69,7 +69,12 @@ class WP_MS_Sites_List_Table extends WP_List_Table {
|
|||
|
||||
$current_site = get_current_site();
|
||||
|
||||
$mode = ( empty( $_REQUEST['mode'] ) ) ? 'list' : $_REQUEST['mode'];
|
||||
if ( ! empty( $_REQUEST['mode'] ) ) {
|
||||
$mode = $_REQUEST['mode'] === 'excerpt' ? 'excerpt' : 'list';
|
||||
set_user_setting ( 'sites_list_mode', $mode );
|
||||
} else {
|
||||
$mode = get_user_setting ( 'sites_list_mode', 'list' );
|
||||
}
|
||||
|
||||
$per_page = $this->get_items_per_page( 'sites_network_per_page' );
|
||||
|
||||
|
|
|
@ -81,7 +81,12 @@ class WP_MS_Users_List_Table extends WP_List_Table {
|
|||
if ( isset( $_REQUEST['order'] ) )
|
||||
$args['order'] = $_REQUEST['order'];
|
||||
|
||||
$mode = empty( $_REQUEST['mode'] ) ? 'list' : $_REQUEST['mode'];
|
||||
if ( ! empty( $_REQUEST['mode'] ) ) {
|
||||
$mode = $_REQUEST['mode'] === 'excerpt' ? 'excerpt' : 'list';
|
||||
set_user_setting ( 'network_users_list_mode', $mode );
|
||||
} else {
|
||||
$mode = get_user_setting ( 'network_users_list_mode', 'list' );
|
||||
}
|
||||
|
||||
/** This filter is documented in wp-admin/includes/class-wp-users-list-table.php */
|
||||
$args = apply_filters( 'users_list_table_query_args', $args );
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '4.5-alpha-36561';
|
||||
$wp_version = '4.5-alpha-36562';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
|
Loading…
Reference in New Issue