fix: Move Default Discount Account field to Item Defaults

This commit is contained in:
GangaManoj
2021-07-13 01:37:30 +05:30
parent 4fcdc5d129
commit 0b7d8fb3af
3 changed files with 104 additions and 457 deletions

View File

@@ -591,8 +591,8 @@ def get_default_expense_account(args, item, item_group, brand):
or brand.get("expense_account")
or args.expense_account)
def get_default_discount_account(args, item_defaults):
return (item_defaults.default_discount_account
def get_default_discount_account(args, item):
return (item.get("default_discount_account")
or args.discount_account)
def get_default_deferred_account(args, item, fieldname=None):