mirror of
https://github.com/LaCasemate/fab-manager.git
synced 2025-01-17 06:52:27 +01:00
basic avoir invoice for wallet credit
This commit is contained in:
parent
b44089a33d
commit
9190e61f5f
@ -37,10 +37,12 @@ module PDF
|
||||
if Setting.find_by({name: 'invoice_code-active'}).value == 'true'
|
||||
text I18n.t('invoices.code', CODE:Setting.find_by({name: 'invoice_code-value'}).value), :leading => 3
|
||||
end
|
||||
if invoice.is_a?(Avoir)
|
||||
text I18n.t('invoices.order_number', NUMBER:invoice.invoice.order_number), :leading => 3
|
||||
else
|
||||
text I18n.t('invoices.order_number', NUMBER:invoice.order_number), :leading => 3
|
||||
if invoice.invoiced_type != WalletTransaction.name
|
||||
if invoice.is_a?(Avoir)
|
||||
text I18n.t('invoices.order_number', NUMBER:invoice.invoice.order_number), :leading => 3
|
||||
else
|
||||
text I18n.t('invoices.order_number', NUMBER:invoice.order_number), :leading => 3
|
||||
end
|
||||
end
|
||||
if invoice.is_a?(Avoir)
|
||||
text I18n.t('invoices.refund_invoice_issued_on_DATE', DATE:I18n.l(invoice.avoir_date.to_date))
|
||||
@ -68,7 +70,11 @@ module PDF
|
||||
# object
|
||||
move_down 25
|
||||
if invoice.is_a?(Avoir)
|
||||
object = I18n.t('invoices.cancellation_of_invoice_REF', REF: invoice.invoice.reference)
|
||||
if invoice.invoiced_type == WalletTransaction.name
|
||||
object = I18n.t('invoices.wallet_credit')
|
||||
else
|
||||
object = I18n.t('invoices.cancellation_of_invoice_REF', REF: invoice.invoice.reference)
|
||||
end
|
||||
else
|
||||
case invoice.invoiced_type
|
||||
when 'Reservation'
|
||||
|
@ -68,6 +68,7 @@ en:
|
||||
order_number: "Order #: %{NUMBER}"
|
||||
invoice_issued_on_DATE: "Invoice issued on %{DATE}"
|
||||
refund_invoice_issued_on_DATE: "Refund invoice issued on %{DATE}"
|
||||
wallet_credit: "Wallet credit"
|
||||
cancellation_of_invoice_REF: "Cancellation of invoice %{REF}"
|
||||
reservation_of_USER_on_DATE_at_TIME: "Reservation of %{USER} on %{DATE} at %{TIME}"
|
||||
cancellation: "Cancellation"
|
||||
|
@ -68,6 +68,7 @@ fr:
|
||||
order_number: "N° Commande : %{NUMBER}"
|
||||
invoice_issued_on_DATE: "Facture éditée le %{DATE}"
|
||||
refund_invoice_issued_on_DATE: "Avoir édité le %{DATE}"
|
||||
wallet_credit: "Crédit du porte-monnaie"
|
||||
cancellation_of_invoice_REF: "Annulation de la facture %{REF}"
|
||||
reservation_of_USER_on_DATE_at_TIME: "Réservation de %{USER} le %{DATE} à %{TIME}"
|
||||
cancellation: "Annulation"
|
||||
|
Loading…
x
Reference in New Issue
Block a user