[enhance] merge customize buttons under groups

This commit is contained in:
Saurabh
2016-01-06 15:34:56 +05:30
parent 025a407e13
commit e23e99f4bd
33 changed files with 195 additions and 176 deletions

View File

@@ -133,14 +133,14 @@ erpnext.TransactionController = erpnext.taxes_and_totals.extend({
var me = this;
if (in_list(["Purchase Invoice", "Sales Invoice"], this.frm.doctype)) {
if(this.frm.doc.outstanding_amount !== this.frm.doc.base_grand_total) {
this.frm.add_custom_button(__("Show Payments"), function() {
this.frm.add_custom_button(__("Payments"), function() {
frappe.route_options = {
"Journal Entry Account.reference_type": me.frm.doc.doctype,
"Journal Entry Account.reference_name": me.frm.doc.name
};
frappe.set_route("List", "Journal Entry");
});
}, __("View"));
}
}
},