2017-05-18 01:21:04 +02:00

98 lines
2.0 KiB
Plaintext
Executable File

-@read_only = true
.center.padding
%h2= @customer.pseudo_admin
.row
.col-md-6
%table.table.table-striped
%tbody
%tr
%td
Date d'inscription :
%td
=l @customer.created_at, :format => :date
%tr
%td
Dernière activité
%td
=time_ago_in_words(@customer.last_activity) if @customer.last_activity
%tr
%td
Organisation :
%td
=@customer.organisation
%tr
%td
Nom :
%td
=@customer.name
%tr
%td
Prénom :
%td
=@customer.firstname
%tr
%td
Téléphone :
%td
=@customer.phone
%tr
%td
Email :
%td
=link_to @customer.email, "mailto:#{@customer.email}"
.col-md-6
%table.table.table-striped
%tbody
%tr
%td
Adresse :
%td=@customer.address
%tr
%td
Adresse (suite) :
%td
=@customer.address2
%tr
%td
Code postal
%td
=@customer.cp
%tr
%td
Ville :
%td
=@customer.city
%h3 Offres acceptées par ce membre
%table.table.table-hover.table-striped.customer_table
%tr
%th Besoin
%th Offre
-@customer.accepted_offers.joins(:offer).where(:state => "documents_completed").each do |accepted_offer|
%tr
%td
=link_to accepted_offer.offer.need.title.upcase, public_need_path(accepted_offer.offer.need)
%td=number_to_currency accepted_offer.offer.price
%h3 Intérêts de ce membre
=render collection: @customer.needs, partial: 'public/needs/need_item', as: :need
.clear