{% extends spa_base or "base.html"%} {% block title %}Assinantes - Admin{% endblock %} {% block extra_head %} {% endblock %} {% block content %}

👥 Assinantes

Visao completa de todos os assinantes, planos, historico de pagamentos e mais

{{ qtd_paid|default(0) }}
Premium Ativo
{{ qtd_free|default(0) }}
Free Ativo
{{ qtd_expired|default(0) }}
Expirados
{{ qtd_never|default(0) }}
Nunca Assinou
{{ qtd_banned|default(0) }}
Banidos
{{ total }}
Total
{% if user_search %}Limpar{% endif %}

👤 Usuarios {{ total }} registro(s)

{% for u in users %} {% set plans = plan_histories.get(u.id, []) %} {% set pays = payments_by_user.get(u.id, []) %} {% set coms = commissions_by_user.get(u.id, []) %} {% endfor %}
Usuario Email WhatsApp Plano Assinaturas Pagamentos Vencimento Comissoes Convidados Status Criado
{% if u.is_banned %}Banido {% elif not u.is_active_user %}Inativo {% elif u.id in online_user_ids %}{% endif %} {{ u.email.split('@')[0] }} {{ u.email }} {% if u.whatsapp %} 💬 {{ u.whatsapp }} {% else %}-{% endif %} {% if plans|length > 0 %} {% set latest = plans[0] %} {{ latest.plan_name or latest.plan_type|title }} {% elif u.is_paid %} Premium {% else %} Free {% endif %} {% if plans|length > 0 %} {{ plans|length }}
{% for p in plans[:3] %} {{ p.plan_name or p.plan_type|title }} {% endfor %} {% if plans|length > 3 %}+{{ plans|length - 3 }} mais{% endif %}
{% else %}0{% endif %}
{% if pays|length > 0 %} {{ pays|length }}
{% for p in pays[:3] %} R$ {{ '%.2f'|format(p.amount) }} {{ p.plan_type|title }}
{% endfor %}
{% else %}0{% endif %}
{% set exp = user_expiry_info.get(u.id) %} {% if exp %} {% if exp.expired %} Vencido {% else %} {{ exp.date }}
{{ exp.days }} dias restantes
{% endif %} {% else %}-{% endif %}
{% if coms|length > 0 %} {{ coms|length }} comissões {% else %}0{% endif %} {% set invited = ref_total_map.get(u.id, 0) %} {% if invited > 0 %} {{ invited }} {% else %}0{% endif %} {% if u.is_banned %}Banido {% elif not u.is_active_user %}Inativo {% elif u.is_paid %}Premium {% else %}Free{% endif %} {{ u.created_at|bdate }}
{% if total_pages > 1 %} {% endif %}
{% endblock %}