{% extends "pretixcontrol/event/base.html" %} {% load i18n %} {% block title %}{% trans "Affiliates" %}{% endblock %} {% block content %}

{% trans "Affiliates" %} {% trans "Export payouts (CSV)" %}

{% blocktrans %}Promoters, DJs and influencers each get an ?aff= code and any number of trackable per-channel links (Instagram story, printed-flyer QR, email blast) — so you see which channel actually sold, not just which promoter. Attribution window: {{ window }} days.{% endblocktrans %}

{% csrf_token %}
{% if board %}

{% trans "Leaderboard" %}

{% for r in board %} {% endfor %}
#{% trans "Affiliate" %}{% trans "Orders" %}{% trans "Revenue" %}{% trans "Owed" %}
{{ forloop.counter }}{{ r.aff.name }} {{ r.orders }} {{ event.currency }} {{ r.revenue }} {{ event.currency }} {{ r.commission }}
{% endif %} {% for r in rows %}
{{ r.aff.name }} · {{ r.aff.code }} {{ r.aff.commission_percent }}% · {{ r.orders }} {% trans "orders" %} · {{ event.currency }} {{ r.revenue }}
{% trans "Commission owed" %}: {{ event.currency }} {{ r.owed }} {% if r.paid_out %} · {% trans "paid" %} {{ event.currency }} {{ r.paid_out }}{% endif %} {% if r.aff.connect_account_id %}Stripe Connect{% else %}({% trans "no Connect account — records for manual payout" %}){% endif %}
{% csrf_token %}
{% if r.payouts %}
{% trans "Recent payouts" %}: {% for p in r.payouts %}{{ event.currency }}{{ p.amount }} {{ p.status }}{% if not forloop.last %} · {% endif %}{% endfor %}
{% endif %}
{% if r.links %} {% for l in r.links %} {% endfor %}
{% trans "Channel" %}{% trans "Trackable link" %} {% trans "Clicks" %}{% trans "Orders" %} {% trans "Conv." %}{% trans "Revenue" %}
{{ l.ln.label|default:l.ln.slug }}
{{ l.ln.utm_medium|default:"referral" }}
{% trans "QR code" %} {{ l.ln.clicks }} {{ l.orders }} {{ l.cr|floatformat:1 }}% {{ event.currency }} {{ l.revenue }}
{% csrf_token %}
{% endif %}
{% csrf_token %}
{% empty %}
{% trans "No affiliates yet. Add one above, then give them trackable per-channel links." %}
{% endfor %} {% endblock %}