How do I customize the MDF Request approval flow?

The Marketing Development Fund feature (MDF) is optimized for partner users. You can optimize the user experience for channel managers by modifying the relevant fields and pages for the needed roles. Since brand owners don't have identical approval processes, MDF provides a flexible and quick way to create pre-approval validations that meet your specific business needs. If your business processes change, you can change your validations accordingly.

Activity management pages are optimized for direct sales. You must modify the activities pages to expose MDF attributes for customers offering MDF programs to their partners.

You must make the appropriate decisions during implementation for the following features that drive MDF request and MDF claim approvals:

  • Approval routing rules

  • Approval process flows

MDF Requests and MDF Claims Approval Routing Rules

MDF requests and MDF claims submitted by partners must be assigned to appropriate personnel in your organization so they can get access to MDF requests or claims based on their roles. For example, people who are approvers must be assigned properly so they can view, approve, reject, or return an MDF request or an MDF claim.

By default, commonly needed approval routing rules for MDF requests and MDF claims are provided. However, you can create your own approval workflow to route MDF requests and MDF claims to the correct approvers.

MDF Request and MDF Claim Approval Process Flows

The default MDF approval processes should meet most MDF request and MDF claim use cases. However, if you need to modify one or both flows, you can do so by editing the included human task flows, using the existing business flows as your templates. The templates are: FundRequestApprovalHumanTask for MDF requests and ClaimApprovalHumanTask for MDF claims.

Use these steps to edit the existing business flow templates in the Worklist application.

  1. Sign in with your sales administrator credentials.

  2. Click the Notification bell icon in the global header.

  3. Click More Details, and then click Customer Relationship Management.

  4. From the user_name drop-down list, select Administration - Task Configuration.

  5. Perform the following steps as needed:

    1. For MDF Requests

      1. Search for Fund% in the search field in the left panel.

      2. Click the Edit icon in the left panel.

      3. In the Assignees tab, and click inside the MDF Request Stage One Approvers box.

      4. Click the FundRequestApproval business rule.

      5. Make the changes you need to fit your business needs.

    2. For MDF Claims

      1. Search for Claim% in the search field in the left panel.

      2. Click the Edit icon in the left panel.

      3. In the Assignees tab, and click inside the MDF Claim Stage One Approvers box.

      4. Click the ClaimRequestApproval business rule.

      5. Make the changes you need to fit your business needs.

  6. Save your changes.

Change the Number of Stages in an Approval Flow

MDF offers up to five approval stages, with both serial and parallel approvals on each stage for both MDF requests and MDF claims. If you need to add additional approval stages to the MDF request or MDF claim flow, follow these steps:

  1. Click the MDF Request or MDF Claim Approval Stage Three box.

  2. Deselect the Ignore Participants check box.

  3. Click Advanced.

  4. Deselect the Ignore Stage check box.

  5. Click MDF Request or MDF Claim Approval Stage Three Approvers.

  6. Click Advanced.

  7. Deselect the Ignore Participants check box.

  8. Save your changes.

To remove stages, you can create rules that skip approval levels. For example, use these steps if you want to have one approval stage for MDF claims:

  1. Create a new rule that skips stage one.

  2. Move this rule so it's the first rule in the UI.

  3. Inactivate the first seeded rule.

Example of Configuring MDF Pre-Approval Validation

Sales administrators can use Application Composer to create customer-defined validations that run before an approver takes action on a submitted MDF request or MDF claim. In this example, a sales administrator for a brand owner creates a validation that ensures MDF requests can only be approved if a budget is associated to the request. When this validation is activated, approvers receive an error message when they try to approve a MDF request that doesn't have an associated budget.

Each human task action requires a separate validation. After you create the validation in Application Composer, you must create a profile option whose value is the name of the object function that will be invoked when the human task action executes. You can configure validations for the following human task actions:

  • Return

  • Approve

  • Reject

  • Withdraw

To create the pre-approval validation, sales administrators must:

  1. Create the validation in Application Composer as an object function under the MDF request object, Server Scripts link.

  2. Create a site level profile option with a value that's the same as the name of the object function that will be invoked.

1. Create and Configure the Validation

Use the following steps to create and configure a validation for MDF requests that ensures a MDF request can only be approved if a budget is associated to it.

  1. Sign in with your sales administrator credentials.

  2. Ensure that you're in a sandbox.

  3. Navigate to Application Composer.

  4. From the list of Standard Objects, select MDF Request.

  5. Select Server Scripts, then select Object Functions, and click Create.

  6. On the Object Function page, provide the following:

    • Function Name: type a name for the function, such as validateMDFRequest.

    • Return: select String.

  7. In the Parameters area, click Create and provide the following:

    • Name: type a name for the parameter, such as parameter.

    • Type: String.

  8. In the Function Body area, type the following:

    def context = parameter?.tokenize(';='); // Replace 'parameter' with whatever parameter name is defined in the object function, in this case it is 'parameter'. .

    def stage = context[1];

    def participant = context[3];

    def user = context[5];

    if(BudgetId ==null && stage == 'SoaOLabel.RequestBudgetFundRequestApprovalStageTwo'){ // This condition is on the second stage which is final stage for the seeded flow

    return "A Budget must be associated to Fund Request before the final approval"; // Error message to be shown on UI if the validation fails

    }

    return null; // Return null otherwise, which means the validation is successful.

  9. Validate the script and click Save and Close.

2. Create and Configure the Profile Option

Use the following steps to create and configure the profile option for the previous validation.

  1. Sign in with your sales administrator credentials.

  2. Ensure that you're in a sandbox.

  3. Navigate to Setup and Maintenance.

  4. Search for and select Manage Profile Options.

  5. Create a new profile option with the following values:

    • Profile Option Code: MKT_FUNDREQUEST_APPROVE_VALIDATION_OBJFUNC (This is the code for Fund Request approve validation; the codes are predefined for object/action validation and must be defined exactly the same)

    • Profile Display Name: Fund Request Approve Validation Object Function

    • Application/Module: Marketing

    • Start Date: Provide a start date for the validation.

  6. Click Save and Close.

  7. Select the Enable check box for the profile option at the Site level only and select the Updatable check box at the site level only.

  8. Click Save and Close.

  9. Test the validation by approving the FundRequest without providing the Budget. It should display the message what was returned in the groovy. Once you complete the testing, you can publish the sandbox.