Example: Create Condition Rules for Absence Occurrences
Workday enables you to control data entry based on absence occurrences. This example illustrates how to create step condition rules on the
Request Time Off
business process to validate time off requests. However, you can configure the same condition rules for these Absence and Time Tracking business processes, where necessary:
- Correct Time Off
- Enter Time
- Request Leave of Absence
- Request Time Off
- Request Return from Leave of Absence
Example: You're an Absence administrator for Global Modern Services. You want to create step condition rules to:
- Require attachments such as a medical certificate when workers are absent 7 calendar days or more.
- Prevent workers requesting absence based on the number of occurrences already in the calendar year.
- Require that workers take a block of time off that includes at least 10 consecutive working days during the calendar year.
Enable absence occurrences for the absence types that you want to validate in the requests such as specific:
- Absence tables.
- Time offs.
- Leave types.
- Custom types.
Security: These domains in the System functional area
- Business Process Administration
- Custom Field Management
- Manage: Business Process Definitions
- Access theCreate Calculated Fieldtask.Create a calculated field that checks whether the length of an absence occurrence is greater than or equal to 7.
- Enter these values:FieldValueField NameAbsence Occurrence with Length greater than or equal to 7Business ObjectCoordinated Absence EventFunctionLookup Field with Prompts
- ClickOK.
- On theCalculationtab, select theLength of Current Absence Occurrence Matchesreport field from theSource Fieldprompt.
- In thePrompts for Source Fieldgrid, enter these values:Prompt FieldValueLength AttributeCalendar DaysAbsence Occurrence TypeSelect the absence type. Example:Monthly Time Off.Length Value7Length Attribute Operatorgreater than or equal to
- ClickOKandCreate Another Calculation.Create a calculated field that checks whether the worker already has an occurrence for a specific absence type in the calendar year.
- Enter these values:FieldValueField NameAbsence Occurrence Event in the Calendar YearBusiness ObjectCoordinated Absence EventFunctionLookup Field with Prompts
- ClickOK.
- On theCalculationtab, select theCount of Absence Occurrences Matchesreport field from theSource Fieldprompt.
- In thePrompts for Source Fieldgrid, enter these values:Prompt FieldValue TypeValueStart DateDetermine Value at RuntimeFirst Day of This Calendar YearEnd DateDetermine Value at RuntimeLast Day of This Calendar YearLength AttributeSpecify ValueWorkdaysCount OperatorSpecify Valuegreater than or equal toAbsence Occurrence TypeSpecify ValueSelect the absence type. Example:Absence Table Sample (Days).Length Attribute OperatorSpecify Valuegreater than or equal to.Count of OccurrencesSpecify Value2
- ClickOKandCreate Another Calculation.Create a calculated field that checks that the worker has requested a block of time off during the calendar year with at least 10 consecutive days.
- Enter these values:FieldValueField NameAbsence Occurrence with Length of 10 or more in the Calendar YearBusiness ObjectCoordinated Absence EventFunctionLookup Field with Prompts
- ClickOK.
- On theCalculationtab, select theCount of Absence Occurrences Matchesreport field from theSource Fieldprompt.
- In thePrompts for Source Fieldgrid, enter these values:Prompt FieldValue TypeValueStart DateDetermine Value at RuntimeFirst Day of This Calendar YearEnd DateDetermine Value at RuntimeLast Day of This Calendar YearLength AttributeSpecify ValueCalendar DaysCount OperatorSpecify Valueless than or equal toAbsence Occurrence TypeSpecify ValueSelect the absence type. Example:Sample Custom Occurrence.Length ValueSpecify Value10Length Attribute OperatorSpecify Valuegreater than or equal toCount of OccurrencesSpecify Value1
- ClickDone.
- Access theRequest Time Offbusiness process definition.Add the calculated fields that you just created to a condition rule on the business process.
- From the related actions menu of the initiation step, select .
- Add a row to theValidation Conditionsgrid for the first condition.
- SelectCreate Condition Rulefrom theRuleprompt.
- In theDescriptionfield, enter:Absence Occurrence is 7 or more days and there is no attachment.
- Define theRule Conditions.And/OrSource External Field or Condition RuleRelational OperatorComparison TypeComparison ValueAndAttachmentsis emptyValue specified in this filterAndAbsence Occurrence with Length greater than or equal to 7equal toValue specified in this filterSelect the check box.
- Select theWarningoption in theSeverityfield.
- Add a row to theValidation Conditionsgrid for the second condition.
- SelectCreate Condition Rulefrom theRuleprompt.
- In theDescriptionfield, enter:Only 1 Absence Occurrence of this type allowed per calendar year.
- Define theRule Conditions.And/OrSource External Field or Condition RuleRelational OperatorComparison TypeComparison ValueAndAbsence Occurrence Event in the Calendar Yearequal toValue specified in this filterSelect the check box.
- Select theCriticaloption in theSeverityfield.
- Add a row to theValidation Conditionsgrid for the third condition.
- SelectCreate Condition Rulefrom theRuleprompt.
- In theDescriptionfield, enter:At least 1 Absence Occurrence of this type in the calendar year is 10 workdays or more.
- Define theRule Conditions.And/OrSource External Field or Condition RuleRelational OperatorComparison TypeComparison ValueAndAbsence Occurrence with Length of 10 or more in the Calendar Yearequal toValue specified in this filterSelect the check box.
- Select theWarningoption in theSeverityfield.
When workers request time off, Workday displays an:
- Alert if the absence occurrence is for 7 calendar days or more and they don't attach a supporting document.
- Error message that prevents them submitting the request, if they've already requested that absence type in the same calendar year.
- Alert if the absence occurrence is for less than 10 consecutive workdays during the calendar year.