fix: incorrect rules around family insurances

addresses #869dr80qj
This commit is contained in:
Björn Fromme
2026-08-05 15:11:37 +02:00
parent 736128476b
commit 8a46908856
15 changed files with 859 additions and 50 deletions
@@ -493,9 +493,15 @@
{# Insurance field OR assigned insurance display for dependent participants (create mode) #}
{% else %}
{% set showBulkInsurance = participantIndex > 0 and bookingDto.participants[0].bulkInsuranceBooking %}
{# Dependents get the applicant's read-only insurance display instead of their own choice
when bulk insurance booking is active, or when the applicant selected a family
insurance (which always covers the whole family, regardless of the bulk checkbox) #}
{% set showApplicantInsurance = participantIndex > 0 and (
bookingDto.participants[0].bulkInsuranceBooking
or (bookingDto.participants[0].insurance and bookingDto.participants[0].insurance.familyInsurance)
) %}
{% if showBulkInsurance %}
{% if showApplicantInsurance %}
{% set applicantInsurance = bookingDto.participants[0].insurance %}
<div class="pb-4">
<fieldset class="border border-primary-bg">