fix: cost center & account validation in Sales/Purchase Taxes and Charges (#26881)

This commit is contained in:
Frappe PR Bot
2021-08-10 19:38:39 +05:30
committed by GitHub
parent 66784a16cb
commit 1a39d1a311
6 changed files with 45 additions and 5 deletions

View File

@@ -124,7 +124,8 @@ def make_taxes_and_charges_template(company_name, doctype, template):
account_data = tax_row.get('account_head')
tax_row_defaults = {
'category': 'Total',
'charge_type': 'On Net Total'
'charge_type': 'On Net Total',
'cost_center': frappe.db.get_value('Company', company_name, 'cost_center')
}
if doctype == 'Purchase Taxes and Charges Template':