foodsoft/app/views/suppliers/shared_suppliers.html.haml

26 lines
916 B
Text
Raw Normal View History

2013-02-07 16:30:47 +01:00
- title t('.title')
= t('.body').html_safe
2009-01-06 11:49:19 +01:00
2012-10-17 20:45:52 +02:00
%table.table.table-striped
%thead
2009-01-06 11:49:19 +01:00
%tr
2013-10-09 23:12:26 +02:00
%th= heading_helper Supplier, :name
%th= heading_helper Supplier, :address
%th= heading_helper Supplier, :note
%th= heading_helper Supplier, :delivery_days
%th= heading_helper Supplier, :is_subscribed
2012-10-17 20:45:52 +02:00
%tbody
2009-01-06 11:49:19 +01:00
- for shared_supplier in @shared_suppliers
2012-10-17 20:45:52 +02:00
%tr
%td= shared_supplier.name
%td= shared_supplier.address
%td= shared_supplier.note
%td= shared_supplier.delivery_days
%td
- if shared_supplier.suppliers.any?
2012-10-17 20:45:52 +02:00
%i.icon-ok
= associated_supplier_names(shared_supplier)
= link_to t('.subscribe_again'), new_supplier_path(:shared_supplier_id => shared_supplier), class: 'btn'
2012-10-17 20:45:52 +02:00
- else
2013-02-07 16:30:47 +01:00
= link_to t('.subscribe'), new_supplier_path(:shared_supplier_id => shared_supplier), class: 'btn'