From ab96d120867ecdcb919a30c2be49053c666f4bbc Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Wed, 2 May 2012 12:19:33 +0530 Subject: [PATCH 1/4] fixes in customerwise price list --- erpnext/accounts/doctype/sales_invoice/sales_invoice.js | 3 +-- erpnext/selling/doctype/sales_order/sales_order.js | 2 +- erpnext/stock/doctype/delivery_note/delivery_note.js | 2 +- 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/erpnext/accounts/doctype/sales_invoice/sales_invoice.js b/erpnext/accounts/doctype/sales_invoice/sales_invoice.js index 9aaf620b94..15270defc9 100644 --- a/erpnext/accounts/doctype/sales_invoice/sales_invoice.js +++ b/erpnext/accounts/doctype/sales_invoice/sales_invoice.js @@ -173,7 +173,6 @@ cur_frm.cscript.warehouse = function(doc, cdt , cdn) { //Customer cur_frm.cscript.customer = function(doc,dt,dn,onload) { - var callback = function(r,rt) { var callback2 = function(doc, dt, dn) { doc = locals[dt][dn]; @@ -181,7 +180,7 @@ cur_frm.cscript.customer = function(doc,dt,dn,onload) { get_server_fields('get_cust_and_due_date','','',doc,dt,dn,1, function(doc, dt, dn) { cur_frm.refresh(); - cur_frm.cscript.price_list_name(doc, dt, dn); + if (!onload) cur_frm.cscript.price_list_name(doc, dt, dn); }); } diff --git a/erpnext/selling/doctype/sales_order/sales_order.js b/erpnext/selling/doctype/sales_order/sales_order.js index 7435593eb4..7f89748276 100644 --- a/erpnext/selling/doctype/sales_order/sales_order.js +++ b/erpnext/selling/doctype/sales_order/sales_order.js @@ -102,7 +102,7 @@ cur_frm.cscript.customer = function(doc,dt,dn) { var callback2 = function(r, rt) { if(doc.customer) unhide_field(['customer_address', 'contact_person', 'territory','customer_group','shipping_address']); cur_frm.refresh(); - cur_frm.cscript.price_list_name(doc, dt, dn); + if(!onload) cur_frm.cscript.price_list_name(doc, dt, dn); } var doc = locals[cur_frm.doctype][cur_frm.docname]; diff --git a/erpnext/stock/doctype/delivery_note/delivery_note.js b/erpnext/stock/doctype/delivery_note/delivery_note.js index 28ba99ecb5..982275174d 100644 --- a/erpnext/stock/doctype/delivery_note/delivery_note.js +++ b/erpnext/stock/doctype/delivery_note/delivery_note.js @@ -83,7 +83,7 @@ cur_frm.cscript.customer = function(doc,dt,dn,onload) { var doc = locals[cur_frm.doctype][cur_frm.docname]; if(doc.customer) unhide_field(['customer_address','contact_person','territory','customer_group']); cur_frm.refresh(); - cur_frm.cscript.price_list_name(doc, dt, dn); + if(!onload) cur_frm.cscript.price_list_name(doc, dt, dn); } var args = onload ? 'onload':'' if(doc.customer) $c_obj(make_doclist(doc.doctype, doc.name), 'get_default_customer_shipping_address', args, callback); From e876ac2005cd4af510e36b455c674d44322c5a57 Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Wed, 2 May 2012 12:21:27 +0530 Subject: [PATCH 2/4] delete question-view page --- erpnext/patches/jan_mar_2012/sync_ref_db.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/erpnext/patches/jan_mar_2012/sync_ref_db.py b/erpnext/patches/jan_mar_2012/sync_ref_db.py index 911c6a07ca..91a53596cb 100644 --- a/erpnext/patches/jan_mar_2012/sync_ref_db.py +++ b/erpnext/patches/jan_mar_2012/sync_ref_db.py @@ -20,7 +20,7 @@ def execute(): 'Invest 80 Declaration Detail', 'IT Checklist', 'Chapter VI A Detail', 'Declaration Detail', 'Personalize', 'Salary Slip Control Panel', 'Question Control' ], - 'Page' : ['File Browser', 'Bill of Materials'], + 'Page' : ['File Browser', 'Bill of Materials', 'question-view'], 'DocType Mapper': ['Production Forecast-Production Planning Tool', 'Production Forecast-Production Plan', 'Sales Order-Production Plan'], } From 60118662ff441b2bab6f61e5d319ddbb856a70cc Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Wed, 2 May 2012 12:23:05 +0530 Subject: [PATCH 3/4] delete question-view page --- erpnext/patches/jan_mar_2012/sync_ref_db.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/erpnext/patches/jan_mar_2012/sync_ref_db.py b/erpnext/patches/jan_mar_2012/sync_ref_db.py index 91a53596cb..d65a22ffb8 100644 --- a/erpnext/patches/jan_mar_2012/sync_ref_db.py +++ b/erpnext/patches/jan_mar_2012/sync_ref_db.py @@ -20,7 +20,7 @@ def execute(): 'Invest 80 Declaration Detail', 'IT Checklist', 'Chapter VI A Detail', 'Declaration Detail', 'Personalize', 'Salary Slip Control Panel', 'Question Control' ], - 'Page' : ['File Browser', 'Bill of Materials', 'question-view'], + 'Page' : ['File Browser', 'Bill of Materials', 'question-view', 'questions'], 'DocType Mapper': ['Production Forecast-Production Planning Tool', 'Production Forecast-Production Plan', 'Sales Order-Production Plan'], } From 187ac7ccf1aa8cda27cb50b36b95f34f1b5b7c41 Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Wed, 2 May 2012 12:23:44 +0530 Subject: [PATCH 4/4] delete question-view page --- erpnext/patches/jan_mar_2012/sync_ref_db.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/erpnext/patches/jan_mar_2012/sync_ref_db.py b/erpnext/patches/jan_mar_2012/sync_ref_db.py index d65a22ffb8..91a53596cb 100644 --- a/erpnext/patches/jan_mar_2012/sync_ref_db.py +++ b/erpnext/patches/jan_mar_2012/sync_ref_db.py @@ -20,7 +20,7 @@ def execute(): 'Invest 80 Declaration Detail', 'IT Checklist', 'Chapter VI A Detail', 'Declaration Detail', 'Personalize', 'Salary Slip Control Panel', 'Question Control' ], - 'Page' : ['File Browser', 'Bill of Materials', 'question-view', 'questions'], + 'Page' : ['File Browser', 'Bill of Materials', 'question-view'], 'DocType Mapper': ['Production Forecast-Production Planning Tool', 'Production Forecast-Production Plan', 'Sales Order-Production Plan'], }