{# il2ks-template: templates/il2ks/components/online_now_body.html v1 - copy this line along when you override #} {% load i18n il2ks il2ks_live %}{% comment %} online_now_body.html: what /live/ returns and what online_now.html shows inside its section. Context: live (il2ks.queries.live.OnlineNow: running, mission_name, elapsed_s, updated_at, rows, redfor, blufor, unassigned, total), site (SiteSettings, for the coalition names). Hidden players show as "Hidden player"; a stale or missing snapshot shows "No mission running" and when it was last seen. {% endcomment %}{% if live.running %}

{% blocktranslate count players=live.total %}{{ players }} player online{% plural %}{{ players }} players online{% endblocktranslate %} {% if live.redfor or live.blufor %} {% coalition_badge "redfor" %} {{ live.redfor }} {% coalition_badge "blufor" %} {{ live.blufor }} {% endif %} {% blocktranslate with name=live.mission_name running=live.elapsed_s|duration %}Mission {{ name }}, running for {{ running }}{% endblocktranslate %}

{% for row in live.rows %} {% empty %} {% empty_row 6 _("Nobody is on the server right now.") %} {% endfor %}
{% translate "Player" %} {% translate "Side" %} {% translate "Aircraft" %} {% translate "State" %} {% translate "In the air" %} {% translate "Air / ground kills" %}
{% if row.is_hidden %}{% translate "Hidden player" %}{% elif row.player_id and row.name %}{{ row.name }}{% elif row.name %}{{ row.name }}{% else %}{% translate "Joining…" %}{% endif %} {% if row.side %}{% coalition_badge row.side %}{% else %}—{% endif %} {% if row.aircraft %}{% aircraft_icon row.aircraft "online-now__plane" %} {{ row.aircraft.display_name }}{% else %}—{% endif %} {% live_state_badge row.state %} {% if row.aircraft %}{{ row.flight_time_s|duration }}{% else %}—{% endif %} {{ row.kills_air|num }} / {{ row.kills_ground|num }}
{% if live.updated_at %}

{% blocktranslate with when=live.updated_at|utc %}Updated {{ when }}{% endblocktranslate %}

{% endif %} {% else %} {% notice "info" title=_("No mission running") %}{% if live.updated_at %}{% blocktranslate with when=live.updated_at|utc %}Last seen {{ when }}.{% endblocktranslate %}{% else %}{% translate "No mission has been seen on the server yet." %}{% endif %}{% endnotice %} {% endif %}