mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-31 10:49:09 +00:00
refactor(test): utlity method to set cumulative actions
This commit is contained in:
@@ -479,6 +479,15 @@ def make_budget(**args):
|
|||||||
args.action_if_accumulated_monthly_budget_exceeded_on_po or "Warn"
|
args.action_if_accumulated_monthly_budget_exceeded_on_po or "Warn"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
if args.applicable_on_cumulative_expense:
|
||||||
|
budget.applicable_on_cumulative_expense = 1
|
||||||
|
budget.action_if_annual_exceeded_on_cumulative_expense = (
|
||||||
|
args.action_if_annual_exceeded_on_cumulative_expense or "Warn"
|
||||||
|
)
|
||||||
|
budget.action_if_accumulated_monthly_exceeded_on_cumulative_expense = (
|
||||||
|
args.action_if_accumulated_monthly_exceeded_on_cumulative_expense or "Warn"
|
||||||
|
)
|
||||||
|
|
||||||
budget.insert()
|
budget.insert()
|
||||||
budget.submit()
|
budget.submit()
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user