ACP QBCore
Logs
User Punish Logs

Insert Punish Log

This log entry records the sanctions applied to a player, contributing to their overall sanction history. By maintaining a comprehensive record of all sanctions, it simplifies the review of a player's accumulated sanctions.

local details = {
    citizenid = citizenid,    -- Replace 'citizenid' with the actual user ID
    type = 'ban',             -- Type of punish log, but we have only 'ban' type right now
    text = 'Robert has received a Temporary Ban for 15 days from ServerAdmin  Reason: ban reason here'   -- Punish Log Text
}
 
exports['syn-acp']:insertPunish(details)

Parameters Description

citizenid => Parameter Description:
The unique identifier for the user being punished.

type (string) => Parameter Description:
The type of punishment applied. Currently, only 'ban' is supported.

text (string) => Parameter Description:
A detailed description of the punishment. This includes the duration of the ban, the administrator who issued it, and the reason for the ban.