Skip to main content

🏢 Adding a New Business to BizPad

This step-by-step guide walks you through adding a new business to the BizPad system in XR-MDT, including branding (logo, colors), permissions, and troubleshooting common problems.

📋 Prerequisites

Before you begin, make sure you have:
  • ✅ A job defined in your framework (qb-core/shared/jobs.lua or ESX jobs table)
  • ✅ A bank account for the business in your banking system (e.g. qb-banking, Renewed-Banking, xr-bank)
  • ✅ Access to the file configs/config.business.lua
  • ✅ (Optional) A logo image (.png, .webp, or .jpg)

📖 How Does BizPad Work?

BizPad is the XR-MDT module designed for businesses and companies. It provides: Each business is identified by its framework job name. The system automatically pulls employees, grades, and data from the database.

🔧 Step 1 — Add the Job to AllowedJobs

Open configs/config.business.lua and add the job name to the AllowedJobs list:
[!IMPORTANT] The name must exactly match the job name in your framework. If shared/jobs.lua (QB) has ['autoexotica'], you must write 'autoexotica' here — not 'AutoExotica' or 'auto_exotica'.

🔧 Step 2 — Add Branding (Logo, Name, Colors)

Add an entry to the JobSettings table to give your business a custom logo, display name, and color theme:
Then place your logo file at:
Supported image formats: .png, .webp, .jpg
[!TIP] If you don’t add a JobSettings entry, the business will still work — it will use the framework’s job label as the name and show no logo. Branding is optional.

🔧 Step 3 — Configure Permissions (Grades)

You have two approaches to configure permissions:

Option A — Use Default Permissions

If you don’t define a custom block for your business, the system automatically uses the ['default'] grades. This is the simplest option for standard businesses. The default config provides 5 grade levels (0–4):
[!TIP] If your business uses a standard 5-grade hierarchy and doesn’t need special permissions — you don’t need to do anything else. Just add it to AllowedJobs and optionally JobSettings.

Option B — Define Custom Permissions Per Business

For businesses with a non-standard hierarchy, add a dedicated block in Grades:
[!WARNING] Grade keys must be strings ('0', '1', '2', etc.), not numbers. The system looks up grades using tostring(job.grade.level). Using numeric keys will cause a permissions lookup failure and the BizPad will appear empty or broken.

🔧 Step 4 — Bank Account Setup

The BizPad dashboard displays balance, revenue, and transaction history. This data comes from your banking system. The bank account must exist under the job name.

Automatically Supported Banking Systems

QB-Core / QBX

The bank account is usually created automatically by qb-management or qb-banking when the job is defined in shared/jobs.lua. No extra steps needed.

ESX

You must manually insert the society account:
[!CAUTION] If the bank account doesn’t exist, the dashboard will show $0 for balance, revenue, and expenses. This is the #1 reason businesses appear broken. Always verify the account exists before reporting a bug.

🔧 Step 5 — Database Tables

The BizPad relies on two database tables that are created by xr-mdt.sql:
[!WARNING] If these tables don’t exist, the invoice and tariff tabs will crash. Run the full xr-mdt.sql migration if you haven’t already.

Verify Tables Exist

Expected output:

🔧 Step 6 — Adjust Limits (optional)

At the bottom of config.business.lua you’ll find global limits:
[!NOTE] Limits are global — they apply equally to all businesses. Per-business limits are not currently supported.

🔧 Step 7 — Restart & Verify

Then log in as a player with the autoexotica job and type /bizpad.

✅ Checklist


🔥 Troubleshooting — Common Business Issues

BizPad opens but shows empty dashboard / $0 everywhere

Cause: The bank account doesn’t exist or your banking resource uses a different table name. Fix:
  1. Verify the bank account exists in your banking system under the exact job name
  2. If your banking system uses a non-standard table, override Bridge.Bank.GetBalance in editable/server/main.lua:

“No Access” notification when opening BizPad

Cause: The player’s job name doesn’t match any entry in AllowedJobs, or the permissions callback returned nil. Fix:
  1. Check the player’s exact job name in F8 console or admin panel
  2. Ensure it’s exactly spelled the same in AllowedJobs
  3. Make sure Config.EnableBusiness = true in config.main.lua

Employee list is empty even though workers are assigned

Cause: Grade mismatch between framework and config, or the database query is filtering out employees. Fix:
  1. Ensure the framework job grades match the Grades keys in your config
  2. For QB: verify that players.job JSON contains the correct job name
  3. For ESX: verify the users.job column matches
  4. Check F8 console for SQL errors

Invoices not being created / “unknown column” error

Cause: The business_invoices table is missing or has an outdated schema. Fix:

Employee management actions fail silently

Cause: The acting player’s grade is lower than or equal to the target’s grade. The system prevents you from promoting/firing someone at or above your own rank. Fix: This is intentional behavior. Only higher-ranked employees can manage lower-ranked ones. The owner (highest grade) can manage everyone.

Finance charts show no data

Cause: Your banking resource doesn’t write to the bank_statements table, which the revenue/expense queries depend on. Fix: Override the finance queries in editable/server/business.lua to use your banking system’s transaction table:
See the full EditTable Business Reference for all overridable queries.

Logo not displaying

Cause: Wrong file path, wrong format, or the file is missing from web/dist/. Fix:
  1. Ensure the file is placed at web/dist/images/biz_yourjob.webp (or .png/.jpg)
  2. Ensure the LogoFile path in JobSettings matches exactly (case-sensitive)
  3. Clear your FiveM cache: AppData/Local/FiveM/FiveM.app/data/cache
  4. Restart the resource

📝 BizPad Permissions Reference


🎯 Minimal Example — Adding a Business in 3 Lines

The simplest way to add a new business (no custom branding, default permissions):
[!TIP] If your business has a standard hierarchy (0 = employee, 1 = experienced, 2 = manager, 3–4 = owner), adding it to AllowedJobs is all you need. Default permissions work immediately.

🎯 Full Example — Business with Custom Branding


© XR-Core Systems | Professional FiveM Resources