suite
This commit is contained in:
parent
4860ad1290
commit
f642bb86db
@ -347,7 +347,11 @@ class PDocument < ActiveRecord::Base
|
|||||||
|
|
||||||
|
|
||||||
def echeance
|
def echeance
|
||||||
|
if self.created_at?
|
||||||
d = self.created_at
|
d = self.created_at
|
||||||
|
else
|
||||||
|
d = Time.now
|
||||||
|
end
|
||||||
if self.comptant
|
if self.comptant
|
||||||
d
|
d
|
||||||
else
|
else
|
||||||
|
@ -69,7 +69,7 @@ class PPayment < ActiveRecord::Base
|
|||||||
self.p_payment_documents.each do |ppd|
|
self.p_payment_documents.each do |ppd|
|
||||||
r += ppd.amount.to_f
|
r += ppd.amount.to_f
|
||||||
end
|
end
|
||||||
return r
|
return r.round(2)
|
||||||
end
|
end
|
||||||
|
|
||||||
def paid_date_needed?
|
def paid_date_needed?
|
||||||
|
@ -119,11 +119,22 @@
|
|||||||
|
|
||||||
%table.table
|
%table.table
|
||||||
%tr
|
%tr
|
||||||
|
|
||||||
%th Date
|
%th Date
|
||||||
|
%th Offre
|
||||||
|
%th Client
|
||||||
%th Type
|
%th Type
|
||||||
%th Numéro
|
%th Numéro
|
||||||
%th Total HT
|
%th Total HT
|
||||||
%th Total TTC
|
%th Total TTC
|
||||||
|
%th
|
||||||
|
Payée
|
||||||
|
%th Solde
|
||||||
|
%th Echéance
|
||||||
|
|
||||||
|
%th Jours de retard
|
||||||
|
%th
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
%tbody#p_customer_sheets_rows
|
%tbody#p_customer_sheets_rows
|
||||||
|
@ -84,7 +84,7 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
-if !@p_customer_sheet
|
-if !@p_customer_sheet or true
|
||||||
%td
|
%td
|
||||||
=link_to "##{p_document.element.id}", admin_p_customer_sheet_path(p_document.element)
|
=link_to "##{p_document.element.id}", admin_p_customer_sheet_path(p_document.element)
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user