app/views/schools/subscription_generation_runs/show.html.erb
<% content_for :page_title, "Email and SMS for #{@school.name}" %>
<div class="row padded-row">
<div class="col-md-12">
<h1>Messages sent</h1>
<h2><%= link_to @school.name, @school %></h2>
<p>These are all the actions taken by Energy Sparks for your alert subscriptions</p>
<p><%= link_to 'Alert Contacts', school_contacts_path(@school), class: 'btn btn-primary' %></p>
</div>
</div>
<div class="table-responsive">
<table class="table table-striped table-sm">
<thead>
<tr>
<th>Contact</th>
<th>Alert Type</th>
<th>Created At</th>
<th>Error Message</th>
<th>Sent on</th>
<th>Sent message</th>
<th>Priority</th>
<th></th>
</tr>
</thead>
<%= render 'table', school: @school, alert_subscription_events: @sent_emails, name: 'Sent emails'%>
<%= render 'table', school: @school, alert_subscription_events: @sent_sms, name: 'Sent SMS' %>
<%= render 'table', school: @school, alert_subscription_events: @pending_emails, name: 'Pending emails' %>
<%= render 'table', school: @school, alert_subscription_events: @pending_sms, name: 'Pending SMS'%>
</table>
</div>