Merge pull request #16621 from netchampfaris/fix-warehouse-currency

fix: Set company_currency for Warehouse Tree
This commit is contained in:
rohitwaghchaure 2019-02-11 14:58:02 +05:30 committed by GitHub
commit d95c8cfac3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -157,6 +157,8 @@ def get_children(doctype, parent=None, company=None, is_root=False):
# return warehouses
for wh in warehouses:
wh["balance"] = get_stock_value_from_bin(warehouse=wh.value)
if company:
wh["company_currency"] = frappe.db.get_value('Company', company, 'default_currency')
return warehouses
@frappe.whitelist()