Planning applications tracker for InLinkUK from BT kiosks. https://kiosks.adrianshort.org/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

18 lines
366 B

  1. def short_date(s)
  2. return if s.nil?
  3. Date.parse(s).strftime("%e %b %Y").gsub(' ', ' ')
  4. end
  5. def cleanup(s)
  6. return if s.nil?
  7. s.sub!('Unknown', '')
  8. s.sub!('Not Available', '')
  9. # s = "<span class=grant>#{s}</span>" if s.match(/approve/i)
  10. # s = "<span class=refuse>#{s}</span>" if s.match(/refuse/i)
  11. s
  12. end
  13. def slug(s)
  14. s.downcase.gsub(' ', '-')
  15. end