1
0
mirror of https://github.com/LaCasemate/fab-manager.git synced 2025-01-29 18:52:22 +01:00

[bug] unable to export reservations

This commit is contained in:
Sylvain 2020-07-21 17:25:19 +02:00
parent ad14b02caa
commit e5cef6e6bf
4 changed files with 8 additions and 4 deletions

View File

@ -1,5 +1,7 @@
# Changelog Fab-manager
- Fix a bug: unable to export reservations
## v4.5.3 2020 July 21
- Documentation of the easy upgrade procedure

View File

@ -15,14 +15,14 @@ wb.add_worksheet(name: t('export_reservations.reservations')) do |sheet|
# data rows
@reservations.each do |resrv|
data = [
resrv.user.id,
resrv.user.profile.full_name,
resrv.user.email,
resrv.user&.id,
resrv.user&.profile&.full_name || t('export_reservations.deleted_user'),
resrv.user&.email,
resrv.created_at.to_date,
resrv.reservable_type,
(resrv.reservable.nil? ? '' : resrv.reservable.name),
(resrv.reservable_type == 'Event') ? resrv.total_booked_seats: resrv.slots.count,
(resrv.invoice.paid_with_stripe?) ? t('export_reservations.local_payment') : t('export_reservations.online_payment')
(resrv.invoice&.paid_with_stripe?) ? t('export_reservations.online_payment') : t('export_reservations.local_payment')
]
styles = [nil, nil, nil, date, nil, nil, nil, nil]
types = [:integer, :string, :string, :date, :string, :string, :integer, :string]

View File

@ -188,6 +188,7 @@ en:
payment_method: "Payment method"
local_payment: "Payment at the reception"
online_payment: "Online payment"
deleted_user: "Deleted user"
#subscriptions list export to EXCEL format
export_subscriptions:
subscriptions: "Subscriptions"

View File

@ -188,6 +188,7 @@ fr:
payment_method: "Méthode de paiement"
local_payment: "Paiement à l'accueil"
online_payment: "Paiement en ligne"
deleted_user: "Utilisateur supprimé"
#subscriptions list export to EXCEL format
export_subscriptions:
subscriptions: "Abonnements"