{% extends 'base.html' %} {% load static %} {% load humanize %} {% block title %}All Repayments{% endblock %} {% block extra_css %} {% endblock %} {% block content %}

๐Ÿ’ต All Loan Repayments

Comprehensive view of all loan repayments

{% if user.role == 'admin' %} {% endif %}
{{ total_repayments }} Total Repayments
{{ total_amount|floatformat:0|intcomma }} Total Amount (KSh)
{% if user.is_admin %} {% endif %}
{% if user.role == 'admin' or user.role == 'team_leader' %}
โšก
Auto-payments are active.

When a customer pays via M-Pesa paybill, SasaPay sends the payment here automatically โ€” it is matched to their loan, a repayment is recorded, and a confirmation SMS is sent to the customer + all admin numbers. Payments marked โšก Auto (SasaPay) were received this way.

{% endif %}
{% if repayments.has_other_pages %}
of {{ repayments.paginator.num_pages }}
{% endif %}
{% for repayment in repayments %} {% empty %} {% endfor %}
๐Ÿ“…Date ๐Ÿ‘คBorrower Loan ID ๐Ÿท๏ธProduct ๐Ÿ’ตAmount ๐Ÿ’ณMethod Source โ„น๏ธStatus ๐ŸงพReceipt โš™๏ธActions
{{ repayment.payment_date|date:"M d, Y" }}
{{ repayment.payment_date|date:"H:i" }}
{{ repayment.loan.borrower.get_full_name }}
๐Ÿ“ž{{repayment.loan.borrower.phone_number }}
{{ repayment.loan.loan_number }} {{ repayment.loan.application.loan_product.name }} KSh {{ repayment.amount|floatformat:2|intcomma}} {{ repayment.payment_method}} {% if repayment.payment_source == 'automatic' %} โšก Auto (SasaPay) {% else %} Manual {% endif %} {% if repayment.loan.status == 'active' %} Active {% elif repayment.loan.status == 'completed' %} Completed {% elif repayment.loan.status == 'overdue' %} Overdue {% else %} {{repayment.loan.status|title }} {% endif %} {% if repayment.receipt %} Generated {% else %} Missing {% endif %}
๐Ÿ“ฅ

No Repayments Found

No repayments match your current filters. Try adjusting your search criteria.

{% if repayments.has_other_pages %}
of {{ repayments.paginator.num_pages }}
{% endif %}
{% endblock %} {% block extra_js %} {% endblock %}