diff options
Diffstat (limited to 'app/views/events/index.html.erb')
-rw-r--r-- | app/views/events/index.html.erb | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/app/views/events/index.html.erb b/app/views/events/index.html.erb new file mode 100644 index 0000000..654d317 --- /dev/null +++ b/app/views/events/index.html.erb @@ -0,0 +1,18 @@ +<p style="color: green"><%= notice %></p> + +<h1>Events</h1> + +<%= link_to "New event", new_event_path %> + +<table class="table table-success table-striped table-bordered mt-2"> + <tr> + <th>Date</th> + <th>Name</th> + </tr> + <% @events.each do |e| %> + <tr> + <td><%= e.name %></td> + <td><%= e.date.to_formatted_s(:rfc822) %></td> + </tr> + <% end %> +</table> |