riparias/gbif-alert

List data imports by datetime in drop down menu

Closed this issue · 1 comments

@bramdhondt found this issue, which is worth to be reported.

At the moment the data imports in drop down menu are ordered alphabetically by column Name, actually the only column of the table.
Doing this a typical problem arises: 10, 100, 101, 110, ... appear before 2. 20, 200, 201, ... appear before 3 etc.
Or, if you flip the order, 99 come before 9, etc.
Screenshot from the LIFE RIPARIAS Alert tool instance of GBIF Alert follows at the end of the issue.

I suggest to:

  1. Add column Datetime.
  2. Move datetime information from column Name to column Datetime.
  3. Order the imports by Datetime, most recent first by default

The dropdown menu would look like this (again, using the LFIE RIPARIAS Alert tool as example):

Name Datetime
Data import # 457 July 27, 2023, 1:26 a.m.
Data import # 456 July 26, 2023, 1:29 a.m.
Data import # 455 July 25, 2023, 1:35 a.m.
... ...
Data import # 102 July 30, 2022, 1:01 a.m.
Data import # 101 July 29, 2022, 1:02 a.m.
Data import # 100 July 28, 2022, 1:01 a.m.
... ...
Data import # 20 May 8, 2022, 1:01 a.m.
... ...
Data import # 11 April 29, 2022, 1:01 a.m.
Data import # 10 April 28, 2022, 1:01 a.m.
... ...
Data import # 3 April 21, 2022, 1:01 a.m.
Data import # 2 April 20, 2022, 1:01 a.m.
Data import # 1 April 19, 2022, 9:53 a.m.

image

That's been fixed now, thanks @damianooldoni and @bramdhondt for the report!