{% extends "base.twig" %} {% import "macros/profileelements.twig" as profile %} {% import "macros/messagebox.twig" as msgbox %} {% import "macros/statisticelements.twig" as statisticelements %} {% block page_title %} {{ match.home_team_name }} - {{ match.guest_team_name }} {% endblock %} {% block page_content %} {{ profile.infofield(i18n.getMessage("entity_youthmatch_matchdate"), env.getFormattedDatetime(match.matchdate)) }} {% if match.simulated %}

{{ i18n.getMessage("match_details_report_title") }}

{{ match.home_goals }} - {{ match.guest_goals }}
{% if match.home_noformation %} {{ msgbox.box("", i18n.getMessage("match_details_noformation", match.home_team_name), "warning") }} {% endif %} {% if match.guest_noformation %} {{ msgbox.box("", i18n.getMessage("match_details_noformation", match.guest_team_name), "warning") }} {% endif %}
{% if reportMessages|length > 0 %} {{ match.home_team_name }} {{ match.guest_team_name }}
{% endif %}

{{ i18n.getMessage("match_details_players_title") }}

{% for teamPrefix,teamPlayers in players %}
{{ match[teamPrefix ~ "_team_name"] }}
{% if teamPlayers|length > 0 %} {% for player in teamPlayers %} {% if player.position_main is not empty %} {% else %} {% endif %} {% endfor %}
{{ i18n.getMessage("playertable_head_position_abbr") }} {{ i18n.getMessage("match_details_players_name") }} {{ i18n.getMessage("match_details_players_grade") }}
{{ i18n.getMessage("player_mainposition_" ~ player.position_main) }}{{ i18n.getMessage("option_" ~ player.position)|slice(0, 2)|upper }}{{ player.name }} {% if player.card_yellow > 0 %} {{ i18n.getMessage( {% if player.card_yellow > 1 %} {{ i18n.getMessage( {% endif %} {% endif %} {% if player.card_red > 0 %} {{ i18n.getMessage( {% endif %} {% if player.goals > 0 %} {% for i in 1..player.goals %} {{ i18n.getMessage( {% endfor %} {% endif %} {% if player.assists %} {% for i in 1..player.assists %} {% endfor %} {% endif %} {% if player.state == 'Ausgewechselt' %} {% elseif player.minutes_played < 90 %} {% endif %} = 4.3 and player.grade <= 5 %}class="text-warning" {% elseif player.grade > 5 %}class="text-error" {% endif %} >{{ player.grade }}
{% else %}

{{ i18n.getMessage("match_details_noplayersset") }}

{% endif %}
{% endfor %}

{{ i18n.getMessage("match_details_statistic_title") }}

{% for teamPrefix,teamStatistics in statistics %}
{{ match[teamPrefix ~ "_team_name"] }}
{% if teamStatistics|length > 0 %}

{{ i18n.getMessage("match_details_statistic_shoots") }}: {{ teamStatistics.shoots }}

{{ i18n.getMessage("youthmatch_statistic_avg_strength") }}

{{ statisticelements.progressbar(teamStatistics.avg_strength) }}

{{ i18n.getMessage("match_details_statistic_ballcontacts") }}

{{ statisticelements.progressbar(teamStatistics.ballpossession) }}

{{ i18n.getMessage("match_details_statistic_tackles") }}

{% set tackles = (teamStatistics.wontackles * 100 / (teamStatistics.wontackles + teamStatistics.losttackles))|number_format %} {{ statisticelements.progressbar(tackles) }} {% if teamStatistics.passes_successed > 0 or teamStatistics.passes_failed > 0 %} {% set succesfulPasses = (teamStatistics.passes_successed * 100 / (teamStatistics.passes_successed + teamStatistics.passes_failed))|number_format %}

{{ i18n.getMessage("match_details_statistic_successfulpasses") }}

{{ statisticelements.progressbar(succesfulPasses) }} {% endif %} {% endif %}
{% endfor %}
{% endif %} {% endblock %}