Sha256: 527fa183156430d799ba83347eaa822aeaf1eb8e1e8a864e23cfd942b437d8e3

Contents?: true

Size: 1.61 KB

Versions: 3

Compression:

Stored size: 1.61 KB

Contents

<div class="page-header">
  <h2><%= params[:db_name] %> collections</h2>
</div>

<ul class="nav nav-tabs">
  <li class="active">
    <a href="#collections" data-toggle="tab">Collections</a>
  </li>
  <li><a href="#stats" data-toggle="tab">Stats</a></li>
</ul>

<div class="tab-content">
  <div class="tab-pane active" id="collections">
    <%= erb :"shared/_filter", {}, { filter_for: "collections", placeholder: "Collection name" } %>

    <table class="table table-striped table-hover collections">
      <thead>
      <tr>
        <th>Name</th>
        <th>Size</th>
        <th class="actions">&nbsp;</th>
      </tr>
      </thead>
      <tbody>
      <% @collections.each do |collection| %>
        <tr class="collection">
          <td><a href="/databases/<%= params[:db_name] %>/collections/<%= collection.name %>"><%= collection.name %></a></td>
          <td><%= collection.size %></td>
          <td>
            <a href="/databases/<%= params[:db_name] %>/collections/<%= collection.name %>" class="btn btn-danger" data-method="delete" data-confirm="Are you sure?">
              <i class="icon-remove-circle"></i>
              Delete
            </a>
          </td>
        </tr>
      <% end %>
      </tbody>
    </table>
  </div>

  <div class="tab-pane" id="stats">
    <table class="table table-striped table-hover">
      <thead>
      <tr>
        <th>Property</th>
        <th>Value</th>
      </tr>
      </thead>
      <tbody>
      <% @stats.each do |property, value| %>
        <tr>
          <td><%= property %></td>
          <td><%= value %></td>
        </tr>
      <% end %>
      </tbody>
    </table>
  </div>
</div>

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
mongo_browser-0.1.3 app/views/collections/index.erb
mongo_browser-0.1.2 app/views/collections/index.erb
mongo_browser-0.1.1 app/views/databases/show.erb