fix for tickets with new popup

This commit is contained in:
jimathy
2022-03-12 12:56:30 +00:00
committed by GitHub
parent 3e036d6996
commit 185c641f60

View File

@@ -85,7 +85,7 @@ RegisterServerEvent("jim-payments:server:PayPopup", function(data)
local biller = QBCore.Functions.GetPlayer(tonumber(data.biller)) local biller = QBCore.Functions.GetPlayer(tonumber(data.biller))
if data.accept == true then if data.accept == true then
billed.Functions.RemoveMoney(tostring(data.billtype), data.amount) TriggerEvent("qb-bossmenu:server:addAccountMoney", tostring(biller.PlayerData.job.name), data.amount) billed.Functions.RemoveMoney(tostring(data.billtype), data.amount) TriggerEvent("qb-bossmenu:server:addAccountMoney", tostring(biller.PlayerData.job.name), data.amount)
TriggerEvent('jim-payments:Tickets:Give', data.amount, tostring(billed.PlayerData.job.name)) TriggerEvent('jim-payments:Tickets:Give', data.amount, tostring(biller.PlayerData.job.name))
elseif data.accept == false then elseif data.accept == false then
TriggerClientEvent("QBCore:Notify", src, "You declined the payment") TriggerClientEvent("QBCore:Notify", src, "You declined the payment")
TriggerClientEvent("QBCore:Notify", data.biller, billed.PlayerData.charinfo.firstname.." declined the payment", "error") TriggerClientEvent("QBCore:Notify", data.biller, billed.PlayerData.charinfo.firstname.." declined the payment", "error")