openstreetmap / openstreetmap-website

The Rails application that powers OpenStreetMap
https://www.openstreetmap.org/
GNU General Public License v2.0
2.15k stars 908 forks source link

Sorting the blocks given to the users by date and time created #1202

Open jinalfoflia opened 8 years ago

jinalfoflia commented 8 years ago

I was looking for the latest blocks given by Peda to different OpenStreetMap users. I expected that the list will have them listed by the latest block given on the top and then followed by the others. What I found was that the first one was created 5 months ago, the second one was created 3 months ago and the third one being created 4 months ago. I'm unable to identify the sorting parameter used for listing these blocks.

It will be great if they are sorted based on the date and time the blocks were created. Which will make it easy to identify the latest block given.

tomhughes commented 8 years ago

They're sorted by the time when they end, in descending order.

For the most part that is more or less equivalent to sorting by creation time, obviously with some minor variation based on the length of the block.

What it does mean though is that a very long block stays at the top, which is good in the sense that it stops such blocks vanishing down the list, but bad in that it can be a bit confusing. Such blocks are rare though as they have to be created manually by me as 96 hours is the longest a block can be via the normal route.

jinalfoflia commented 8 years ago

What it does mean though is that a very long block stays at the top, which is good in the sense that it stops such blocks vanishing down the list

@tomhughes thank you! It's good to know the logic behind sorting the list.

but bad in that it can be a bit confusing

That is true that it is a bit confusing. Can we have another column along with Blocked User , Reason for the block, Status and Revokes By which gives the date at which the block was created. This would make it less confusing and give more context.

screen_shot_2016-04-15_at_11_28_56_am

SomeoneElseOSM commented 8 years ago

Personally I'd just be happy to know the actual times involved without any of this "6 months ago" stuff :)

(see also https://github.com/openstreetmap/openstreetmap-website/issues/631 )