agenda-libre-ruby/app/views/lugs/index.html.haml

37 lines
875 B
Plaintext
Raw Normal View History

%h2
%em.fa.fa-users
= title t 'lugs.search.title', entity: Lug.model_name.human
2014-07-27 01:50:22 +02:00
= render 'search'
%table.list.autopagerize_page_element
%thead
%th= sort_link @search, :name
%th= sort_link @search, :city
%th= sort_link @search, :department
%th= sort_link @search, :region_name, Lug.human_attribute_name(:region)
2014-07-27 01:50:22 +02:00
%th= sort_link @search, :url
%th/
%tbody
- @lugs.each do |lug|
%tr
%td
- if lug.url =~ /^http/
= image_tag lug.url + '/favicon.ico', alt: '', class: :favicon
2014-07-27 01:50:22 +02:00
= lug.name
%td
= lug.city
%td
= lug.department
%td
= lug.region
2014-07-27 01:50:22 +02:00
%td
= link_to lug.url, lug.url
%td
= link_to t('show'),
lug_path(lug, q: params[:q], page: params[:page]),
class: :view_link
2014-07-27 01:50:22 +02:00
= paginate @lugs