{# il2ks-template: templates/il2ks/home.html v1 - copy this line along when you override #} {% extends "il2ks/base.html" %}{% load i18n static il2ks il2ks_live %}{% comment %} Home page (OQ-79: tour-aware, no ?tour = the current tour, ?tour=all = all time; online now is live). Context: tours / tour (the tour selector), tour_query ("?tour=" or "?tour=all", for links that keep the scope), latest (the newest missions that have sorties, in the tour), last_mission (the first of them, or None), activity (ChartSpec or None), boards (HomeBoard: .key, .title, .rows of BoardRow: rank, player, stats, per_hour), pilots (TopPilot: .row is a PlayerMission with .player, .side is "redfor", "blufor" or None). The "Recently earned" strip (achievements/home_feed.html, doc 17) reads its own rows for the scope. Order: hero (title, player search, tour selector), the front page image (if set), online now, last mission, recently earned, boards, activity, latest missions. Blocks: head (page stylesheet), content. {% endcomment %} {% block head %}{% endblock %} {% block content %}
{% if not home_bg %}{% icon "brand/logo-mark" "hero__mark" %}{% endif %}

{{ site.site_title }}

{% if site.description %}{{ site.description|linebreaksbr }}{% else %}{% translate "Pilot, sortie and mission statistics from our IL-2 Sturmovik: Korea server." %}{% endif %}

{% tour_select tours tour %}
{% include "il2ks/home_feature.html" %} {% online_now %} {% if last_mission %}

{% translate "Last mission" %}

{{ last_mission|mission_title }}

{{ last_mission.started_at|local_time }} {{ last_mission.duration_s|duration }} {% translate "Winner" %}: {% winner_badge last_mission %}

{% stat_tile last_mission.players_total|num _("Players") %} {% stat_tile last_mission.sorties_total|num _("Sorties") icon="stat/sorties" %} {% stat_tile last_mission.kills_air|num _("Air kills") icon="stat/air-kills" %} {% stat_tile last_mission.kills_ground|num _("Ground kills") icon="stat/ground-kills" %}

{% coalition_badge "redfor" %} {{ last_mission.redfor_sorties|num }} {% translate "sorties" %} {% coalition_badge "blufor" %} {{ last_mission.blufor_sorties|num }} {% translate "sorties" %}

{% translate "Top pilots by kills" %}

{% if pilots %}{% flavor "top_pilot" last_mission.pk as top_quip %}{% if top_quip %}

{{ top_quip }}

{% endif %}{% endif %} {% if pilots %} {% col_th _("Air") numeric=True %} {% col_th _("Ground") numeric=True %} {% for pilot in pilots %} {% endfor %}
{% translate "Pilot" %}
{% coalition_icon pilot.side %} {% include "il2ks/missions/_player.html" with player=pilot.row.player name=pilot.row.player.current_name stretch=True tour_q=tour_query %} {{ pilot.row.kills_air|num }} {{ pilot.row.kills_ground|num }}
{% else %}

{% translate "Nobody scored a kill in this mission." %} {% flavor "nobody_scored" last_mission.pk %}

{% endif %}
{% endif %} {% include "il2ks/achievements/home_feed.html" %} {% include "il2ks/leaderboards/home_block.html" %} {% include "il2ks/home_activity.html" %}

{% translate "Latest missions" %}

{% include "il2ks/missions/_rows.html" with missions=latest empty_message=_("No missions yet.") %}
{% translate "Date" %} {% translate "Mission" %} {% translate "Duration" %} {% translate "Players" %} {% translate "Sorties" %} {% coalition_icon "redfor" %}/{% coalition_icon "blufor" %} {% translate "Air kills" %} {% translate "Ground kills" %} {% translate "Winner" %}

{% translate "All missions" %}

{% endblock %}