Make WordPress Core

Opened 21 years ago

Closed 20 years ago

Last modified 19 years ago

#1511 closed defect (bug) (invalid)

Users page should sort by role seniority, not by role alphabetically. [PATCH]

Reported by: davidhouse's profile davidhouse Owned by: skippy's profile skippy
Milestone: Priority: normal
Severity: minor Version: 1.6
Component: Administration Keywords: bg|has-patch bg|commit
Focuses: Cc:

Description

On the users page, the users list is currently sorted by role alphabetically. This isn't very useful, I expect roles to be sorted by how senior they are. I.e., the administrator is at the top, and it goes down through editor, author, then contributor, finally subscriber and then inactive.

The attached diff does this.

Attachments (1)

role-seniority.diff (1.5 KB) - added by davidhouse 21 years ago.
Sort alphabetically within roles

Download all attachments as: .zip

Change History (9)

#1 @skippy
21 years ago

  • Keywords bg|has-patch bg|dev-feedback bg|2nd-opinion added
  • Milestone set to 1.6
  • Owner changed from anonymous to skippy
  • Status changed from new to assigned

#2 @davidhouse
21 years ago

New patch. Sort alphabetically within roles.

@davidhouse
21 years ago

Sort alphabetically within roles

#3 @markjaquith
21 years ago

  • Keywords bg|commit added; bg|dev-feedback bg|2nd-opinion removed

I like it.

See also #1660 for a related issue (where the roles weren't being properly assigned)

#4 @ringmaster
21 years ago

Two points:

1.Removing and re-adding a role would reorganize the role list so the concept of seniority (which is only coincidal from the way the roles are added by the installer) wouldn't be true.

2.There is no intrinsic indicator in the name of a role that one role is greater than another, so seniority of a role is not apparent to a user from its name.

Consider - you are looking at an English dictionary in which the words are ordered by some number of "seniority" I have applied to each word. This number is not visible anywhere near the word's definition. Choose a word, open to a random page, and then tell me if the word you chose appears before or after that random page.

So although you might be able to organize roles using the order they appear in the database, there is no indicator to the user that the roles are sorted that way, or what the sort value is for the role they're looking for, especially if they've customized the roles.

Don't commit this patch - sort by alpha only.

#5 @MichaelH
20 years ago

It doesn't really sort in alpha either. Here's the User List by Role order:

Administrator
ID 	Username 
1 	admin 
12 	level10
9 	level8 
24 	level8a
10 	level9 
25 	level9a

Contributor
ID 	Username 
2 	level1 	
18 	level1a 


Author
ID 	Username 
3 	level2 	
17 	level2a 
4 	level3 	
20 	level3a 
5 	level4 	
26 	level4a 

Editor
ID 	Username 
6 	level5 	
7 	level6 	
22 	level6a 
8 	level7 	
23 	level7a 

Subscriber
ID 	Username 
11 	level0 


ID 	Username 	
31 	added1.6user

#6 @matt
20 years ago

  • Milestone changed from 1.6 to 2.1

#7 @davidhouse
20 years ago

  • Resolution set to invalid
  • Status changed from assigned to closed

Calling invalid as we've declared before that the new system isn't meant to be any kind of hierarchy. As ringmaster said, plugins messing around with roles will probably break things anyway. Reopen if anyone can argue for this bug.

#8 @Nazgul
19 years ago

  • Milestone 2.1 deleted
Note: See TracTickets for help on using tickets.