🛠️Installation
Item Installation
["aviator_license"] = {
label = "Aviator Licenses",
weight = 10,
stack = true,
close = true,
client = {
image = "aviator_license.png",
}
},Metadata Installation
If you are using ox_inventory or most recent qb-inventory ignore this
} else if (itemData.name == "aviator_license") {
$(".item-info-title").html("<p>" + itemData.label + "</p>");
$(".item-info-description").html(
"<p><strong>Name: </strong><span>" +
itemData.info.name +
"</span></p><p><strong>Description: </strong><span>" +
itemData.info.description +
"</span></p>"
);} else if (itemData.name == "aviator_license") {
$(".item-info-title").html("<p>" + itemData.label + "</p>");
$(".item-info-description").html(
"<p><strong>Name: </strong><span>" +
itemData.info.name +
"</span></p><p><strong>Description: </strong><span>" +
itemData.info.description +
"</span></p>"
);} else if (item.name.match("aviator_license")) {
let infoData = [
{ label: "Name", value: iteminfo.name || "Unknown" },
{ label: "Description", value: iteminfo.description|| "Unknown" },
];
returnString = infoData;} else if (
itemData.name == "aviator_license"
) {
html = `
<div class="item_info_container">
<div class="item_info_row">
<div class="item_info_row_left">Name:</div>
<div class="item_info_row_right"> ${itemData.info.name}</div>
</div>
<div class="item_info_row">
<div class="item_info_row_left">Description: </div>
<div class="item_info_row_right"> ${itemData.info.description}</div>
</div>
</div>
`;Database Installation
If you want jump this database installation you can active the option Config.AutoDatabaseon config.lua file.
CREATE TABLE IF NOT EXISTS `aviator_licenses` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`charid` varchar(50) NOT NULL,
`owner_name` varchar(50) NOT NULL,
`owner_licenses` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NOT NULL CHECK (json_valid(`owner_licenses`)),
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_general_ci;Jobs Installation
If you are using ESX you can active the option Config.AutoDatabaseon config.lua file and the script run all correctly.
INSERT INTO `jobs` (`name`, `label`, `whitelisted`)
SELECT 'aviator', 'Aviator', 1
WHERE NOT EXISTS (SELECT 1 FROM `jobs` WHERE `name` = 'aviator');
INSERT INTO `job_grades` (`job_name`, `grade`, `name`, `label`, `salary`, `skin_male`, `skin_female`)
SELECT 'aviator', 0, 'recruit', 'Recruit', 500, '{}', '{}'
WHERE NOT EXISTS (SELECT 1 FROM `job_grades` WHERE `job_name` = 'aviator' AND `grade` = 0);
INSERT INTO `job_grades` (`job_name`, `grade`, `name`, `label`, `salary`, `skin_male`, `skin_female`)
SELECT 'aviator', 1, 'teacher', 'Teacher', 1000, '{}', '{}'
WHERE NOT EXISTS (SELECT 1 FROM `job_grades` WHERE `job_name` = 'aviator' AND `grade` = 1);
INSERT INTO `job_grades` (`job_name`, `grade`, `name`, `label`, `salary`, `skin_male`, `skin_female`)
SELECT 'aviator', 2, 'boss', 'Boss', 2000, '{}', '{}'
WHERE NOT EXISTS (SELECT 1 FROM `job_grades` WHERE `job_name` = 'aviator' AND `grade` = 2);Last updated