Account link query changed in LC wizard

This commit is contained in:
Nabin Hait 2011-11-17 14:47:05 +05:30
parent f164b269db
commit a8da0fecb5
2 changed files with 2 additions and 1 deletions

View File

@ -4,5 +4,6 @@ def execute():
from webnotes.model import delete_doc from webnotes.model import delete_doc
delete_doc('DocType', 'Landed Cost Wizard') delete_doc('DocType', 'Landed Cost Wizard')
delete_doc('DocType', 'LC PR Detail')
reload_doc('stock', 'doctype', 'landed_cost_wizard') reload_doc('stock', 'doctype', 'landed_cost_wizard')
reload_doc('stock', 'doctype', 'lc_pr_detail') reload_doc('stock', 'doctype', 'lc_pr_detail')

View File

@ -4,5 +4,5 @@ if(!doc.currency){doc.currency = sys_defaults.currency;}
cur_frm.fields_dict['landed_cost_details'].grid.get_field("account_head").get_query = function(doc,cdt,cdn) { cur_frm.fields_dict['landed_cost_details'].grid.get_field("account_head").get_query = function(doc,cdt,cdn) {
return 'SELECT tabAccount.name FROM tabAccount WHERE tabAccount.group_or_ledger="Ledger" AND tabAccount.docstatus != 2 AND (tabAccount.account_type = "Tax" OR tabAccount.account_type = "Chargeable") AND tabAccount.name LIKE "%s"' return 'SELECT tabAccount.name FROM tabAccount WHERE tabAccount.group_or_ledger="Ledger" AND tabAccount.docstatus != 2 AND (tabAccount.account_type = "Tax" OR tabAccount.account_type = "Chargeable" or (tabAccount.is_pl_account = "Yes" and tabAccount.debit_or_credit = "Debit")) AND tabAccount.name LIKE "%s"';
} }