Setting up violations

After you have set up an event, you can set up violations. The events that constitute a violation are determined during setup. Employees trigger a violation when they accrue the threshold points that are associated with the violation.

  1. Select Maintenance > Optional Modules > Attendance Control > Violation Setup.
  2. Click Create New Entry.
  3. Specify this information:
    Violation Name
    Specify the name of the violation.
    Description
    Optionally, specify a short description of the violation.
    Period Type
    Select the time period to which the violation applies (such as, calendar year or last 30 days).
    Pay Groups
    Optionally, select the pay groups to which the violation applies. If left blank, this field defaults to all pay groups.
    Calc Groups
    Optionally, select the calculation groups to which the violation applies. If left blank, this field defaults to all calculation groups.
    Event Names
    Select the events that constitute a violation. The application cannot process the violation if events are not specified in this field.
    Threshold Points
    Specify the number of points an employee must accumulate to trigger the violation.
    Condition
    Optionally, specify the customizable condition under which the violation is assigned to the employee.

    You can populate this field with any custom condition that implements the com.workbrain.app.modules.ac.testviolation.TestViolation interface, as defined below:

    /**
    * Interface to a condition class. If an implementation
    * returns true, a new violation log is created for the given 
    * and any associated event logs.
    */
    public interface TestViolation {
      /**
      * Executes a customized testing logic and returns
      * true if the given employee, event log, violation and sum 
      * of points pass the test.
      *
      * @param conn database connection
      * @param employee employee
      * @param eventLog event log
      * @param violation violation
      * @param sumPoints sum of points
      * @return true if the parameters pass this test
      * @throws ACException
      */
      public boolean test( DBConnection conn, 
        EmployeeData employee, ACEventLogData eventLog, 
        ACViolationData violation, int sumPoints )
        throws ACException;
    }
    Action
    Optionally, specify the customizable action that is assigned to the violation. The action is triggered when the violation is recorded by the system. The action can be any Oracle procedure accepting one parameter. The acviolog_id of the Violation Log being authorized will be passed to this procedure.
    Priority
    Specify a number to represent the priority of the violation. Violations with priority of 1 are considered first by the system.
    Ignore
    Optionally, select this check box to ignore the Action when the violation is authorized by a supervisor.
    Exclude
    Optionally, select this check box to exempt previously triggered events when calculating the violation. Only events that are associated with other “exclude” violations will be excluded.

    For example, an employee is late three times and triggers a verbal violation. If the employee is late again, it will be considered their first late, not their fourth. In effect, the employee's current point total is reset.

    Acviol Flag1-10 (Violation Flag1-10)
    Optionally, select flag options for a set of customizable violation property flags. These user defined flags are linked to the EMPLOYEE record flags. If the user defined Flag1 is defined in the EMPLOYEE table, then Violation Flag1 can be used to filter employees with Flag1 defined.
    Acviol UDF1-10 (Violation UDF1-10)
    Optionally, specify field options from a set of customizable violation property fields. These user defined fields (UDFs) are linked to the EMPLOYEE record UDFs. If the UDF1 is defined in the EMPLOYEE table, then Violation UDF1 can be used to filter employees with UDF1 defined.
    Teams
    Optionally, select the teams to which the violation applies. If left blank, this field defaults to all teams.
    Include Sub Teams
    Optionally, select this check box to include the sub teams of the teams to which the violation applies.
    Employees
    Optionally, select the employees to which the violation applies. If left blank, this field defaults to all employees.
    Note: Because of the way the application processes events and violations, these lookups should not be configured with the optional ALL button. If left blank, the lookup defaults to all values, so the button is unnecessary.
  4. Click Save.