{% import 'fixture/_chip.html.twig' as pick_row %}

Sklady

{% for side, squad in {'mine': fixture.mySquad, 'opponent': fixture.opponentSquad} %}

{{ squad.name }}

{% for entry in squad.entries %} {% set snapshot = view.snapshotFor(entry.id) %} {% set live = not fixture.gameweek.finished %} {% set waitingCount = live and snapshot and snapshot.hasData ? snapshot.startingPicks|filter(p => p.minutes == 0 and p.rawPoints == 0)|length : 0 %}
{{ entry.teamName }} {% if waitingCount > 0 %}{{ waitingCount }} do gry{% endif %} {{ snapshot and snapshot.hasData ? snapshot.netPoints : '—' }} {% if snapshot and snapshot.hasData %} {% for pick in snapshot.startingPicks %} {{ pick_row.row(pick, live) }} {% endfor %}
{# Przy chipie z grajaca lawka wszystkie pietnascie pozycji ma mnoznik wiekszy od zera, wiec ta lista jest pusta i blok w ogole sie nie pojawia. #} {% if snapshot.benchPicks is not empty %}

Lawka

{% for pick in snapshot.benchPicks %} {{ pick_row.row(pick, live) }} {% endfor %}
{% endif %} {% else %}

Brak danych z FPL.

{% endif %}
{% endfor %}
{% endfor %}