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.0.60 app/views/tenon/events/index.json.jbuilder
tenon-1.0.59 app/views/tenon/events/index.json.jbuilder
tenon-1.0.57 app/views/tenon/events/index.json.jbuilder
tenon-1.0.56 app/views/tenon/events/index.json.jbuilder
tenon-1.0.55 app/views/tenon/events/index.json.jbuilder
tenon-1.0.54 app/views/tenon/events/index.json.jbuilder
tenon-1.0.53 app/views/tenon/events/index.json.jbuilder
tenon-1.0.52 app/views/tenon/events/index.json.jbuilder
tenon-1.0.51 app/views/tenon/events/index.json.jbuilder
tenon-1.0.50 app/views/tenon/events/index.json.jbuilder
tenon-1.0.49 app/views/tenon/events/index.json.jbuilder
tenon-1.0.48 app/views/tenon/events/index.json.jbuilder
tenon-1.0.47 app/views/tenon/events/index.json.jbuilder
tenon-1.0.46 app/views/tenon/events/index.json.jbuilder
tenon-1.0.45 app/views/tenon/events/index.json.jbuilder
tenon-1.0.44 app/views/tenon/events/index.json.jbuilder
tenon-1.0.43 app/views/tenon/events/index.json.jbuilder
tenon-1.0.42 app/views/tenon/events/index.json.jbuilder
tenon-1.0.41 app/views/tenon/events/index.json.jbuilder
tenon-1.0.40 app/views/tenon/events/index.json.jbuilder