noesya/osuny

View on GitHub
app/views/admin/communication/websites/show/_events.html.erb

Summary

Maintainability
Test Coverage
<%
title = t('communication.website.last_events')
action = ''
action += link_to t('create'),
                  new_admin_communication_website_agenda_event_path(website_id: @website),
                  class: button_classes if can?(:create, Communication::Website::Agenda::Event)
%>
<%= osuny_panel title, action: action do %>
  <%= render 'admin/communication/websites/agenda/events/list',
              events: @events,
              small: true %>  
  <%= link_to t('communication.website.see_all', number: @all_events.size), 
              admin_communication_website_agenda_events_path(website_id: @website) if @all_events.any? %>
<% end %>