mirror of
https://github.com/jimathy/jim-payments.git
synced 2026-08-16 22:06:02 +01:00
(Beta) Fixes for multiframework features
This commit is contained in:
@@ -37,7 +37,7 @@ end
|
|||||||
RegisterNetEvent(getScript()..":Client:ATM", function() local setheader = nil
|
RegisterNetEvent(getScript()..":Client:ATM", function() local setheader = nil
|
||||||
--this grabs all the info from names to savings account numbers in the databases
|
--this grabs all the info from names to savings account numbers in the databases
|
||||||
local info = triggerCallback(getScript()..":GetInfo")
|
local info = triggerCallback(getScript()..":GetInfo")
|
||||||
|
jsonPrint(info)
|
||||||
playAnim("amb@prop_human_atm@male@enter", "enter", 2000, 1)
|
playAnim("amb@prop_human_atm@male@enter", "enter", 2000, 1)
|
||||||
|
|
||||||
if progressBar({ label = locale("menu", "acc_atm"), time = 3000 }) then
|
if progressBar({ label = locale("menu", "acc_atm"), time = 3000 }) then
|
||||||
|
|||||||
@@ -8,9 +8,9 @@ Config = {
|
|||||||
Debug = false,
|
Debug = false,
|
||||||
EventDebug = false,
|
EventDebug = false,
|
||||||
|
|
||||||
Menu = "qb", -- "qb", "ox", "gta"
|
Menu = "ox", -- "qb", "ox", "gta"
|
||||||
Notify = "qb", -- "qb", "ox", "gta", "esx"
|
Notify = "gta", -- "qb", "ox", "gta", "esx"
|
||||||
ProgressBar = "qb", -- "qb", "ox", "gta", "esx"
|
ProgressBar = "gta", -- "qb", "ox", "gta", "esx"
|
||||||
},
|
},
|
||||||
|
|
||||||
Crafting = {
|
Crafting = {
|
||||||
|
|||||||
@@ -298,7 +298,7 @@ createCallback(getScript()..":GetInfo", function(source)
|
|||||||
end
|
end
|
||||||
|
|
||||||
-- Savings account is only QBCore for now
|
-- Savings account is only QBCore for now
|
||||||
if isStarted(QBExport) then
|
if isStarted(QBExport) and not isStarted(QBXExport) then
|
||||||
-- Grab Savings account info
|
-- Grab Savings account info
|
||||||
local result = MySQL.Sync.fetchAll('SELECT * FROM bank_accounts WHERE citizenid = ? AND account_name = ?', { Player.citizenId, 'Savings_'..Player.citizenId, })
|
local result = MySQL.Sync.fetchAll('SELECT * FROM bank_accounts WHERE citizenid = ? AND account_name = ?', { Player.citizenId, 'Savings_'..Player.citizenId, })
|
||||||
if result[1] then
|
if result[1] then
|
||||||
|
|||||||
@@ -52,6 +52,10 @@ RegisterServerEvent(getScript()..":Tickets:Give", function(data, biller, gang)
|
|||||||
|
|
||||||
-- If ticket system enabled, do this
|
-- If ticket system enabled, do this
|
||||||
if (biller.onDuty or gang) and Config.Receipts.TicketSystem then
|
if (biller.onDuty or gang) and Config.Receipts.TicketSystem then
|
||||||
|
if not Config.Receipts.Jobs[data.society] then
|
||||||
|
print("^1Error^7: Failed to find job "..data.society.." in ^2Config.Receipts.Jobs^7")
|
||||||
|
return
|
||||||
|
end
|
||||||
if data.amount >= Config.Receipts.Jobs[data.society].MinAmountforTicket then
|
if data.amount >= Config.Receipts.Jobs[data.society].MinAmountforTicket then
|
||||||
if Config.Receipts.TicketSystemAll then
|
if Config.Receipts.TicketSystemAll then
|
||||||
for _, v in pairs(activePlayers) do
|
for _, v in pairs(activePlayers) do
|
||||||
@@ -63,7 +67,6 @@ RegisterServerEvent(getScript()..":Tickets:Give", function(data, biller, gang)
|
|||||||
triggerNotify(nil, locale("success", "rec_rec"), 'success', Player.source)
|
triggerNotify(nil, locale("success", "rec_rec"), 'success', Player.source)
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
print("player found")
|
|
||||||
if Player.job == data.society and Player.onDuty then
|
if Player.job == data.society and Player.onDuty then
|
||||||
print("player on duty, giving tickets")
|
print("player on duty, giving tickets")
|
||||||
addItem("payticket", 1, nil, Player.source)
|
addItem("payticket", 1, nil, Player.source)
|
||||||
|
|||||||
Reference in New Issue
Block a user