Browse Source

Add CSV download to decisions page

main
Adrian Short 5 years ago
parent
commit
ef4464d90b
2 changed files with 6 additions and 1 deletions
  1. +3
    -1
      lib/site.rb
  2. +3
    -0
      views/decisions.haml

+ 3
- 1
lib/site.rb View File

@@ -20,7 +20,9 @@ class Site

# Latest decisions page
apps = ScraperWiki.select("* from `applications` order by date_decision desc limit 30")
Petrify.page('decisions', 'decisions', { apps: apps })
path = 'decisions'
Petrify.page(path, 'decisions', { apps: apps })
Petrify.csv(path, 'inlink-decisions', apps)
# Appeals page
summary = ScraperWiki.select("


+ 3
- 0
views/decisions.haml View File

@@ -1,4 +1,7 @@
%h1 Latest decisions

= download_button('inlink-decisions.csv')

%table
%thead
%tr


Loading…
Cancel
Save