ZX MDT documentation.
A quick guide to installing, configuring and integrating ZX MDT on a QBox FiveM server.
Install the three core dependencies, configure the resource, then ensure ZX MDT after your selected integrations.
View installation →Requirements
ZX MDT is built for QBox / qbx_core and requires the following resources.
- qbx_core
- ox_lib
- oxmysql
Your selected garage, housing, phone, licence and inventory integrations must also be installed and started before ZX MDT. Profile-photo capture additionally uses screenshot-basic and FiveManage when enabled.
Installation
- 1Upload the resource
Place the folder in your resources directory and keep the resource name as
zx-mdt. - 2Configure ZX MDT
Edit the files inside the
config/folder for your jobs, permissions and integrations. - 3Set up SQL
Leave
Config.AutoInsertSQL = truefor automatic setup, or disable it and manually importzx-mdt.sql. - 4Start the resource
Ensure dependencies and selected integrations before
zx-mdt.
ensure oxmysql
ensure ox_lib
ensure qbx_core
# Start your selected integrations here
# ensure ox_inventory
# ensure jg-advancedgarages
ensure zx-mdt
The MDT opens with /mdt or the default F6 keybind. Both can be changed or disabled in the config.
Configuration
The main settings are split across the config/ folder so you can update the resource without editing the MDT core.
Config.AutoInsertSQL = true
Config.AllowedJobs = {
['police'] = true,
['sheriff'] = true,
['sasp'] = true,
}
Config.Command = 'mdt'
Config.CommandOpen = true
Config.Keybind = 'F6'
Config.KeybindOpen = true
Config.Item = false
Config.ItemName = 'police_mdt'
Config.Locale = 'en'
Use config/permissions.lua to control who can create, edit, delete or manage sensitive MDT records.
Use config/navigation.lua to hide pages your server does not use.
Integrations
Select the resources your server actually uses in config/integrations.lua.
Config.Garage = 'jg-advancedgarages'
Config.Housing = 'qbx-properties'
Config.Licenses = 'qbx'
Config.Phone = 'nx-phone'
Config.Inventory = 'ox_inventory'
qbx-garages, jg-advancedgarages, quasar-advancedgarages, custom or none.
qbx-properties, quasar-housing, custom or none.
nx-phone, qb-phone, qs-smartphone, lb-phone, custom or none.
ox_inventory, qb-inventory, qs-inventory or custom.
Client exports
Use these from another client-side resource.
exports['zx-mdt']:open()
exports['zx-mdt']:close()
local opened = exports['zx-mdt']:isOpened()
Server exports
The current build exposes the following server-side exports.
GetOwnedVehicles(citizenId)
GetOwnedProperties(citizenId)
GetHouses(query)
GetHouseData(id)
LookupVehicle(plate)
GetCitizenLicenses(citizenId)
GetCitizenPhoneNumber(citizenId)
GetRegisteredProviders()
GetGarageIntegration()
GetHousingIntegration()
GetLicenseIntegration()
GetPhoneIntegration()
GetInventoryIntegration()
IsReady()
GetVersion()
GetVehicleHistory(plate)
AddVehicleHistory(plate, action, details, officerName, incidentId)
GetVehicleFlags(plate)
GetActiveWarrants(citizenId)
GetCitizenFlags(citizenId)
GetCitizenProfile(citizenId)
AddIncidentActivity(incidentId, actionType, message, officerName)
RefreshMDTClients()
Example
local profile = exports['zx-mdt']:GetCitizenProfile(citizenId)
local warrants = exports['zx-mdt']:GetActiveWarrants(citizenId)
local vehicle = exports['zx-mdt']:LookupVehicle(plate)
Events
These are the useful public events exposed by the resource.
TriggerEvent('zx-mdt:client:open')
TriggerEvent('zx-mdt:client:close')
TriggerEvent('zx-mdt:client:refresh', payload)
AddEventHandler('zx-mdt:server:ready', function()
print('ZX MDT is ready')
end)
Before opening a ticket
If something is not working, include enough information for the issue to be reproduced quickly.
- ZX MDT version
- Your framework and selected integrations
- Relevant client/server console errors
- Steps to reproduce the problem
- Your order number when requesting customer support
Make sure qbx_core, ox_lib, oxmysql and any selected integration resources start before ZX MDT.