Reports (ed_reports)

Advanced report system.

Installation

Download the Script

Download the script using keymaster.

Add it to your resources

Open the downloaded zip, copy ed_reports & put it inside your resources.

Start the Script

Terminal
refresh
start ed_reports

Finally, if everything is right, you can put it inside your server.cfg as follows:

server.cfg
ensure ed_reports

Install screenshot-basic (optional)

screenshot-basic is needed for screenshots to work.

If you decide to install it, you do not need to change anything. Script will automatically detect its existence.

Configuration

config.lua
config_server.lua
translations.lua
-- https://edeverce.com/scripts/reports

Config = {
   ---@type "default"|"blue"|"green"|"red"|"rose"|"orange"|"violet"|"yellow"
   -- UI theme. See https://edeverce.com/guides/theming for more advanced configuration.
   theme = "default",

   ---@type string
   -- Shorthand for myReports command, it displays submit dialog immediately for faster report submission.
   reportCommand = "report",

   ---@type string
   -- Command to display players previous reports.
   myReportsCommand = "myreports",

   ---@type string
   -- Command for staff to display reports dashboard.
   reportsCommand = "reports",

   ---@type number
   -- Cooldown (ms) of sending chat messages.
   chatCooldown = 1500,

   ---@type string[]
   -- Categories to display.
   categories = { "Question", "Bug", "Player" },

   ---@type boolean
   -- Determines whether to use built-in notification system or not.
   handleNotifications = true,

   ---@type fun(type: string, title: string, description: string)
   -- If handleNotifications set to false, this function will be called.
   notificationHandler = function(type, title, description)
      --ESX
      /*
         ESX = exports["es_extended"]:getSharedObject()
         ESX.ShowNotification(title .. " / " .. description, type)
      */

      --QB
      --TriggerEvent("QBCore:Notify", { text = title, caption = description })
   end,

   ---@type number
   -- Limited amount of reports handled by a staff at a time.
   acceptedReportLimit = 3,

   ---@type boolean
   -- Determines whether to take screenshot when a player submits a report.
   screenshotOnSubmit = true
}