16 Commits

Author SHA1 Message Date
Jim Shield
4ec75a90fa Merge pull request #20 from Andyauk/main
Management working for gangs and jobs
2023-02-01 09:30:39 +00:00
Andyauk
baca1add62 Update server.lua 2023-01-28 14:10:10 +00:00
Andyauk
890d8d67b0 Renewed-Banking and QB-Management fixes
Renewed-Banking and QB-Management fixes
2023-01-28 14:05:58 +00:00
Andyauk
5a849f1028 Renewed-Banking and QB-Management fixes
Renewed-Banking and QB-Management fixes
2023-01-28 14:04:27 +00:00
Andyauk
42e3c7d2be Renewed-Banking and QB-Management fixes
Renewed-Banking and QB-Management fixes
2023-01-28 14:03:12 +00:00
Andyauk
28d80261a2 more Management fixes 2023-01-27 01:42:19 +00:00
Andyauk
a61716db2d Management working for gangs and jobs 2023-01-26 18:49:29 +00:00
Andyauk
1c8942a107 Management working for gangs and jobs 2023-01-26 18:48:43 +00:00
Andyauk
bfc3a372d3 Management working for gangs and jobs 2023-01-26 18:48:02 +00:00
Andyauk
2aefb7fa3b toc 2023-01-26 18:47:03 +00:00
Andyauk
1f109ee4c9 toc 2023-01-26 18:45:47 +00:00
Andyauk
4f120d7276 Management working for gangs and jobs 2023-01-26 18:45:19 +00:00
Jim Shield
71a6d4d7dd Merge pull request #13 from jimathy/v2.8.4
v2.8.4
2022-10-08 19:48:02 +01:00
Jim Shield
fc902b34e2 v2.8.4 - Reset default config.lua 2022-10-08 19:46:31 +01:00
Jim Shield
89fa06507b v2.8.4 - Fix logic of the ticket systems 2022-10-08 19:43:57 +01:00
Jim Shield
61e2e6f32e v2.8.4 - Discontinue support for qb-bossmenu 2022-10-08 19:26:21 +01:00
5 changed files with 58 additions and 69 deletions

View File

@@ -108,7 +108,7 @@ RegisterNetEvent('jim-payments:Client:ATM:use', function(data)
--this grabs all the info from names to savings account numbers in the databases
local p = promise.new()
QBCore.Functions.TriggerCallback('jim-payments:ATM:Find', function(cb) p:resolve(cb) end) local info = Citizen.Await(p)
if not Config.Manage then
if not Config.RenewedBanking then
local p = promise.new()
QBCore.Functions.TriggerCallback('qb-bossmenu:server:GetAccount', function(cb) p:resolve(cb) end, PlayerJob.name) info.society = Citizen.Await(p)
local p2 = promise.new()

View File

@@ -1,4 +1,4 @@
print("^2Jim^7-^2Payments ^7v^42^7.^48^7.^43 ^7- ^2Payments Script by ^1Jimathy^7")
print("^2Jim^7-^2Payments ^7v^42^7.^48^7.^45 ^7- ^2Payments Script by ^1Jimathy^7")
-- If you need support I now have a discord available, it helps me keep track of issues and give better support.
@@ -12,10 +12,9 @@ Config = {
---------------------------------
-- Default Job Payment Systems --
---------------------------------
Manage = true, -- "true" if using qb-management
-- "false" if using qb-bossmenu
RenewedBanking = false, -- Enable if using Renewed-Banking (requires Manage to be true and leaving jim-payments banking part separate)
RenewedBanking = false, -- Enable if using Renewed-Banking false if using QB-Management
ApGov = false, -- Toggle support for AP-Goverment Tax
List = true, -- "true" to use nearby player list feature in the cash registers, "false" for manual id entry
@@ -63,6 +62,7 @@ Config = {
-- Commission is a percentage eg "0.10" becomes 10%
Jobs = {
['beanmachine'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
['bakery'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
['burgershot'] = { MinAmountforTicket = 50, PayPerTicket = 50 , Commission = 0.10, },
['catcafe'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
['henhouse'] = { MinAmountforTicket = 50, PayPerTicket = 50, Commission = 0.10, },
@@ -100,7 +100,7 @@ Config = {
BankBlips = false, -- Enable this if you disabled qb-banking and need bank locations
ATMBlips = false, -- Enable this if you are a pyscho and need every ATM to be on the map too
Gabz = true, -- "true" to enable Gabz Bank locations
Gabz = false, -- "true" to enable Gabz Bank locations
-- this corrects the ATM/Bank Cashier + Ticket Cash in location
ATMModels = { `prop_atm_01`, `prop_atm_02`, `prop_atm_03`, `prop_fleeca_atm` },

View File

@@ -1,6 +1,6 @@
name "Jim-Payments"
author "Jimathy"
version "v2.8.3"
version "v2.8.5"
description "Payment Script By Jimathy"
fx_version "cerulean"
game "gta5"
@@ -9,4 +9,4 @@ lua54 'yes'
dependencies { 'qb-input', 'qb-target', }
client_scripts { 'client/*.lua', 'locales/*.lua' }
server_scripts { '@oxmysql/lib/MySQL.lua', 'server/*.lua' }
shared_scripts { 'config.lua', 'shared/*.lua', 'locales/*.lua' }
shared_scripts { 'config.lua', 'shared/*.lua', 'locales/*.lua' }

View File

@@ -70,14 +70,14 @@ RegisterServerEvent('jim-payments:server:ATM:use', function(amount, billtype, ba
elseif tonumber(society) >= amount then
triggerNotify(nil, Loc[Config.Lan].success["draw"]..cv(amount)..Loc[Config.Lan].success["fromthe"]..Player.PlayerData.job.label..Loc[Config.Lan].success["account"], "success", src)
Player.Functions.AddMoney('bank', amount)
if Config.Manage then exports["qb-management"]:RemoveMoney(tostring(Player.PlayerData.job.name), amount)
else TriggerEvent("qb-bossmenu:server:removeAccountMoney", tostring(Player.PlayerData.job.name), amount) end
if Config.RenewedBanking then TriggerEvent("qb-bossmenu:server:removeAccountMoney", tostring(Player.PlayerData.job.name), amount)
else exports["qb-management"]:RemoveMoney(tostring(Player.PlayerData.job.name), amount) end
end
elseif billtype == "deposit" then
if bankB < amount then triggerNotify(nil, Loc[Config.Lan].error["nomoney_bank"], "error", src)
elseif bankB >= amount then
if Config.Manage then exports["qb-management"]:AddMoney(tostring(Player.PlayerData.job.name), amount)
else TriggerEvent("qb-bossmenu:server:addAccountMoney", tostring(Player.PlayerData.job.name), amount) end
if Config.RenewedBanking then TriggerEvent("qb-bossmenu:server:addAccountMoney", tostring(Player.PlayerData.job.name), amount)
else exports["qb-management"]:AddMoney(tostring(Player.PlayerData.job.name), amount) end
Player.Functions.RemoveMoney('bank', amount) Wait(1500)
triggerNotify(nil, Loc[Config.Lan].success["deposited"]..cv(amount)..Loc[Config.Lan].success["into"]..Player.PlayerData.job.label..Loc[Config.Lan].success["account"], "success", src)
end
@@ -100,8 +100,8 @@ RegisterServerEvent('jim-payments:server:ATM:use', function(amount, billtype, ba
local result = MySQL.Sync.fetchAll('SELECT * FROM players WHERE charinfo LIKE ?', {query})
if result[1] then
local Reciever = QBCore.Functions.GetPlayerByCitizenId(result[1].citizenid)
if Config.Manage then exports["qb-management"]:RemoveMoney(tostring(Player.PlayerData.job.name), amount)
else TriggerEvent("qb-bossmenu:server:removeAccountMoney", tostring(Player.PlayerData.job.name), amount) end
if Config.RenewedBanking then TriggerEvent("qb-bossmenu:server:removeAccountMoney", tostring(Player.PlayerData.job.name), amount)
else exports["qb-management"]:RemoveMoney(tostring(Player.PlayerData.job.name), amount) end
if Reciever then
Reciever.Functions.AddMoney('bank', amount)
triggerNotify(nil, Loc[Config.Lan].success["sent"]..amount..Loc[Config.Lan].success["to"]..Reciever.PlayerData.charinfo.firstname.." "..Reciever.PlayerData.charinfo.lastname, "success", src)
@@ -122,14 +122,14 @@ RegisterServerEvent('jim-payments:server:ATM:use', function(amount, billtype, ba
elseif tonumber(gsociety) >= amount then
triggerNotify(nil, Loc[Config.Lan].success["draw"]..cv(amount)..Loc[Config.Lan].success["fromthe"]..Player.PlayerData.gang.label..Loc[Config.Lan].success["account"], "success", src)
Player.Functions.AddMoney('bank', amount)
if Config.Manage then exports["qb-management"]:RemoveGangMoney(tostring(Player.PlayerData.gang.name), amount)
else TriggerEvent("qb-gangmenu:server:removeAccountMoney", tostring(Player.PlayerData.gang.name), amount) end
if Config.RenewedBanking then TriggerEvent("qb-gangmenu:server:removeAccountMoney", tostring(Player.PlayerData.gang.name), amount)
else exports["qb-management"]:RemoveGangMoney(tostring(Player.PlayerData.gang.name), amount) end
end
elseif billtype == "deposit" then
if bankB < amount then triggerNotify(nil, Loc[Config.Lan].error["nomoney_bank"], "error", src)
elseif bankB >= amount then
if Config.Manage then exports["qb-management"]:AddGangMoney(tostring(Player.PlayerData.gang.name), amount)
else TriggerEvent("qb-gangmenu:server:addAccountMoney", tostring(Player.PlayerData.gang.name), amount) end
if Config.RenewedBanking then TriggerEvent("qb-gangmenu:server:addAccountMoney", tostring(Player.PlayerData.gang.name), amount)
else exports["qb-management"]:AddGangMoney(tostring(Player.PlayerData.gang.name), amount) end
Player.Functions.RemoveMoney('bank', amount) Wait(1500)
triggerNotify(nil, Loc[Config.Lan].success["deposited"]..cv(amount)..Loc[Config.Lan].success["into"]..Player.PlayerData.gang.label..Loc[Config.Lan].success["account"], "success", src)
end
@@ -152,8 +152,8 @@ RegisterServerEvent('jim-payments:server:ATM:use', function(amount, billtype, ba
local result = MySQL.Sync.fetchAll('SELECT * FROM players WHERE charinfo LIKE ?', {query})
if result[1] then
local Reciever = QBCore.Functions.GetPlayerByCitizenId(result[1].citizenid)
if Config.Manage then exports["qb-management"]:RemoveGangMoney(tostring(Player.PlayerData.gang.name), amount)
else TriggerEvent("qb-bossmenu:server:removeAccountMoney", tostring(Player.PlayerData.gang.name), amount) end
if Config.RenewedBanking then TriggerEvent("qb-bossmenu:server:removeAccountMoney", tostring(Player.PlayerData.gang.name), amount)
else exports["qb-management"]:RemoveGangMoney(tostring(Player.PlayerData.gang.name), amount) end
if not Reciever then
Reciever.Functions.AddMoney('bank', amount)
triggerNotify(nil, Loc[Config.Lan].success["sent"]..amount..Loc[Config.Lan].success["to"]..Reciever.PlayerData.charinfo.firstname.." "..Reciever.PlayerData.charinfo.lastname, "success", src)
@@ -213,7 +213,7 @@ QBCore.Functions.CreateCallback('jim-payments:ATM:Find', function(source, cb)
local gsociety = 0
-- If qb-management, grab info directly from database
if Config.Manage then
if Config.RenewedBanking then
local result = MySQL.Sync.fetchAll('SELECT * FROM management_funds')
for _, v in pairs(result) do
if Player.PlayerData.job.name == v.job_name then society = v.amount end
@@ -267,3 +267,4 @@ RegisterServerEvent("jim-payments:server:ATM:give", function(citizen, price)
end
else triggerNotify(nil, Loc[Config.Lan].error["zero"], 'error', source) end
end)

View File

@@ -23,26 +23,18 @@ RegisterServerEvent('jim-payments:Tickets:Give', function(data, biller, gang)
local takecomm = math.floor(tonumber(data.amount) * Config.Jobs[data.society].Commission)
if biller then -- If this is found, it ISN'T a phone payment, so add money to society here
if gang then
if Config.Manage then
if Config.RenewedBanking then exports['Renewed-Banking']:addAccountMoney(tostring(biller.PlayerData.gang.name), data.amount - takecomm)
if Config.Debug then print("^5Debug^7: ^3Renewed-Banking^7(^3Gang^7): ^2Adding ^7$^6"..data.amount - takecomm.." ^2to account ^7'^6"..tostring(biller.PlayerData.gang.name).."^7' ($^6"..exports['Renewed-Banking']:getAccountMoney(biller.PlayerData.gang.name).."^7)") end
else
exports["qb-management"]:AddGangMoney(tostring(biller.PlayerData.gang.name), data.amount - takecomm)
if Config.Debug then print("^5Debug^7: ^3QB-Management^7(^3Gang^7): ^2Adding ^7$^6"..data.amount - takecomm.." ^2to account ^7'^6"..tostring(biller.PlayerData.gang.name).."^7' ($^6"..exports["qb-management"]:GetGangAccount(biller.PlayerData.gang.name).."^7)") end
end
else TriggerEvent("qb-gangmenu:server:addAccountMoney", tostring(biller.PlayerData.gang.name), data.amount - takecomm)
if Config.Debug then print("^5Debug^7: ^3QB^7-^3GangMenu^7: ^2Adding ^7$^6"..data.amount - takecomm.." ^2to account ^7'^6"..tostring(biller.PlayerData.gang.name).."^7'") end
if Config.RenewedBanking then exports['Renewed-Banking']:addAccountMoney(tostring(biller.PlayerData.gang.name), data.amount - takecomm)
if Config.Debug then print("^5Debug^7: ^3Renewed-Banking^7(^3Gang^7): ^2Adding ^7$^6"..data.amount - takecomm.." ^2to account ^7'^6"..tostring(biller.PlayerData.gang.name).."^7' ($^6"..exports['Renewed-Banking']:getAccountMoney(biller.PlayerData.gang.name).."^7)") end
else
exports["qb-management"]:AddGangMoney(tostring(biller.PlayerData.gang.name), data.amount - takecomm)
if Config.Debug then print("^5Debug^7: ^3QB-Management^7(^3Gang^7): ^2Adding ^7$^6"..data.amount - takecomm.." ^2to account ^7'^6"..tostring(biller.PlayerData.gang.name).."^7' ($^6"..exports["qb-management"]:GetGangAccount(biller.PlayerData.gang.name).."^7)") end
end
elseif not gang then
if Config.Manage then
if Config.RenewedBanking then exports['Renewed-Banking']:addAccountMoney(tostring(biller.PlayerData.job.name), data.amount - takecomm)
if Config.Debug then print("^5Debug^7: ^3Renewed-Banking^7(^3Job^7): ^2Adding ^7$^6"..data.amount - takecomm.." ^2to account ^7'^6"..tostring(biller.PlayerData.job.name).."^7' ($^6"..exports['Renewed-Banking']:getAccountMoney(biller.PlayerData.job.name).."^7)") end
else
exports["qb-management"]:AddMoney(tostring(biller.PlayerData.job.name), data.amount - takecomm)
if Config.Debug then print("^5Debug^7: ^3QB-Management^7(^3Job^7): ^2Adding ^7$^6"..data.amount - takecomm.." ^2to account ^7'^6"..tostring(biller.PlayerData.job.name).."^7' ($^6"..exports["qb-management"]:GetAccount(biller.PlayerData.job.name).."^7)") end
end
else TriggerEvent("qb-bossmenu:server:addAccountMoney", tostring(biller.PlayerData.job.name), data.amount - takecomm)
if Config.Debug then print("^5Debug^7: ^3QB-BossMenu^7: ^2Adding ^7$^6"..data.amount - takecomm.." ^2to account ^7'^6"..tostring(biller.PlayerData.job.name - takecomm).."^7'") end
if Config.RenewedBanking then exports['Renewed-Banking']:addAccountMoney(tostring(biller.PlayerData.job.name), data.amount - takecomm)
if Config.Debug then print("^5Debug^7: ^3Renewed-Banking^7(^3Job^7): ^2Adding ^7$^6"..data.amount - takecomm.." ^2to account ^7'^6"..tostring(biller.PlayerData.job.name).."^7' ($^6"..tostring(exports['Renewed-Banking']:getAccountMoney(biller.PlayerData.job.name)).."^7)") end
else
exports["qb-management"]:AddMoney(tostring(biller.PlayerData.job.name), data.amount - takecomm)
if Config.Debug then print("^5Debug^7: ^3QB-Management^7(^3Job^7): ^2Adding ^7$^6"..data.amount - takecomm.." ^2to account ^7'^6"..tostring(biller.PlayerData.job.name).."^7' ($^6"..exports["qb-management"]:GetAccount(biller.PlayerData.job.name).."^7)") end
end
end
elseif not biller then --Find the biller from their citizenid
@@ -53,25 +45,25 @@ RegisterServerEvent('jim-payments:Tickets:Give', function(data, biller, gang)
triggerNotify(nil, data.sender..Loc[Config.Lan].success["invoice_start"]..data.amount..Loc[Config.Lan].success["invoice_end"], "success", biller.PlayerData.source)
end
local duty = true
if not biller.PlayerData.job.onduty or gang ~= nil then duty = false end
-- If ticket system enabled, do this
if duty and Config.TicketSystem then
if (biller.PlayerData.job.onduty or gang) and Config.TicketSystem then
if data.amount >= Config.Jobs[data.society].MinAmountforTicket then
if Config.TicketSystemAll then
for _, v in pairs(QBCore.Functions.GetPlayers()) do
local Player = QBCore.Functions.GetPlayer(v)
if Player ~= nil or Player ~= billed then
if Player.PlayerData.job.name == data.society and Player.PlayerData.job.onduty then
if Player.Functions.AddItem('payticket', 1) then TriggerClientEvent('inventory:client:ItemBox', Player.PlayerData.source, QBCore.Shared.Items['payticket'], "add", 1) end
triggerNotify(nil, Loc[Config.Lan].success["rec_rec"], 'success', Player.PlayerData.source)
if gang then
if Player.PlayerData.gang.name == data.society then
if Player.Functions.AddItem('payticket', 1) then TriggerClientEvent('inventory:client:ItemBox', Player.PlayerData.source, QBCore.Shared.Items['payticket'], "add", 1) end
triggerNotify(nil, Loc[Config.Lan].success["rec_rec"], 'success', Player.PlayerData.source)
end
else
if Player.PlayerData.job.name == data.society and Player.PlayerData.job.onduty then
if Player.Functions.AddItem('payticket', 1) then TriggerClientEvent('inventory:client:ItemBox', Player.PlayerData.source, QBCore.Shared.Items['payticket'], "add", 1) end
triggerNotify(nil, Loc[Config.Lan].success["rec_rec"], 'success', Player.PlayerData.source)
end
end
end
if gang then
if biller.Functions.AddItem('payticket', 1) then TriggerClientEvent('inventory:client:ItemBox', biller.PlayerData.source, QBCore.Shared.Items['payticket'], "add", 1) end
triggerNotify(nil, Loc[Config.Lan].success["rec_rec"], 'success', biller.PlayerData.source)
end
end
else
if biller.Functions.AddItem('payticket', 1) then TriggerClientEvent('inventory:client:ItemBox', biller.PlayerData.source, QBCore.Shared.Items['payticket'], "add", 1) end
@@ -79,6 +71,7 @@ RegisterServerEvent('jim-payments:Tickets:Give', function(data, biller, gang)
end
end
end
-- Commission section, does each config option separately
local comm = tonumber(Config.Jobs[data.society].Commission)
if Config.Commission and comm ~= 0 then
@@ -192,16 +185,14 @@ RegisterServerEvent("jim-payments:server:PolCharge", function(citizen, price)
if billed.Functions.RemoveMoney("bank", price) then if Config.Debug then print("^5Debug^7: ^3PolCharge^7 - ^2Player^7(^6"..billed.PlayerData.source.."^7) ^2charged ^7$^6"..price.."^7") end end
if Config.ApGov then exports['ap-government']:chargeCityTax(billed.PlayerData.source, "Item", price) end
if biller.Functions.AddMoney("bank", commission) then if Config.Debug then print("^5Debug^7: ^3PolCharge^7 - ^2Commission of ^7$^6"..commission.." ^2sent to Player^7(^6"..biller.PlayerData.source.."^7)") end end
if Config.Manage then
if Config.RenewedBanking then exports['Renewed-Banking']:addAccountMoney(tostring(biller.PlayerData.job.name), (price - commission))
if Config.Debug then print("^5Debug^7: ^3Renewed-Banking^7(^3Job^7): ^2Adding ^7$^6"..(price - commission).." ^2to account ^7'^6"..tostring(biller.PlayerData.job.name).."^7' ($^6"..exports['Renewed-Banking']:getAccountMoney((biller.PlayerData.job.name).."^7)")) end
else
exports["qb-management"]:AddMoney(tostring(biller.PlayerData.job.name), (price - commission))
if Config.Debug then print("^5Debug^7: ^3QB-Management^7(^3Job^7): ^2Adding ^7$^6"..(price - takecomm).." ^2to account ^7'^6"..tostring(biller.PlayerData.job.name).."^7' ($^6"..exports["qb-management"]:GetAccount(biller.PlayerData.job.name).."^7)") end
end
else TriggerEvent("qb-bossmenu:server:addAccountMoney", tostring(biller.PlayerData.job.name), price - takecomm)
if Config.Debug then print("^5Debug^7: ^3QB^7-^3Bossmenu^7(^3Job^7): ^2Adding ^7$^6"..(price - commission).." ^2to account ^7'^6"..tostring(biller.PlayerData.job.name).."^7'") end
if Config.RenewedBanking then exports['Renewed-Banking']:addAccountMoney(tostring(biller.PlayerData.job.name), (price - commission))
if Config.Debug then print("^5Debug^7: ^3Renewed-Banking^7(^3Job^7): ^2Adding ^7$^6"..(price - commission).." ^2to account ^7'^6"..tostring(biller.PlayerData.job.name).."^7' ($^6"..exports['Renewed-Banking']:getAccountMoney((biller.PlayerData.job.name).."^7)")) end
else
exports["qb-management"]:AddMoney(tostring(biller.PlayerData.job.name), (price - commission))
if Config.Debug then print("^5Debug^7: ^3QB-Management^7(^3Job^7): ^2Adding ^7$^6"..(price - takecomm).." ^2to account ^7'^6"..tostring(biller.PlayerData.job.name).."^7' ($^6"..exports["qb-management"]:GetAccount(biller.PlayerData.job.name).."^7)") end
end
triggerNotify(nil, billed.PlayerData.charinfo.firstname..Loc[Config.Lan].success["charged"]..(price - commission), "success", src)
triggerNotify(nil, Loc[Config.Lan].success["you_charged"]..(price - commission), nil, billed.PlayerData.source)
else
@@ -221,15 +212,12 @@ RegisterServerEvent("jim-payments:server:PolPopup", function(data)
if Config.ApGov then exports['ap-government']:chargeCityTax(billed.PlayerData.source, "Item", data.amount) end
triggerNotify(nil, billed.PlayerData.charinfo.firstname..Loc[Config.Lan].success["accepted_pay"]..data.amount..Loc[Config.Lan].success["charge_end"], "success", data.biller)
if biller.Functions.AddMoney("bank", commission) then if Config.Debug then print("^5Debug^7: ^3PolCharge^7 - ^2Commission^2 of ^7$^6"..commission.." ^2sent to Player^7(^6"..biller.PlayerData.source.."^7)") end end
if Config.Manage then
if Config.RenewedBanking then exports['Renewed-Banking']:addAccountMoney(tostring(biller.PlayerData.job.name), data.amount - commission)
if Config.Debug then print("^5Debug^7: ^3Renewed-Banking^7(^3Job^7): ^2Adding ^7$^6"..(data.amount - commission).." ^2to account ^7'^6"..tostring(biller.PlayerData.job.name).."^7' ($^6"..exports['Renewed-Banking']:getAccountMoney((biller.PlayerData.job.name).."^7)")) end
else
exports["qb-management"]:AddMoney(tostring(biller.PlayerData.job.name), data.amount - commission)
if Config.Debug then print("^5Debug^7: ^3QB-Management^7(^3Job^7): ^2Adding ^7$^6"..data.amount - takecomm.." ^2to account ^7'^6"..tostring(biller.PlayerData.job.name).."^7' ($^6"..exports["qb-management"]:GetAccount(biller.PlayerData.job.name).."^7)") end
end
else TriggerEvent("qb-bossmenu:server:addAccountMoney", tostring(biller.PlayerData.job.name), data.amount - takecomm)
if Config.Debug then print("^5Debug^7: ^3QB^7-^3Bossmenu^7(^3Job^7): ^2Adding ^7$^6"..(data.amount - commission).." ^2to account ^7'^6"..tostring(biller.PlayerData.job.name).."^7'") end
if Config.RenewedBanking then exports['Renewed-Banking']:addAccountMoney(tostring(biller.PlayerData.job.name), data.amount - commission)
if Config.Debug then print("^5Debug^7: ^3Renewed-Banking^7(^3Job^7): ^2Adding ^7$^6"..(data.amount - commission).." ^2to account ^7'^6"..tostring(biller.PlayerData.job.name).."^7' ($^6"..exports['Renewed-Banking']:getAccountMoney((biller.PlayerData.job.name).."^7)")) end
else
exports["qb-management"]:AddMoney(tostring(biller.PlayerData.job.name), data.amount - commission)
if Config.Debug then print("^5Debug^7: ^3QB-Management^7(^3Job^7): ^2Adding ^7$^6"..data.amount - takecomm.." ^2to account ^7'^6"..tostring(biller.PlayerData.job.name).."^7' ($^6"..exports["qb-management"]:GetAccount(biller.PlayerData.job.name).."^7)") end
end
else
triggerNotify(nil, Loc[Config.Lan].error["declined_payment"], nil, src)
@@ -244,4 +232,4 @@ QBCore.Functions.CreateCallback('jim-payments:MakePlayerList', function(source,
onlineList[#onlineList+1] = { value = tonumber(v), text = "["..v.."] - "..P.PlayerData.charinfo.firstname..' '..P.PlayerData.charinfo.lastname }
end
cb(onlineList)
end)
end)