{% extends "base.html" %} {% block introduction %} {% if msgs.lede %}
{{ msgs.lede | safe }}
{% else %}Your .abif has been processed. See results below
{% endif %} {% endblock introduction %} {% block content %} {% set all_results_generated = (result_types|length == 5) %} {% include 'abifbox-snippet.html' %}The {{msgs.results_name}} of {{abif_id}} are below, and can be edited in the field above.
{% elif msgs.results_lede %} {# msgs.results_lede is DEPRECATED as of 2024-06-19 #}{{ msgs.results_lede | safe }}
{% else %}Below are various abiftool output blocks for the ABIF above. {% endif %}
| Method | Winner |
|---|---|
| Condorcet/Copeland | {% if copewinners and FPTP_candnames %} {%- for tok in copewinners -%} {{ FPTP_candnames[tok] if tok in FPTP_candnames else tok }}{% if not loop.last %}, {% endif %} {%- endfor -%} {% elif copewinnerstring %} {{ copewinnerstring }} {% else %} N/A {% endif %} |
| FPTP | {% if FPTP_candnames and resblob and resblob['FPTP_result'] and resblob['FPTP_result']['winners'] %} {% set winner_token = resblob['FPTP_result']['winners'][0] %} {{ FPTP_candnames[winner_token] if winner_token in FPTP_candnames else winner_token }} {% elif resblob and resblob['FPTP_result'] and resblob['FPTP_result']['winners'] %} {{ resblob['FPTP_result']['winners'][0] }} {% else %} N/A {% endif %} |
| IRV/RCV | {% if IRV_dict and IRV_dict['winner'] and IRV_candnames %} {%- for winner_token in IRV_dict['winner'] -%} {{ IRV_candnames[winner_token] if winner_token in IRV_candnames else winner_token }}{% if not loop.last %}, {% endif %} {%- endfor -%} {% elif IRV_dict and IRV_dict['winnerstr'] %} {{ IRV_dict['winnerstr'] }} {% else %} N/A {% endif %} |
| STAR | {% if scorestardict and scorestardict['scoremodel']['winner'] and FPTP_candnames %} {% set winner_name = scorestardict['scoremodel']['winner'] %} {% set winner_token = namespace(value=None) %} {% for cand_token in scorestardict['scoremodel']['ranklist'] %} {% if scorestardict['scoremodel']['scores'][cand_token]['candname'] == winner_name and winner_token.value is none %} {% set winner_token.value = cand_token %} {% endif %} {% endfor %} {% if winner_token.value %} {{ winner_name }} {% else %} {{ winner_name }} {% endif %} {% elif scorestardict and scorestardict['scoremodel']['winner'] %} {{ scorestardict['scoremodel']['winner'] }} {% else %} N/A {% endif %} |
| Approval | {% if approval_result and approval_result['winners'] and FPTP_candnames %} {%- for winner in approval_result['winners'] -%} {{ FPTP_candnames[winner] if winner in FPTP_candnames else winner }}{% if not loop.last %}, {% endif %} {%- endfor -%} {% elif approval_result and approval_result['winners'] %} {% for winner in approval_result['winners'] %}{{ winner }}{% if not loop.last %}, {% endif %}{% endfor %} {% else %} N/A {% endif %} |
{{ dotsvg_html | safe }}
{% endif %} {% endif %} {% endif %}{% include 'fptp-snippet.html' %}
{% endif %}{% include 'irv-snippet.html' %}
{{ scorestardict['star_lede'] }}
{% endif %} {% set notices = resblob.notices.star %} {% include 'notice-snippet.html' %}{% include 'star-snippet.html' %}
{% if scorestardict and scorestardict['star_foot'] %}{{ scorestardict['star_foot'] }}
{% endif %} {% endif %}(homepage)
{% endblock content %}