{% extends "base.html" %} {% block title %}{{ _('Admin · Analytics') }}{% endblock %} {% block content %} {% include "admin/_nav.html" %}

{{ _('Analytics — last 30 days') }}

{{ _('New signups (30d)') }}
{{ signups|sum(attribute='n') }}
{{ _('Listings posted (30d)') }}
{{ listings_chart|sum(attribute='n') }}
{{ _('Revenue (30d)') }}
${{ '%.2f'|format((revenue_chart|sum(attribute='cents') or 0) / 100) }}
{{ _('Ad impressions (active ads)') }}
{{ ad_stats.total_impressions or 0 }}
{{ _('Ad clicks (active ads)') }}
{{ ad_stats.total_clicks or 0 }}
{{ _('Overall CTR') }}
{% if ad_stats.total_impressions %} {{ '%.2f'|format(ad_stats.total_clicks / ad_stats.total_impressions * 100) }}% {% else %}—{% endif %}

{{ _('Signups per day') }}

{% if signups %} {% for row in signups %} {% endfor %}
{{ _('Date') }}{{ _('Signups') }}
{{ row.day }} {{ row.n }}
{% else %}

{{ _('No signups in the last 30 days.') }}

{% endif %}

{{ _('Listings posted per day') }}

{% if listings_chart %} {% for row in listings_chart %} {% endfor %}
{{ _('Date') }}{{ _('Listings') }}
{{ row.day }} {{ row.n }}
{% else %}

{{ _('No listings posted in the last 30 days.') }}

{% endif %}

{{ _('Revenue per day') }}

{% if revenue_chart %} {% for row in revenue_chart %} {% endfor %}
{{ _('Date') }}{{ _('Revenue') }}
{{ row.day }} ${{ '%.2f'|format((row.cents or 0) / 100) }}
{% else %}

{{ _('No revenue in the last 30 days.') }}

{% endif %}

{{ _('Top categories by active listings') }}

{% if top_cats %} {% for name, n in top_cats %} {% endfor %}
{{ _('Category') }}{{ _('Active listings') }}
{{ name }} {{ n }}
{% else %}

{{ _('No listings.') }}

{% endif %}
{% endblock %}