Scroll through full user list?

(Allen - Watchman Monitoring) #1

[quote=“watchmanmonitor, post:1, topic:22672, full:true”]
The full list is 200 people (which I think is too short) [/quote]

When I’m at the main user list in the admin page, I can see 100 users. Is there a reason not to allow this list to scroll to 200, or more?

Using the api for user management (the 100 user limit)
(Jeff Atwood) #2

If scrolling, no reason other than hasn’t been requested or needed to date. But the performance of showing 200 at once is abysmal.

(Mittineague) #3

I agree, showing additional AJAX loaded content after scrolling results, like topics do, would be ideal. Or if not that, some way to get at the results via a limit-offset thing like discussed a couple of weeks ago here could work.

It makes little sense to have data but not be able to get at it some way.

(Jeff Atwood) #4

You can get to it via exporting user data; @techapj just submitted a patch to make exports work in more sub tabs!

(TechnoBear) #5

“Export” only works for Admins; it’s not much help to other moderators.

(Mittineague) #6

My plan was for us to continuously pester @HAWK to provide them for us.

Seeing as the displayed data is limited, I figure once per 24 hours should be adequate.


I’m fine with that, but it doesn’t seem like an especially robust solution.

(Allen - Watchman Monitoring) #8

Right now I have to export a list to see all the people who are approved, but not activated

being able to scroll would be so much better.

(Dan Dascalescu) #9

I would also like the ability to scroll through the full list of (filtered) users in /admin/users.

Anyway, a real UX problem is that there’s no indication that the results are limited to the first 100 matches. This was misleading when I tried to see how many users from a certain domain had registered and eyeballing indicated about 90-100. In reality there were over 400 users, which changes the dimension of the problem somewhat (have moderators send custom welcomes).

(Jeff Atwood) #10

Just export the full user list via Admin, Users, Export.

(Dan Dascalescu) #11

Three problems:

  1. That exports the entire list. I wanted to see how many users matched the filter.
  2. Exporting doesn’t resolve the fact that there’s no indication as to the size of the filter results.
  3. The export file is a full CSV dump with all the fields (less user friendly than what a moderator would like), and there’s no clickable link to go to a user’s profile

(Allen - Watchman Monitoring) #12

Given how awesome the rest of discourse is, how is this even an answer?

(Mittineague) #13

I put together an admittedly hackish PHP script for personal use early on (about a year and a half ago)

32,908 KB
219952 users

I then created my own “filters” using the available fields

if (($handle = fopen($csv_file, "r")) !== FALSE) {
	$user_arr = [];
    while (($data = fgetcsv($handle, 1000, ",")) !== FALSE) {
	$user_arr[$data[0]] = ['name' =>	 	(!empty($data[1])) ? $data[1] : "no name",
				'username' =>  		(!empty($data[2])) ? $data[2] : "no username",
				'email' => 		(!empty($data[3])) ? $data[3] : "no email",
				'title' =>  		(!empty($data[4])) ? $data[4] : "no title",
				'created_at' =>  	(!empty($data[5])) ? $data[5] : "no created_at",
				'trust_level' =>  	(!empty($data[6])) ? $data[6] : "no trust_level",
				'active' =>  		(!empty($data[7])) ? $data[7] : "no active",
				'admin' =>  		(!empty($data[8])) ? $data[8] : "no admin",
				'moderator' =>  	(!empty($data[9])) ? $data[9] : "no moderator",
				'ip_address' =>  	(!empty($data[10])) ? $data[10] : "no ip_address",
				'topics_entered' => 	(!empty($data[11])) ? $data[11] : "no topics_entered",
				'posts_read_count' =>	(!empty($data[12])) ? $data[12] : "no posts_read_count",
				'time_read' =>  	(!empty($data[13])) ? $data[13] : "no time_read",
				'topic_count' => 	(!empty($data[14])) ? $data[14] : "no topic_count",
				'post_count' =>  	(!empty($data[15])) ? $data[15] : "no post_count",
				'likes_given' =>  	(!empty($data[16])) ? $data[16] : "no likes_given",
				'likes_received' => 	(!empty($data[17])) ? $data[17] : "no likes_received",
				'group_names' =>  	(!empty($data[18])) ? $data[18] : "no group_names"

* “0” is the id field

(Dan Dascalescu) #14

Here’s a simple Node.js script to delete users that match a given (spam) domain. It makes repeated API requests to bypass the 100 users limit. I wrote more about it at

(Jeff Atwood) #15

I dunno, have you ever scrolled through all Google search results? Sometimes, the question is wrong.

(Allen - Watchman Monitoring) #16

The google search results aren’t paying members of the close forum(s) I manage.

(Mittineague) #17

Is this something the Data Explorer plugin could make easy work of?

(Dan Dascalescu) #18

Again, Google does indicate there are more than 10 search results. Discourse’s admin does not.

Also, Discourse already has the code to page through users, as can be seen at Discourse Meta.

(cpradio) #19

Yes. @dandv, if you can tell me what you typically filter by (or want to be able to filter by), I can create a Data Explorer Query to return what you want.

(Dan Dascalescu) #20

Not sure if the reply above was for me or @Mittineague, but I want to filter by username or email address.

What I’m a little surprised by is how come it’s so difficult to reuse the Ember code that does user pagination at /users/ to /admin/users/list/.