mirror of
https://github.com/LaCasemate/fab-manager.git
synced 2025-03-01 23:29:23 +01:00
(feat) show age of child in event reservation
This commit is contained in:
parent
8771eb8ccc
commit
8b4150a888
@ -38,6 +38,7 @@
|
|||||||
<span ng-if="event.event_type === 'standard'">{{ reservation.user_full_name }} </span>
|
<span ng-if="event.event_type === 'standard'">{{ reservation.user_full_name }} </span>
|
||||||
<div ng-repeat="bu in reservation.booking_users_attributes">
|
<div ng-repeat="bu in reservation.booking_users_attributes">
|
||||||
<span>{{bu.name}}</span>
|
<span>{{bu.name}}</span>
|
||||||
|
<span ng-if="bu.booked_type === 'Child'" class="m-l-sm">({{ 'app.admin.event_reservations.age' | translate:{NUMBER: bu.age} }})</span>
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
<td>{{ reservation.created_at | amDateFormat:'LL LTS' }}</td>
|
<td>{{ reservation.created_at | amDateFormat:'LL LTS' }}</td>
|
||||||
|
@ -40,6 +40,7 @@ json.booking_users_attributes reservation.booking_users.order(booked_type: :desc
|
|||||||
json.event_price_category_id bu.event_price_category_id
|
json.event_price_category_id bu.event_price_category_id
|
||||||
json.booked_id bu.booked_id
|
json.booked_id bu.booked_id
|
||||||
json.booked_type bu.booked_type
|
json.booked_type bu.booked_type
|
||||||
|
json.age ((Time.zone.now - bu.booked.birthday.to_time) / 1.year.seconds).floor if bu.booked_type == 'Child'
|
||||||
end
|
end
|
||||||
json.is_valid reservation.slots_reservations[0].is_valid
|
json.is_valid reservation.slots_reservations[0].is_valid
|
||||||
json.is_paid reservation.invoice_items.count.positive?
|
json.is_paid reservation.invoice_items.count.positive?
|
||||||
|
@ -672,6 +672,7 @@ en:
|
|||||||
confirm_present: "Confirm presence"
|
confirm_present: "Confirm presence"
|
||||||
confirm_present_info: "Confirm the presence of the user for this event"
|
confirm_present_info: "Confirm the presence of the user for this event"
|
||||||
reservation_was_successfully_present: "The presence of the user was successfully confirmed."
|
reservation_was_successfully_present: "The presence of the user was successfully confirmed."
|
||||||
|
age: "{NUMBER} years old"
|
||||||
events_settings:
|
events_settings:
|
||||||
title: "Settings"
|
title: "Settings"
|
||||||
generic_text_block: "Editorial text block"
|
generic_text_block: "Editorial text block"
|
||||||
|
@ -672,6 +672,7 @@ fr:
|
|||||||
confirm_present: "Confirmer la présence"
|
confirm_present: "Confirmer la présence"
|
||||||
confirm_present_info: "Confirmer la présence de l'utilisateur à l'événement"
|
confirm_present_info: "Confirmer la présence de l'utilisateur à l'événement"
|
||||||
reservation_was_successfully_present: "La présence a bien été confirmée."
|
reservation_was_successfully_present: "La présence a bien été confirmée."
|
||||||
|
age: "{NUMBER} ans"
|
||||||
events_settings:
|
events_settings:
|
||||||
title: "Paramètres"
|
title: "Paramètres"
|
||||||
generic_text_block: "Bloc de texte rédactionnel"
|
generic_text_block: "Bloc de texte rédactionnel"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user