field changes in sp return tool

This commit is contained in:
Anand Doshi 2012-04-13 12:38:34 +05:30
parent 143291db5b
commit b3ab90a01a

View File

@ -44,17 +44,17 @@ cur_frm.fields_dict.purchase_receipt_no.get_query = function(doc) {
cur_frm.cscript.return_type = function(doc, cdt, cdn) {
var cp = wn.control_panel;
hide_field(['purchase_receipt_no', 'delivery_note_no', 'sales_invoice_no',
'return_details', 'Get Items', 'Make Excise Invoice', 'Make Stock Entry',
'return_details', 'get_items', 'Make Excise Invoice', 'Make Stock Entry',
'Make Debit Note', 'Make Credit Note']);
if(doc.return_type == 'Sales Return') {
unhide_field(['delivery_note_no', 'sales_invoice_no', 'Get Items',
unhide_field(['delivery_note_no', 'sales_invoice_no', 'get_items',
'return_details', 'Make Credit Note', 'Make Stock Entry']);
if(cp.country == 'India') { unhide_field(['Make Excise Invoice']); }
} else if(doc.return_type == 'Purchase Return') {
unhide_field(['purchase_receipt_no', 'Get Items', 'return_details',
unhide_field(['purchase_receipt_no', 'get_items', 'return_details',
'Make Debit Note', 'Make Stock Entry']);
if(cp.country == 'India') { unhide_field(['Make Excise Invoice']); }