Introduction to Attendance Mode

The Attendance Mode is designed for the access control device to be used for time attendance. In this mode, access control functions are disabled. Additionally, it is possible to select the type of clock-in, such as check-in, check-out, break, etc.

In Attendance Mode, access rules are disabled. In this configuration, if the user is registered in the device's database, he will have his attendance registered by identifying himself.

This operating mode can be used in two different ways:

  • Without customization of the clock-in type.

  • With customization of the clock-in type, where it is fully customizable. In this case, the user must select the type of clock-in from the device's display before identifying themselves.

Settings

To configure Attendance Mode, the following parameters are required:

Field Type Description
attendance_mode int Enables (1) or disables (0) Attendance Mode.
log_type int Determines whether it is possible (1) or not (0) to customize the attendance log types.

Request Example

This request configures the Attendance Mode without customization of the clock-in type.

$.ajax({
    url: "/set_configuration.fcgi?session=" + session,
    type: 'POST',
    contentType: 'application/json',
    data: JSON.stringify(
        {
            "general": {
                "attendance_mode": "1"
            },
            "identifier" : {
                "log_type": "0"
            }
        }
    )
});

This request configures the Attendance Mode with customization of the clock-in type.

$.ajax({
    url: "/set_configuration.fcgi?session=" + session,
    type: 'POST',
    contentType: 'application/json',
    data: JSON.stringify(
        {
            "general": {
                "attendance_mode": "1"
            },
            "identifier" : {
                "log_type": "1"
            }
        }
    )
});

Exporting the Clock-In Logs Report

This section presents an example of a request used to export a report of clock-in logs, with customized clock-in types, using the /report_generate.fcgi report export API.

The request below generates a report containing the logs of the customized clock-ins. For a better understanding of the parameters used in this request, refer to the Export Report section, where all fields are explained in detail.

Request Example

Generating the report:

$.ajax({
  url: "/report_generate.fcgi?session=" + session,
  type: 'POST',
  contentType: 'application/json',
  data: JSON.stringify({
      "order": [
            "descending",
            "time"
        ],
        "where": {
            "access_logs": {
                "id": [
                    8,
                    7,
                    6,
                    5,
                    4,
                    3
                ]
            },
            "log_types": {},
            "users": {},
            "groups": {},
            "time_zones": {}
        },
        "object": "access_logs",
        "delimiter": ";",
        "line_break": "\\r\\n",
        "header": ";Date and Time;Register ID;Register Status;Authorization;Identification Type;Id (User);Name (User);Registration (User);Name (Portal)",
        "file_name": "",
        "join": "LEFT",
        "columns": [
            {
                "type": "object_field",
                "object": "access_logs",
                "field": "time",
                "format": {
                    "adjustment": 0,
                    "width": 0,
                    "fill": "0",
                    "format": "%d/%m/%Y %H:%M:%S"
                }
            },
            {
                "type": "object_field",
                "object": "log_types",
                "field": "id",
                "format": {
                    "adjustment": 2,
                    "width": 4,
                    "fill": "0",
                    "format": ""
                }
            },
            {
                "type": "object_field",
                "object": "log_types",
                "field": "name",
                "format": {
                    "adjustment": 1,
                    "width": 50,
                    "fill": " ",
                    "format": ""
                }
            },
            {
                "type": "object_field",
                "object": "access_logs",
                "field": "event",
                "format": {
                    "adjustment": 2,
                    "width": 2,
                    "fill": "0",
                    "format": ""
                }
            },
            {
                "type": "object_field",
                "object": "access_logs",
                "field": "identifier_id",
                "format": {
                    "adjustment": 1,
                    "width": 1,
                    "fill": " ",
                    "format": ""
                }
            },
            {
                "type": "object_field",
                "object": "users",
                "field": "id",
                "format": {
                    "adjustment": 2,
                    "width": 15,
                    "fill": "0",
                    "format": ""
                }
            },
            {
                "type": "object_field",
                "object": "users",
                "field": "name",
                "format": {
                    "adjustment": 1,
                    "width": 50,
                    "fill": " ",
                    "format": ""
                }
            },
            {
                "type": "object_field",
                "object": "users",
                "field": "registration",
                "format": {
                    "adjustment": 1,
                    "width": 50,
                    "fill": " ",
                    "format": ""
                }
            },
            {
                "type": "object_field",
                "object": "portals",
                "field": "name",
                "format": {
                    "adjustment": 1,
                    "width": 50,
                    "fill": " ",
                    "format": ""
                }
            }
        ]
  })
});

The report generated by this request includes the following columns:

  • Date and Time: The date and time when the event was recorded in the system.
  • Register ID: Unique identifier of the clock-in type.
  • Register Status: The type of event (e.g., check-in, lunch, check-out, etc.).
  • Authorization: Indicates whether access was granted or denied.
  • Identification Type: The method of identification used (e.g., card, biometry, facial, etc.).
  • Id (User): The user's unique identifier in the system.
  • Name (User): The user's name.
  • Registration (User): The registration number associated with the user.
  • Name (Portal): The name of the portal or location where the clock-in was registered.