How do I analyze the requirements for an autocomplete rule?
Hello, my name is Steve. In this video, I’ll explain how to analyze the requirements for an autocomplete rule.
Every business is different and has its own requirements to enforce the rules governing the implementation of the application. Before creating an autocomplete rule, you should look at the existing functionality and analyze your requirements.
For example, let's say that you would like to use an autocomplete rule to enforce that employee transfers can happen only on certain days of the month. You can highlight specific key words in the requirement to help you determine what needs to be coded in the rule, and which values you want to check in the object fields. This will help you answer the question, "What date am I validating?".
In another example, you want to prevent the termination of employees while they are on a leave of absence. Highlighting key words will help you answer the question, "What fields am I validating?".
There are three considerations for analyzing a requirement. First, identify the field that you want to default or validate. It's important to identify the section containing the field. For example, if your requirement is to validate the Assignment Effective Date, then most likely you want the rule to trigger in the When and Why section where the date is required.
The second part of the requirement is to consider the user experience. Here you should focus on the guided process flow in the UI. For validation, you can have the rule trigger when:
-
Entering a section
-
Tabbing out of a field
-
Exiting a section
-
Clicking the Submit button
When you decide what the user experience should be for the rule, you’ll then know which type of rule you should use.
And the third part of the requirement is to list out the criteria for defaulting or validating a field. Some criteria involve current fields, while others may involve sections that the user has already filled out in the process flow. Still others may involve predetermined setup data. Since autocomplete rules only work on mobile responsive user interfaces, ensure the fields identified in the criteria are visible and editable; either as delivered or as set by using the transaction design studio.
You can break your requirement into logical chunks of information, such as what, where, when, and which criteria. First, create a description of the requirement. Similar to some rules we looked at earlier, you can highlight the key words in the description. Then decide if you are defaulting a field, or validating a field. Decide where the rule will be triggered and by which actions. For example, when hiring an employee in the Hire an Employee flow. Determine when the rule should be triggered, such as after tabbing out of a field or when clicking the Continue or Submit button. Then decide which criteria and field values you need for the business logic of your rule.
Now, let’s look at an example. Let’s say that your organization requires all full time employees have at least 40 working hours. Since this is a requirement of your organization, you will need to validate that the employee has at least 40 working hours and if not then an error is generated. Next, you have to determine all the flows where this validation needs to occur. In this example, it is at the following flows:
-
Add Non-worker
-
Add Pending Worker
-
Change Assignment
-
Add contingent Worker
-
Hire an Employee
The rule will be triggered upon clicking Continue or Submit in any of the flows.
Based on the rule, the criteria needs to include checking the Employment Details of Assignment Category to ensure the employee is full time and Working Hours to ensure they are at least 40 hours. In this rule, the requirement is if the value for weekly working hours is equal to, or greater than, forty, the value for the Full Time or Part Time field will be Full Time. Otherwise, it will be Part Time.
What type of rule should this be?
-
Validating
-
Defaulting
In this example, the value entered in the Working Hours field should determine the default of the Full Time or Part Time field value. Therefore, this is a defaulting autocomplete rule.
Where in the UI should the rule be triggered? Meaning which fields will trigger the rule.
-
Working Hours
-
Working Category
-
Full Time or Part Time
-
Hourly Paid or Salaried
The answer is 1 – Working Hours. When the Working Hours value is entered, the Full Time or Part Time field value should default.
When should the rule be triggered? This determines the actions that trigger the rule.
-
Entering a section
-
Tabbing out of a field
-
Exiting a section
-
Clicking the Submit button
The answer is 2. This rule should trigger the default of the Full Time or Part Time field when you tab out of the Working Hours field.
Now we need to list all of the criteria, objects and fields, that you need for your rule. Which values on the Work Assignment object are needed for this rule?
-
Working Hours
-
Employee Category
-
Frequency
-
Person Type ID
-
Full Time or Part Time
When the Working Hours and Frequency are entered the rule will default the value in the Full Time or Part Time field accordingly. Therefore, the answers are 1, Working Hours, 3, Frequency, and 5, Full Time or Part Time.
This concludes the explanation of how to analyze requirements for autocomplete rules.
Thanks for watching.