paid amount fix in fees
diff --git a/erpnext/education/doctype/fees/fees.py b/erpnext/education/doctype/fees/fees.py
index bfe6af4..aa616e6 100644
--- a/erpnext/education/doctype/fees/fees.py
+++ b/erpnext/education/doctype/fees/fees.py
@@ -112,7 +112,10 @@
user = frappe.session.user
student = frappe.db.sql("select name from `tabStudent` where student_email_id= %s", user)
if student:
- return frappe. db.sql('''select name, program, due_date, paid_amount, outstanding_amount, grand_total from `tabFees`
+ return frappe. db.sql('''
+ select name, program, due_date, grand_total - outstanding_amount as paid_amount,
+ outstanding_amount, grand_total, currency
+ from `tabFees`
where student= %s and docstatus=1
order by due_date asc limit {0} , {1}'''
.format(limit_start, limit_page_length), student, as_dict = True)
diff --git a/erpnext/templates/includes/fee/fee_row.html b/erpnext/templates/includes/fee/fee_row.html
index ac2b100..d5fd682 100644
--- a/erpnext/templates/includes/fee/fee_row.html
+++ b/erpnext/templates/includes/fee/fee_row.html
@@ -5,13 +5,13 @@
{{ doc.program }}
</div>
<div class="col-xs-2">
- {{ doc.get_formatted("total_amount") }}
+ {{ frappe.utils.fmt_money(doc.grand_total, currency=doc.currency) }}
</div>
<div class="col-xs-2">
- {{ doc.get_formatted("paid_amount") }}
+ {{ frappe.utils.fmt_money(doc.paid_amount, currency=doc.currency) }}
</div>
<div class="col-xs-2">
- {{ doc.get_formatted("outstanding_amount") }}
+ {{ frappe.utils.fmt_money(doc.outstanding_amount, currency=doc.currency) }}
</div>
</div>
</a>