Merge branch 'features/household-members-list' into features/household-editor

This commit is contained in:
2021-06-08 22:16:43 +02:00
10 changed files with 115 additions and 23 deletions

View File

@@ -7,9 +7,11 @@
{%- for n in person.altNames -%}
{%- if loop.first -%}({% else %} {%- endif -%}
<span class="chill-entity__person__alt-name chill-entity__person__altname--{{ n.key }}">
{{ n.label }}
{{- n.label -}}
</span>
{%- if loop.last %}) {% endif -%}
{%- if loop.last -%}) {%- endif -%}
{%- endfor -%}
{%- endif -%}
{%- if showLink is defined -%}</a>{%- endif -%}</span>
{%- if showLink is defined -%}</a>{%- endif -%}
{#- tricks to remove easily whitespace after template -#}
{%- if true -%}</span>{%- endif -%}

View File

@@ -1,4 +1,4 @@
<div class="subheader">
<div class="subheader banner-household">
<div class="grid-12 parent" id="header-accompanying_course-name" >
<div class="grid-10 push-1 grid-mobile-12 grid-tablet-12 push-mobile-0 push-tablet-0 parent">
@@ -18,9 +18,23 @@
</div>
<div class="grid-12 parent" id="header-accompanying_course-details" >
<div class="grid-10 push-1 grid-mobile-12 grid-tablet-12 push-mobile-0 push-tablet-0 parent">
<div id="banner-misc"></div>
<div id="banner-misc">
{%- set persons = household.getCurrentPersons() -%}
{%- if persons|length > 0 -%}
<span class="current-members-explain">
{{- 'household.Current household members'|trans }}:
</span>
{%- for p in persons|slice(0, 5) -%}
{{- p|chill_entity_render_box({'addLink': false}) -}}
{%- if false == loop.last -%}, {% endif -%}
{%- endfor -%}
{% if persons|length > 5 %}
<span class="current-members-more">
{{ 'household.and x other persons'|trans({'x': persons|length-5}) }}
</span>
{% endif %}
{%- endif -%}
</div>
</div>
</div>
</div>

View File

@@ -14,7 +14,7 @@
{%- set members = household.currentMembersByPosition(p) %}
{% if members|length > 0 %}
<div class="household-list-members flex-table list-with-period">
<div class="flex-table list-household-members">
{% for m in members %}
<div class="item-bloc">
<div class="item-row person">
@@ -75,7 +75,7 @@
</button>
<div id="nonCurrent_{{ p.id }}" class="collapse">
<div class="household-list-members flex-table list-with-period">
<div class="flex-table list-household-members">
{% for m in members %}
<div class="item-bloc">
<div class="item-row person">
@@ -127,5 +127,12 @@
{% endif %}
{% endfor %}
<ul class="record_actions sticky-form-buttons">
<li>
<a class="sc-button bt-create">
{{ 'household.Add a member'|trans }}
</a>
</li>
</ul>
{% endblock %}

View File

@@ -16,7 +16,7 @@
<p>{{ 'household.Those members does not share address'|trans }}</p>
{% endif %}
<div class="household-list-members flex-table list-with-period">
<div class="flex-table list-household-members--summary">
{% for m in members %}
<div class="item-bloc">
<div class="item-row person">