multiplefixes
diff --git a/erpnext/accounts/doctype/purchase_invoice/purchase_invoice.json b/erpnext/accounts/doctype/purchase_invoice/purchase_invoice.json
index bd8199c..b89f215 100755
--- a/erpnext/accounts/doctype/purchase_invoice/purchase_invoice.json
+++ b/erpnext/accounts/doctype/purchase_invoice/purchase_invoice.json
@@ -298,7 +298,7 @@
"options": "currency",
"permlevel": 0,
"precision": "",
- "print_hide": 1,
+ "print_hide": 0,
"read_only": 1
},
{
@@ -309,7 +309,7 @@
"oldfieldtype": "Currency",
"options": "currency",
"permlevel": 0,
- "print_hide": 0,
+ "print_hide": 1,
"read_only": 1
},
{
@@ -962,7 +962,7 @@
"icon": "icon-file-text",
"idx": 1,
"is_submittable": 1,
- "modified": "2015-02-23 15:33:28.554922",
+ "modified": "2015-02-24 15:24:24.402882",
"modified_by": "Administrator",
"module": "Accounts",
"name": "Purchase Invoice",
diff --git a/erpnext/accounts/doctype/sales_invoice/sales_invoice.json b/erpnext/accounts/doctype/sales_invoice/sales_invoice.json
index d7837a2..b909cb4 100644
--- a/erpnext/accounts/doctype/sales_invoice/sales_invoice.json
+++ b/erpnext/accounts/doctype/sales_invoice/sales_invoice.json
@@ -365,7 +365,7 @@
"options": "currency",
"permlevel": 0,
"precision": "",
- "print_hide": 1,
+ "print_hide": 0,
"read_only": 1
},
{
@@ -374,7 +374,7 @@
"label": "Net Total",
"options": "currency",
"permlevel": 0,
- "print_hide": 0,
+ "print_hide": 1,
"read_only": 1
},
{
@@ -495,7 +495,7 @@
"label": "Discount Amount",
"options": "currency",
"permlevel": 0,
- "print_hide": 0
+ "print_hide": 1
},
{
"fieldname": "base_discount_amount",
@@ -1244,7 +1244,7 @@
"icon": "icon-file-text",
"idx": 1,
"is_submittable": 1,
- "modified": "2015-02-23 15:53:37.894033",
+ "modified": "2015-02-24 15:23:28.554373",
"modified_by": "Administrator",
"module": "Accounts",
"name": "Sales Invoice",
diff --git a/erpnext/buying/doctype/purchase_order/purchase_order.json b/erpnext/buying/doctype/purchase_order/purchase_order.json
index 6776535..273bf27 100644
--- a/erpnext/buying/doctype/purchase_order/purchase_order.json
+++ b/erpnext/buying/doctype/purchase_order/purchase_order.json
@@ -272,7 +272,7 @@
"options": "currency",
"permlevel": 0,
"precision": "",
- "print_hide": 1,
+ "print_hide": 0,
"read_only": 1
},
{
@@ -284,7 +284,7 @@
"oldfieldtype": "Currency",
"options": "currency",
"permlevel": 0,
- "print_hide": 0,
+ "print_hide": 1,
"read_only": 1
},
{
@@ -856,7 +856,7 @@
"icon": "icon-file-text",
"idx": 1,
"is_submittable": 1,
- "modified": "2015-02-23 15:10:05.156787",
+ "modified": "2015-02-24 15:23:59.609724",
"modified_by": "Administrator",
"module": "Buying",
"name": "Purchase Order",
diff --git a/erpnext/buying/doctype/supplier_quotation/supplier_quotation.json b/erpnext/buying/doctype/supplier_quotation/supplier_quotation.json
index 0ed6023..8b5f8d6 100644
--- a/erpnext/buying/doctype/supplier_quotation/supplier_quotation.json
+++ b/erpnext/buying/doctype/supplier_quotation/supplier_quotation.json
@@ -263,7 +263,7 @@
"options": "currency",
"permlevel": 0,
"precision": "",
- "print_hide": 1,
+ "print_hide": 0,
"read_only": 1
},
{
@@ -275,7 +275,7 @@
"oldfieldtype": "Currency",
"options": "currency",
"permlevel": 0,
- "print_hide": 0,
+ "print_hide": 1,
"read_only": 1
},
{
@@ -657,7 +657,7 @@
"icon": "icon-shopping-cart",
"idx": 1,
"is_submittable": 1,
- "modified": "2015-02-23 15:24:02.428061",
+ "modified": "2015-02-24 15:23:43.663479",
"modified_by": "Administrator",
"module": "Buying",
"name": "Supplier Quotation",
diff --git a/erpnext/public/js/controllers/transaction.js b/erpnext/public/js/controllers/transaction.js
index 3f9846f..a1c4fb2 100644
--- a/erpnext/public/js/controllers/transaction.js
+++ b/erpnext/public/js/controllers/transaction.js
@@ -329,6 +329,15 @@
me.frm.fields_dict[fname].set_label(label);
});
+ var show =cint(cur_frm.doc.discount_amount) ||
+ ((cur_frm.doc.taxes || []).filter(function(d) {return d.included_in_print_rate===1}).length);
+
+ if(frappe.meta.get_docfield(cur_frm.doctype, "net_total"))
+ cur_frm.toggle_display("net_total", show);
+
+ if(frappe.meta.get_docfield(cur_frm.doctype, "base_net_total"))
+ cur_frm.toggle_display("base_net_total", (show && (me.frm.doc.currency != company_currency)));
+
},
change_grid_labels: function(company_currency) {
@@ -702,6 +711,7 @@
})
frappe.ui.form.on(cur_frm.cscript.tax_table, "included_in_print_rate", function(frm, cdt, cdn) {
+ cur_frm.cscript.set_dynamic_labels();
cur_frm.cscript.calculate_taxes_and_totals();
})
@@ -710,5 +720,6 @@
})
frappe.ui.form.on(cur_frm.doctype, "discount_amount", function(frm) {
+ cur_frm.cscript.set_dynamic_labels();
cur_frm.cscript.calculate_taxes_and_totals();
})
diff --git a/erpnext/selling/doctype/quotation/quotation.json b/erpnext/selling/doctype/quotation/quotation.json
index 675e6b0..1f5a664 100644
--- a/erpnext/selling/doctype/quotation/quotation.json
+++ b/erpnext/selling/doctype/quotation/quotation.json
@@ -429,15 +429,6 @@
"permlevel": 0
},
{
- "fieldname": "total_taxes_and_charges",
- "fieldtype": "Currency",
- "label": "Total Taxes and Charges",
- "options": "currency",
- "permlevel": 0,
- "print_hide": 1,
- "read_only": 1
- },
- {
"fieldname": "base_total_taxes_and_charges",
"fieldtype": "Currency",
"label": "Total Taxes and Charges (Company Currency)",
@@ -454,6 +445,21 @@
"permlevel": 0
},
{
+ "fieldname": "total_taxes_and_charges",
+ "fieldtype": "Currency",
+ "label": "Total Taxes and Charges",
+ "options": "currency",
+ "permlevel": 0,
+ "print_hide": 1,
+ "read_only": 1
+ },
+ {
+ "fieldname": "section_break_44",
+ "fieldtype": "Section Break",
+ "permlevel": 0,
+ "precision": ""
+ },
+ {
"default": "Grand Total",
"fieldname": "apply_discount_on",
"fieldtype": "Select",
@@ -464,6 +470,12 @@
"print_hide": 1
},
{
+ "fieldname": "column_break_46",
+ "fieldtype": "Column Break",
+ "permlevel": 0,
+ "precision": ""
+ },
+ {
"fieldname": "discount_amount",
"fieldtype": "Currency",
"label": "Discount Amount",
@@ -844,7 +856,7 @@
"idx": 1,
"is_submittable": 1,
"max_attachments": 1,
- "modified": "2015-02-23 01:18:17.421144",
+ "modified": "2015-02-24 14:52:49.998224",
"modified_by": "Administrator",
"module": "Selling",
"name": "Quotation",
diff --git a/erpnext/selling/doctype/sales_order/sales_order.json b/erpnext/selling/doctype/sales_order/sales_order.json
index db7cc80..0e988a5 100644
--- a/erpnext/selling/doctype/sales_order/sales_order.json
+++ b/erpnext/selling/doctype/sales_order/sales_order.json
@@ -360,7 +360,7 @@
"options": "currency",
"permlevel": 0,
"precision": "",
- "print_hide": 1,
+ "print_hide": 0,
"read_only": 1
},
{
@@ -369,6 +369,7 @@
"label": "Net Total",
"options": "currency",
"permlevel": 0,
+ "print_hide": 1,
"read_only": 1
},
{
@@ -485,7 +486,7 @@
"label": "Discount Amount",
"options": "currency",
"permlevel": 0,
- "print_hide": 0
+ "print_hide": 1
},
{
"fieldname": "base_discount_amount",
@@ -1076,7 +1077,7 @@
"idx": 1,
"is_submittable": 1,
"issingle": 0,
- "modified": "2015-02-23 15:40:17.414233",
+ "modified": "2015-02-24 15:22:27.195416",
"modified_by": "Administrator",
"module": "Selling",
"name": "Sales Order",
diff --git a/erpnext/stock/doctype/delivery_note/delivery_note.json b/erpnext/stock/doctype/delivery_note/delivery_note.json
index a68f8cb..8fd5702 100644
--- a/erpnext/stock/doctype/delivery_note/delivery_note.json
+++ b/erpnext/stock/doctype/delivery_note/delivery_note.json
@@ -377,7 +377,7 @@
"options": "currency",
"permlevel": 0,
"precision": "",
- "print_hide": 1,
+ "print_hide": 0,
"read_only": 1
},
{
@@ -386,6 +386,7 @@
"label": "Net Total",
"options": "currency",
"permlevel": 0,
+ "print_hide": 1,
"read_only": 1
},
{
@@ -507,7 +508,8 @@
"fieldtype": "Currency",
"label": "Discount Amount",
"options": "currency",
- "permlevel": 0
+ "permlevel": 0,
+ "print_hide": 1
},
{
"fieldname": "base_discount_amount",
@@ -1065,7 +1067,7 @@
"idx": 1,
"in_create": 0,
"is_submittable": 1,
- "modified": "2015-02-23 15:49:10.972483",
+ "modified": "2015-02-24 15:23:10.431286",
"modified_by": "Administrator",
"module": "Stock",
"name": "Delivery Note",
diff --git a/erpnext/stock/doctype/purchase_receipt/purchase_receipt.json b/erpnext/stock/doctype/purchase_receipt/purchase_receipt.json
index 7964dd2..60ea3d4 100755
--- a/erpnext/stock/doctype/purchase_receipt/purchase_receipt.json
+++ b/erpnext/stock/doctype/purchase_receipt/purchase_receipt.json
@@ -274,7 +274,7 @@
"options": "currency",
"permlevel": 0,
"precision": "",
- "print_hide": 1,
+ "print_hide": 0,
"read_only": 1
},
{
@@ -285,7 +285,7 @@
"oldfieldtype": "Currency",
"options": "currency",
"permlevel": 0,
- "print_hide": 0,
+ "print_hide": 1,
"read_only": 1
},
{
@@ -849,7 +849,7 @@
"icon": "icon-truck",
"idx": 1,
"is_submittable": 1,
- "modified": "2015-02-23 15:16:36.617354",
+ "modified": "2015-02-24 15:24:11.158048",
"modified_by": "Administrator",
"module": "Stock",
"name": "Purchase Receipt",