{% extends "base.html" %} {% from 'macros/sortable.html' import sort_th %} {% block title %}账户流水 - {{ account.student.name if account.student else '' }}{% endblock %} {% block content %}

{% if account.student %}{{ account.student.name }}{% else %}学员{% endif %} {{ account.course.course_code or account.course.name if account.course else '' }}

Excel 课时表流水 · 最新月份 {{ current.period or '—' }}

返回余额表

正课剩余

{{ fmt_hours(current.end_lessons) }}

赠课剩余

{{ fmt_hours(current.end_gift_lessons) }}

账户余额

{{ fmt_money(current.end_balance) }}

单价 / 节

{{ fmt_price(current.unit_price) }}

月度快照(月初 → 月末)
{% for s in snapshots %} {% else %} {% endfor %}
{{ sort_th('keshibiao_account', 'period', '月份', sort, order, account_params, '') }} {{ sort_th('keshibiao_account', 'unit_price', '单价/节', sort, order, account_params) }} 月初正/赠/余额 新签 续费 {{ sort_th('keshibiao_account', 'consumed', '消课/金额', sort, order, account_params, title='按本月消课节数排序') }} 退费/账号费 {{ sort_th('keshibiao_account', 'end_balance', '月末正/赠/总/余额', sort, order, account_params, title='按月末账户余额排序') }} 备注
{{ s.period_label }} {{ fmt_price(s.unit_price) }} {{ fmt_hours(s.prev_lessons) }} / {{ fmt_hours(s.prev_gift_lessons) }}
{{ fmt_money(s.prev_balance) }}
{% if s.new_signup_amount %}{{ fmt_money(s.new_signup_amount) }} +{{ fmt_hours(s.new_signup_lessons) }}节{% else %}-{% endif %} {% if s.renewal_amount %}{{ fmt_money(s.renewal_amount) }} +{{ fmt_hours(s.renewal_lessons) }}节{% else %}-{% endif %} {{ fmt_hours(s.consumed_lessons) }}节
{{ fmt_money(s.consumed_amount) }}
退{{ fmt_hours(s.refund_lessons) }}节
{{ fmt_money(s.refund_amount) }}
账号费 {{ fmt_money(s.account_fee) }}
{{ fmt_hours(s.end_lessons) }} / {{ fmt_hours(s.end_gift_lessons) }} / {{ fmt_hours(s.end_total_lessons) }}
{{ fmt_money(s.end_balance) }}
{{ s.notes or '-' }}
暂无快照
上课记录(Excel 解析)
{% for r in class_records %} {% else %} {% endfor %}
日期课时原始文本归属月
{{ r.class_date }} {{ r.lessons_consumed }} {{ r.raw_text or '-' }} {{ r.year }}-{{ '%02d'|format(r.month) }}
暂无上课记录
{% endblock %}