Sha256: 8c686daea76d927b9cffd740222f7d1ca1c403bd8d1dd109af060b6bb4126f88

Contents?: true

Size: 464 Bytes

Versions: 79

Compression:

Stored size: 464 Bytes

Contents

json.records do
  json.array!(@events) do |event|
    json.extract!(event, :id, :title, :display_date, :location, :edit_path, :edit_link, :delete_link)

    if event.published? && main_app.respond_to?(:event_path)
      json.view_link action_link("View on Site", main_app.event_path(event), "laptop")
    end

  end
end

json.pagination do
  json.currentPage @events.current_page
  json.totalPages @events.total_pages
  json.totalEntries @events.total_entries
end

Version data entries

79 entries across 79 versions & 1 rubygems

Version Path
tenon-1.1.4 app/views/tenon/events/index.json.jbuilder
tenon-1.1.3 app/views/tenon/events/index.json.jbuilder
tenon-1.1.2 app/views/tenon/events/index.json.jbuilder
tenon-1.1.1 app/views/tenon/events/index.json.jbuilder
tenon-1.0.76 app/views/tenon/events/index.json.jbuilder
tenon-1.0.75 app/views/tenon/events/index.json.jbuilder
tenon-1.0.74 app/views/tenon/events/index.json.jbuilder
tenon-1.0.73 app/views/tenon/events/index.json.jbuilder
tenon-1.0.72 app/views/tenon/events/index.json.jbuilder
tenon-1.0.71 app/views/tenon/events/index.json.jbuilder
tenon-1.0.70 app/views/tenon/events/index.json.jbuilder
tenon-1.0.69 app/views/tenon/events/index.json.jbuilder
tenon-1.0.68 app/views/tenon/events/index.json.jbuilder
tenon-1.0.67 app/views/tenon/events/index.json.jbuilder
tenon-1.0.66 app/views/tenon/events/index.json.jbuilder
tenon-1.0.65 app/views/tenon/events/index.json.jbuilder
tenon-1.0.64 app/views/tenon/events/index.json.jbuilder
tenon-1.0.63 app/views/tenon/events/index.json.jbuilder
tenon-1.0.62 app/views/tenon/events/index.json.jbuilder
tenon-1.0.61 app/views/tenon/events/index.json.jbuilder