fireho/geopolitical

View on GitHub
app/views/geopolitical/hoods/index.html.haml

Summary

Maintainability
Test Coverage
.container
  .row
    .page-header
      %h1.title Hoods
      =# render "shared/filter"
      = link_to "New Hood", new_hood_path
  .row
    .content
      %table.table
        %thead
          %tr
            %th Nome
            %th Region
            %th Nation
            %th Population
            %th
        %tbody
          - for hood in @hoods
            %tr
              %td
                = hood.name
                = link_to hood.slug , hood
              %td= hood.city.name if hood.city
              %td= hood.city.name
              %td= hood.souls
              %td{:align => 'right'}
                = link_to 'Edit', edit_hood_path(hood)
                = link_to 'Destroy', hood, :confirm => 'Destroy hood?', :method => :delete

  .row
    .pagination= paginate @hoods
  .row
    = link_to 'Back', root_path