Re-namespacing a bit to clear out some fairly old stuff from the top level
This commit is contained in:
16
oldstuff/map-mash/app/views/maps/edit.html.erb
Normal file
16
oldstuff/map-mash/app/views/maps/edit.html.erb
Normal file
@@ -0,0 +1,16 @@
|
||||
<h1>Editing map</h1>
|
||||
|
||||
<% form_for(@map) do |f| %>
|
||||
<%= f.error_messages %>
|
||||
|
||||
<p>
|
||||
<%= f.label :name %><br />
|
||||
<%= f.text_field :name %>
|
||||
</p>
|
||||
<p>
|
||||
<%= f.submit 'Update' %>
|
||||
</p>
|
||||
<% end %>
|
||||
|
||||
<%= link_to 'Show', @map %> |
|
||||
<%= link_to 'Back', maps_path %>
|
20
oldstuff/map-mash/app/views/maps/index.html.erb
Normal file
20
oldstuff/map-mash/app/views/maps/index.html.erb
Normal file
@@ -0,0 +1,20 @@
|
||||
<h1>Listing maps</h1>
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<th>Name</th>
|
||||
</tr>
|
||||
|
||||
<% @maps.each do |map| %>
|
||||
<tr>
|
||||
<td><%=h map.name %></td>
|
||||
<td><%= link_to 'Show', map %></td>
|
||||
<td><%= link_to 'Edit', edit_map_path(map) %></td>
|
||||
<td><%= link_to 'Destroy', map, :confirm => 'Are you sure?', :method => :delete %></td>
|
||||
</tr>
|
||||
<% end %>
|
||||
</table>
|
||||
|
||||
<br />
|
||||
|
||||
<%= link_to 'New map', new_map_path %>
|
15
oldstuff/map-mash/app/views/maps/new.html.erb
Normal file
15
oldstuff/map-mash/app/views/maps/new.html.erb
Normal file
@@ -0,0 +1,15 @@
|
||||
<h1>New map</h1>
|
||||
|
||||
<% form_for(@map) do |f| %>
|
||||
<%= f.error_messages %>
|
||||
|
||||
<p>
|
||||
<%= f.label :name %><br />
|
||||
<%= f.text_field :name %>
|
||||
</p>
|
||||
<p>
|
||||
<%= f.submit 'Create' %>
|
||||
</p>
|
||||
<% end %>
|
||||
|
||||
<%= link_to 'Back', maps_path %>
|
8
oldstuff/map-mash/app/views/maps/show.html.erb
Normal file
8
oldstuff/map-mash/app/views/maps/show.html.erb
Normal file
@@ -0,0 +1,8 @@
|
||||
<p>
|
||||
<b>Name:</b>
|
||||
<%=h @map.name %>
|
||||
</p>
|
||||
|
||||
|
||||
<%= link_to 'Edit', edit_map_path(@map) %> |
|
||||
<%= link_to 'Back', maps_path %>
|
Reference in New Issue
Block a user