WordPress.org

Make WordPress Core

Opened 3 years ago

Closed 3 years ago

Last modified 3 years ago

#41165 closed enhancement (fixed)

Add 'Super Admin' label to all user list tables

Reported by: johnbillion Owned by: johnbillion
Milestone: 4.9 Priority: normal
Severity: normal Version: 3.0
Component: Users Keywords: has-patch
Focuses: administration, multisite Cc:

Description

When a user is a Super Admin, they should be identified as so on all user list tables. Currently the Super Admin label only appears on the Network Admin -> Users screen (next to the user's username).

Affects:

  • Network Admin -> Sites -> Edit -> Users
  • Users screen in each site's dashboard.

The label should only be shown to users with the manage_network_users capability.

Attachments (6)

41165.diff (1.3 KB) - added by partyfrikadelle 3 years ago.
Diff for wp-admin/includes/class-wp-users-list-table.php (#41165)
41165.2.diff (696 bytes) - added by partyfrikadelle 3 years ago.
Patch fix
41165.3.diff (715 bytes) - added by partyfrikadelle 3 years ago.
Final Patch - sorry for spamming
41165.4.diff (696 bytes) - added by partyfrikadelle 3 years ago.
The next Patch i submit will be better checked before submitting. Promised!
41165.patch (730 bytes) - added by yahil 3 years ago.
I have made changes on existing .path to improve coding standard.
41165.5.diff (2.6 KB) - added by johnbillion 3 years ago.

Download all attachments as: .zip

Change History (11)

@partyfrikadelle
3 years ago

Diff for wp-admin/includes/class-wp-users-list-table.php (#41165)

#1 @partyfrikadelle
3 years ago

This is my first commit. Be gentle ;-)

Just added a simple extension of the both mentioned user-screens underlying get_role_list Function. Pretty simple.

@partyfrikadelle
3 years ago

Patch fix

@partyfrikadelle
3 years ago

Final Patch - sorry for spamming

@partyfrikadelle
3 years ago

The next Patch i submit will be better checked before submitting. Promised!

#2 @DrewAPicture
3 years ago

  • Keywords has-patch added; needs-patch removed
  • Owner set to partyfrikadelle
  • Status changed from new to assigned

Assigning to mark the good-first-bug as "claimed".

@partyfrikadelle Welcome to Core Trac! Don't sweat mistakes too much. We were all first-time contributors at some point. We're happy to do a little hand-holding now and again :-)

Now that you've uploaded a patch, the next step is to wait for developer feedback from @johnbillion.

@yahil
3 years ago

I have made changes on existing .path to improve coding standard.

#3 @johnbillion
3 years ago

  • Keywords good-first-bug removed
  • Milestone changed from Awaiting Review to 4.9
  • Owner changed from partyfrikadelle to johnbillion
  • Status changed from assigned to reviewing

@johnbillion
3 years ago

#4 @johnbillion
3 years ago

  • Resolution set to fixed
  • Status changed from reviewing to closed

In 41150:

Users: Show a Super Admin label next to Super Admins on all user listing screens when the current user can manage network users.

Fixes #41165

#5 @johnbillion
3 years ago

@partyfrikadelle thanks for the patches, but this label needs to be shown next to the username so it's consistent with the same behaviour on the network admin users listing screen. I fixed up the patch in [41150] and this will be in 4.9.

Note: See TracTickets for help on using tickets.