Skip to content

Instantly share code, notes, and snippets.

@lmarburger
Created December 14, 2010 18:30

Revisions

  1. lmarburger revised this gist Dec 14, 2010. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion application.html.erb
    Original file line number Diff line number Diff line change
    @@ -1,3 +1,3 @@
    <%= render :layout => '/layouts/base' do %>
    <%= render :layout => 'layouts/base' do %>
    <%= yield %>
    <% end %>
  2. lmarburger created this gist Dec 14, 2010.
    10 changes: 10 additions & 0 deletions _base.html.erb
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,10 @@
    <!DOCTYPE html>
    <html>
    <head>
    <title>Site</title>
    </head>
    <body class="app">
    <%= render :partial => 'layouts/flashes' %>
    <%= yield %>
    </body>
    </html>
    3 changes: 3 additions & 0 deletions application.html.erb
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,3 @@
    <%= render :layout => '/layouts/base' do %>
    <%= yield %>
    <% end %>
    19 changes: 19 additions & 0 deletions index.html.erb
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,19 @@
    <h1>Listing projects</h1>

    <table id="projects">
    <tr>
    <th>Name</th>
    <th></th>
    </tr>

    <% @projects.each do |project| %>
    <tr>
    <td><%= link_to project.name, project %></td>
    <td><%= link_to 'Destroy', project, :confirm => 'Are you sure?', :method => :delete %></td>
    </tr>
    <% end %>
    </table>

    <br />

    <%= link_to 'New Project', new_project_path %>