Project Demo

Check out the gitHub project at:
http://github.com/SalesforceFoundation/ApexDoc
Show: global  public  webService  

CaseBusinessAgeAutomator

@description Calculates the Business Age of a case from the start of the day and automatically updates the Business Age field to facilitate reporting in and out of Salesforce.

Properties

Methods

  • CaseBusinessAgeAutomator
    Constructor to initialize the business hours and time unit when using real data.
  • calculateBusinessAge
    Calculates and updates the Business_Age__c field for all accessible Case records, using either the current time (for open Cases) or ClosedDate (for closed Cases) to calculate the BusinessHours diff.

CaseBusinessAgeAutomator

Constructor to initialize the business hours and time unit when using real data.
Parameters
businessHoursId
The ID of the BusinessHours definition to use.
unit
The unit of measure in which to output the Case.Business_Age__c.
calculator
The implementation of BusinessHoursService to use for calculations.

calculateBusinessAge

Calculates and updates the Business_Age__c field for all accessible Case records, using either the current time (for open Cases) or ClosedDate (for closed Cases) to calculate the BusinessHours diff.
Parameters
cases
The list of cases on which to update the Business Age field.

Powered By ApexDoc