Sha256: 1d385634521d8e1f40974980e27c8484452094f96a5cc507c0dbc619a0b18616

Contents?: true

Size: 1.77 KB

Versions: 1

Compression:

Stored size: 1.77 KB

Contents

<div class='toolbar'>
  <ul class='actions'>
    <li>
      <p><%= button_link_to "New Retailer", new_object_url, :icon => 'add' %></p>
    </li>
  </ul>
  <br class='clear' />
</div>


<h1>Listing Retailers</h1>

<table class="index">
  <thead>
	<tr>
    	<th><%= sort_link @search, :name %></th>
    	<th><%= sort_link @search, :address %></th>
    	<th><%= sort_link @search, :state %></th>
    	<th><%= sort_link @search, :email %></th>
    	<th><%= sort_link @search, :phone %></th>
    	<th><%= t("action") %></th>
	</tr>
  </thead>
  <tbody>
    <%- @collection.each do |retailer|%>
    <tr id="<%= dom_id retailer %>">
      <td width="200px"><%= link_to retailer.name, object_url(retailer) %></td>
      <td><%= retailer.address %></td>
      <td><%= retailer.state %></td>
      <td><%= retailer.email %></td>
      <td><%= number_to_phone retailer.phone %></td>
      <td class="actions">
      	<%= link_to_edit retailer %> &nbsp;
      	<%= link_to_delete retailer %> &nbsp;
      </td>
    </tr>
    <% end %>
  </tbody>
</table>

<%= paginate @collection %>


<% content_for :sidebar do %>
<div class="box">
  <h3><%= t(:search) %></h3>

  <% @retailer = Spree::Retailer.metasearch %>
  <%= form_for [:admin, @retailer] do |f| %>
    <p>
      <label><%= t '.name_contains' %></label><br />
      <%= f.text_field :name_contains, :size => 25 %>
    </p>
    <p>
      <label><%= t '.email_contains' %></label><br />
      <%= f.text_field :email_contains, :size => 25 %>
    </p>
    <p>
      <label><%= t '.country_contains' %></label><br />
      <%= f.text_field :country_contains, :size => 25 %>
    </p>
    <p>
      <label><%= t '.state_contains' %></label><br />
      <%= f.text_field :state_contains, :size => 25 %>
    </p>
    <p><%= button t("search") %></p>
  <% end %>
</div>
<% end %>

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
spree_retailers-1.0.0.0 app/views/spree/admin/retailers/index.html.erb