Config Files

The script is fully configurable, enabling you to tailor its behavior and features to your needs. Below is a list of the configuration files included in the resource.

Config = Config or {}

--========================================================--
-- Framework
--========================================================--
Config.Framework = Config.Framework or "auto"  -- "auto" | "qbcore" | "esx"

--========================================================--
-- Commands
--========================================================--
Config.Command     = "adsjob"
Config.OpenCommand = Config.Command

Config.AnnounceCommand = "sendad"

--========================================================--
-- Job Management
--========================================================--
Config.CreateCooldownSeconds = 10
Config.MaxJobsStored = 10

Config.MaxJobNameLength  = 32
Config.MaxJobLabelLength = 48


--========================================================--
Config.UI = {
  Title     = "JOB ADS",
  Subtitle  = "iZaap Studios β€’ Job Board",
  CloseHint = "Press ESC to close"
}

--========================================================--
-- Announcements
--========================================================--
Config.AnnounceCooldownSeconds = 15
Config.MaxAnnounceMessageLength = 180
Config.MaxAnnounceLines         = 6

--========================================================--
-- Webhooks
--========================================================--
Config.Webhooks = {
  Enabled  = true,
  Admin    = "TU_WEBHOOK_ADMIN",
  Announce = "TU_WEBHOOK_ANNOUNCE"
}

Config.Logs = {
  -- Nota: Enabled aquΓ­ no lo usa el server actual como apagador
  Enabled = true,
  ColorAdmin    = 16763904,
  ColorAnnounce = 5793266,
}

--========================================================--
-- notify
--========================================================--
Config.Messages = {
  NoPermission         = "You do not have permission to use AdsJob.",

  CooldownCreate       = "You must wait {seconds}s to create another job ad.",
  MissingJobOrLabel    = "Please fill in the job name and the label.",
  DuplicateJob         = "A job ad for \"{job}\" already exists.",
  InvalidURL           = "Invalid URL. Use http(s) and avoid special characters.",
  InvalidColor         = "Invalid color. Use #RRGGBB format.",
  InvalidBodyColor     = "Invalid body color. Use #RRGGBB format.",
  DBInsertError        = "Database error while saving.",
  CreatedSuccess       = "Job ad created successfully.",
  UpdatedSuccess       = "Job ad updated successfully.",
  DeletedSuccess       = "Job ad deleted successfully.",
  InvalidId            = "Invalid ID.",
  UpdateMissingId      = "Could not update (ID does not exist).",
  DeleteMissingId      = "Could not delete (ID does not exist).",

  AnnounceNoJobDetected = "Could not detect your job.",
  AnnounceNoAdForJob    = "Your job does not have an ad created.",
  AnnounceCooldown      = "Wait {seconds}s before sending another announcement.",
  AnnounceEmptyMessage  = "Please write a message.",
  AnnounceSent          = "Announcement sent."
}

--========================================================--
Config.Text = {
  UI = {
    Title     = "JOB ADS",
    Subtitle  = "iZaap Studios β€’ Job Board",
    CloseHint = "Press ESC to close"
  },

  Panel = {
    ListTitle    = "Listing",
    ListSub      = "Created job advertisements",
    AddJobButton = "Add job",

    EmptyTitle = "No job ads have been created yet.",
    EmptySub   = "Press β€œAdd job” to create the first one."
  },

  Modal = {
    TitleCreate = "Create job advertisement",
    TitleEdit   = "Edit job advertisement",
    SubTitle    = "Fill in the job information",

    JobNameLabel       = "Job name (job)",
    JobNamePlaceholder = "e.g. police, mechanic, taxi",

    LabelLabel         = "Label",
    LabelPlaceholder   = "e.g. Police, Mechanic, Taxi",

    BgLabel            = "Background image (FiveManage URL)",
    BgPlaceholder      = "https://...png / jpg / webp",

    LogoLabel          = "Logo (FiveManage URL)",
    LogoPlaceholder    = "https://...png / webp",

    ColorLabel         = "Accent Color",
    ColorHint          = "Use the picker or paste the HEX (e.g. #FBFF00).",

    BodyColorLabel     = "Body Color (Broadcast)",
    BodyColorHint      = "Background color for the broadcast message body only.",

    PreviewNote        = "Preview",

    CancelButton       = "Cancel",
    SaveButton         = "Save",
    SaveChangesButton  = "Save changes"
  },

  Confirm = {
    Title = "Confirmation",
    Text  = "Are you sure?",
    No    = "Cancel",
    Yes   = "Delete"
  },

  Announce = {
    Title = "SEND ANNOUNCEMENT",

    ScopeTitle  = "Announcement scope",
    ScopeGlobal = "Global",
    ScopeJob    = "Job",

    ShowJobName = "Show job name below",
    HideAuthor  = "Hide author",

    MessageLabel       = "Message",
    MessagePlaceholder = "Write your announcement...",

    EmojisTitle    = "Emojis",
    EmojisBtnAria  = "Emojis",
    EmojisBtnTitle = "Emojis",

    InfoTitle = "INFORMATION",
    Info1 = "β€” If you choose Global, everyone will see it.",
    Info2 = "β€” If you choose Job, only players with the same job will see it.",
    Info3 = "β€” Design uses background/logo/colors from the ad created in your AdsJob panel.",

    CancelButton = "Cancel",
    SendButton   = "Send",
    SendHint     = "It will be sent using the selected scope."
  },

  Broadcast = {
    ScopeGlobal  = "GLOBAL",
    ScopeJob     = "JOB",
    DefaultLabel = "ANNOUNCEMENT"
  },

  Defaults = {
    JobLabel = "JOB"
  }
}

Last updated