Set Mandatory Budget Type or Fund Type
As an administrator, you can manage budgets and funds in two ways, Fixed Budget and Accrual Budget. Create triggers to select budget type or fund type as mandatory while creating or updating a budget or a fund.
To create the trigger to select of the budget or fund type mandatory:
-
Ensure that you're in an active sandbox.
-
Navigate to the Application Composer.
-
Select Sales from the Application list.
-
Expand
. -
Click Server Scripts.
-
Navigate to the Triggers tab and click
to create a trigger. -
On the Create Object Trigger page, specify the following two triggers:
-
Trigger: Before Insert in Database
Trigger Name: MandatoryFundBudgetType_BeforeInsert
In Trigger Definition, paste the following script from this document and click Save and Close:
if(__ORACO__BudgetFundType_c == null) { throw new oracle.jbo.ValidationException(adf.util.__ORACO__getMessage('ACO_BUDGET_FUND_TYPE')) }
-
Trigger: Before Update in Database
Trigger Name: MandatoryFundBudgetType_BeforeUpdate
In Trigger Definition, paste the following script from this document and click Save and Close:
if(isAttributeChanged('__ORACO__BudgetFundType_c') && __ORACO__BudgetFundType_c == null) { throw new oracle.jbo.ValidationException(adf.util.__ORACO__getMessage('ACO_BUDGET_FUND_TYPE')) }
-
-
Publish the sandbox to create the required trigger.