Merge pull request #4827 from anandpdoshi/fix/bank-reconciliation-grid

[fix] Show Debit/Credit in Bank Reconciliation table
This commit is contained in:
Anand Doshi 2016-02-18 16:14:56 +05:30
commit d9dc9e4616
3 changed files with 35 additions and 27 deletions

View File

@ -7,6 +7,10 @@ from frappe.utils import flt, getdate, nowdate
from frappe import msgprint, _
from frappe.model.document import Document
form_grid_templates = {
"journal_entries": "templates/form_grid/bank_reconciliation_grid.html"
}
class BankReconciliation(Document):
def get_details(self):
if not (self.bank_account and self.from_date and self.to_date):

View File

@ -235,29 +235,6 @@
"search_index": 0,
"set_only_once": 0,
"unique": 0
},
{
"allow_on_submit": 0,
"bold": 0,
"collapsible": 0,
"fieldname": "data_10",
"fieldtype": "Data",
"hidden": 0,
"ignore_user_permissions": 0,
"in_filter": 0,
"in_list_view": 0,
"length": 0,
"no_copy": 0,
"permlevel": 0,
"precision": "",
"print_hide": 0,
"print_hide_if_no_value": 0,
"read_only": 0,
"report_hide": 0,
"reqd": 0,
"search_index": 0,
"set_only_once": 0,
"unique": 0
}
],
"hide_heading": 0,
@ -270,13 +247,12 @@
"istable": 1,
"max_attachments": 0,
"menu_index": 0,
"modified": "2016-01-19 12:06:17.568428",
"modified": "2016-02-17 06:50:40.074578",
"modified_by": "Administrator",
"module": "Accounts",
"name": "Bank Reconciliation Detail",
"owner": "Administrator",
"permissions": [],
"read_only": 0,
"read_only_onload": 0,
"version": 0
}
"read_only_onload": 0
}

View File

@ -0,0 +1,28 @@
{% if(!doc) { %}
<div class="row">
<div class="col-sm-4 col-xs-4">{{ __("Journal Entry") }}</div>
<div class="col-sm-2 col-xs-4 text-right">{{ __("Amount") }}</div>
<div class="col-sm-2 hidden-xs text-right">{{ __(row.grid.get_docfield("cheque_number").label) }}</div>
<div class="col-sm-2 hidden-xs text-right">{{ __("Posting Date") }}</div>
<div class="col-sm-2 col-xs-4 text-right">{{ __("Clearance Date") }}</div>
</div>
{% } else { %}
<div class="row">
<div class="col-sm-4 col-xs-4">
{{ doc.get_formatted("voucher_id") }}
{{ doc.get_formatted("against_account") }}
</div>
<div class="col-sm-2 col-xs-4 text-right">
{{ doc.debit ? doc.get_formatted("debit") : doc.get_formatted("credit") }} {{ doc.debit ? __("Dr") : __("Cr") }}
</div>
<div class="col-sm-2 hidden-xs text-right">
{{ doc.get_formatted("cheque_number") }}
</div>
<div class="col-sm-2 hidden-xs text-right">
{{ doc.get_formatted("posting_date") }}
</div>
<div class="col-sm-2 col-xs-4 text-right">
{{ doc.get_formatted("clearance_date") }}
</div>
</div>
{% } %}