codeforIATI / org-id-finder

🔍 Search organisation names to find their organisation identifiers (and vice versa)
https://org-id-finder.codeforiati.org
MIT License
1 stars 1 forks source link

Record “last successful fetch”; display on frontend #5

Closed andylolz closed 6 years ago

andylolz commented 6 years ago

The scraper should store a record of runs, including a timestamp (or two – started_at and ended_at) and whether the run was successful. Then on the frontend, we can run this sort of query:

SELECT `started_at`
  FROM `scraper_run`
  WHERE success = true
  ORDER BY `started_at` DESC
  LIMIT 1

…In order to display to end users how up-to-date the data is.

andylolz commented 6 years ago

Fixed in b7dcb4ea3319ac5c72134cf475b266a8d7d55f59.