fixes in sales invoice
diff --git a/accounts/doctype/sales_invoice/sales_invoice.py b/accounts/doctype/sales_invoice/sales_invoice.py
index 65f23f5..4c40525 100644
--- a/accounts/doctype/sales_invoice/sales_invoice.py
+++ b/accounts/doctype/sales_invoice/sales_invoice.py
@@ -650,15 +650,16 @@
# tax table gl entries
for tax in self.doclist.get({"parentfield": "other_charges"}):
- gl_entries.append(
- self.get_gl_dict({
- "account": tax.account_head,
- "against": self.doc.debit_to,
- "credit": flt(tax.tax_amount),
- "remarks": self.doc.remarks,
- "cost_center": tax.cost_center_other_charges
- }, is_cancel)
- )
+ if flt(tax.tax_amount):
+ gl_entries.append(
+ self.get_gl_dict({
+ "account": tax.account_head,
+ "against": self.doc.debit_to,
+ "credit": flt(tax.tax_amount),
+ "remarks": self.doc.remarks,
+ "cost_center": tax.cost_center_other_charges
+ }, is_cancel)
+ )
# item gl entries
for item in getlist(self.doclist, 'entries'):
diff --git a/selling/doctype/quotation/quotation.js b/selling/doctype/quotation/quotation.js
index 2112ac8..a4d8ee6 100644
--- a/selling/doctype/quotation/quotation.js
+++ b/selling/doctype/quotation/quotation.js
@@ -80,7 +80,6 @@
// REFRESH
// ===================================================================================
cur_frm.cscript.refresh = function(doc, cdt, cdn) {
-
cur_frm.clear_custom_buttons();
if (!cur_frm.cscript.is_onload) cur_frm.cscript.hide_price_list_currency(doc, cdt, cdn);
@@ -119,7 +118,7 @@
'get_default_customer_address', '', callback);
if(doc.customer) unhide_field(['customer_address','contact_person','territory', 'customer_group']);
cur_frm.toggle_display("contact_section", doc.customer || doc.lead);
-
+ console.log(doc.customer_group);
}
cur_frm.cscript.customer_address = cur_frm.cscript.contact_person = function(doc,dt,dn) {