GeoRSS aggregator and Layar augmented reality server
25개 이상의 토픽을 선택하실 수 없습니다. Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

52 lines
1.0 KiB

  1. %h1
  2. Layer:
  3. = @layer.name
  4. %p
  5. API URL:
  6. = "#{request.protocol}#{request.host_with_port}/posts/near.json?layer_id=#{@layer.id}"
  7. %h2 Feeds
  8. #new_feed
  9. = render 'subscriptions/form'
  10. %p= link_to "Fetch all", :fetch_all, :class => "button"
  11. %table
  12. %tr
  13. %th
  14. %th Posts
  15. %th Fetched
  16. %th
  17. %th
  18. %th
  19. - @layer.subscriptions.each do |s|
  20. %tr
  21. %td
  22. .feed_title
  23. = link_to s.feed.title, s.feed
  24. %td.right= s.feed.posts.count
  25. %td
  26. - if s.feed.last_fetched.nil?
  27. never
  28. - else
  29. = (time_ago_in_words(s.feed.last_fetched) + " ago").gsub(/ +/, " ").html_safe
  30. %td= link_to "Fetch", fetch_feed_url(s.feed), :class => "button"
  31. %td= link_to 'Edit', edit_feed_path(s.feed), :class => "button"
  32. %td= link_to 'Delete', s, :confirm => "Delete #{s.feed.title}?", :method => :delete, :class => "button"
  33. %tr
  34. %td
  35. %td.right [number of posts in this layer]
  36. %td
  37. %td
  38. %td
  39. %td
  40. = link_to 'Edit', edit_layer_path(@layer)
  41. \|
  42. = link_to 'Back', layers_path