[fix] [minor] temporarily disabled pos view

This commit is contained in:
Anand Doshi
2013-08-23 19:30:44 +05:30
parent 4d47b007aa
commit 6c0a1a9674
2 changed files with 7 additions and 6 deletions

View File

@@ -288,7 +288,7 @@ erpnext.POS = Class.extend({
<tr>', { <tr>', {
description: d.description, description: d.description,
tax_amount: format_currency(d.tax_amount, me.frm.doc.price_list_currency) tax_amount: format_currency(d.tax_amount, me.frm.doc.price_list_currency)
})).appendTo(".tax-table tbody") })).appendTo(".tax-table tbody");
}); });
// set totals // set totals

View File

@@ -26,9 +26,7 @@ erpnext.accounts.SalesInvoiceController = erpnext.selling.SellingController.exte
} }
} }
if(this.frm.doc.is_pos && this.frm.doc.docstatus===0) {
cur_frm.cscript.toggle_pos(true); cur_frm.cscript.toggle_pos(true);
}
}, },
refresh: function(doc, dt, dn) { refresh: function(doc, dt, dn) {
@@ -97,7 +95,7 @@ erpnext.accounts.SalesInvoiceController = erpnext.selling.SellingController.exte
if(cint(sys_defaults.fs_pos_view)===1) if(cint(sys_defaults.fs_pos_view)===1)
cur_frm.cscript.pos_btn(); cur_frm.cscript.pos_btn();
setTimeout(function() { cur_frm.$pos_btn.click(); }, 1000); // setTimeout(function() { cur_frm.$pos_btn.click(); }, 1000);
} else { } else {
// hide shown pos for submitted records // hide shown pos for submitted records
@@ -125,6 +123,9 @@ erpnext.accounts.SalesInvoiceController = erpnext.selling.SellingController.exte
}, },
toggle_pos: function(show) { toggle_pos: function(show) {
if(cint(sys_defaults.fs_pos_view)===0) return;
if(!(this.frm.doc.is_pos && this.frm.doc.docstatus===0)) return;
if (!this.frm.doc.selling_price_list) if (!this.frm.doc.selling_price_list)
msgprint(wn._("Please select Price List")) msgprint(wn._("Please select Price List"))
else { else {