https://projecterror.dev/docs/pefcl/installation
https://projecterror.dev/docs/pefcl/configuration
https://projecterror.dev/docs/pefcl/developers/introduction
Need further support? Join our Discord!
pefcl (PE-Financial) is a financial banking resource for FiveM written in TypeScript and React.
License: Other
When creating a new personal/shared account, the phone app does not reflect this app on the ACCOUNTS & TRANSFER page. It also does not update when your personal account goes down
The phone app is increadible! just needs to be synced on accounts page! I am sure this is on the list already.
To Reproduce
Steps to reproduce the behavior:
Absolutely insane quality on the script!
After reflying this seems to sync, however it is not always synced. seems to be more of an issue on the actual creation of the accounts not syncing. once you do a transfer between them or refly on your first account, they are all synced again. However on creation of actual account this does not update in the phone.
Additionally you are required to modify a shared account to see if someone else has deposited funds into them. Then it will sync.
Is your feature request related to a problem? Please describe.
Freeze all accounts of a player.
Describe the solution you'd like
Allow a specific job, and rank to freeze a players accounts, so the court system can freeze accounts, if a person tryes to dodge the court cases, and got dept to the society.
Hello,
When I want to create an invoice, regardless of the type of "amount" and its amount, the "Invalid amount" error on the customer side is then visible in the F8.
SERVER : createInvoice
CLIENT : createInvoiceForNearestPlayer
@GiroudMathias do you have a solution?
Thanks :)
Describe the issue
After switching character in ESX Legacy the bank UI does not update to show the new users details. You can still manage the old character's accounts.
Expected behavior
The UI should show the new character's details.
To Reproduce
Steps to reproduce the behavior:
Switch character and open the UI at a bank.
Needed information (please complete the following information):
Additional context
I have loaded/unloaded the character correctly with the ESX-bridge but it still does not work. The pefcl-app in npwd does however update correctly. Maybe something wrong with unload export?
Describe the issue
When you go to a bank or ATM and you interact with it with qtarget, NUI doesn't show, only the cursor.
(Fresh install with pefcl)
Expected behavior
NUI oppening and letting interact with the script
To Reproduce
Steps to reproduce the behavior:
Needed information (please complete the following information):
Describe the issue
account wont be removed if you switch / leave the job in qb-core
A clear and concise description of what the bug is.
when i join a job Eg: Police it does give a an account on my phone and my bank for the police but when i leave and join EMS i still have the police account on my bank but with that i do get the EMS account, when i leave both of the job i still have them on me
Expected behavior
the account should be removed when you are not on the spefic job Like
if you are in police job you should have police managment account
and when you are on EMS, you should only get the EMS bank account, only if you are higher ups on both or any jobs or gangs like level 4 or any thing other
To Reproduce
Steps to reproduce the behavior:
If applicable, add a screenshot or a video to help explain your problem.
Needed information (please complete the following information):
ESX Integration is not fully supported. Our salary system is run through es_extended and modifications must be made to get this to work. I will post a not working snippet for an example. There are other aspects of ESX that are not compatible with Pefcl also.
Describe the solution you'd like
More clear snippets & documentation on integration with ESX or full ESX integration. QB seems to get all the support with Pefcl.
Non-working Example Salary Snippet:
function self.addAccountMoney(accountName, money, reason)
if not tonumber(money) then
print(('[^1ERROR^7] Tried To Set Account ^5%s^0 For Player ^5%s^0 To An Invalid Number!'):format(accountName, self.playerId))
return
end
if money > 0 then
local account, index = self.getAccount(accountName)
if account then
if accountName == 'bank' then
exports.pefcl:addBankBalance(self.playerId, {
amount = ESX.Math.Round(money),
message = reason and tostring(reason) or 'Untilted'
})
return
end
money = account.round and ESX.Math.Round(money) or money
self.accounts[index].money += money
self.triggerEvent('esx:setAccountMoney', account)
else
print(('[^1ERROR^7] Tried To Set Add To Invalid Account ^5%s^0 For Player ^5%s^0!'):format(accountName, self.playerId))
end
else
print(('[^1ERROR^7] Tried To Set Account ^5%s^0 For Player ^5%s^0 To An Invalid Number!'):format(accountName, self.playerId))
end
end
function self.removeAccountMoney(accountName, money, reason)
if not tonumber(money) then
print(('[^1ERROR^7] Tried To Set Account ^5%s^0 For Player ^5%s^0 To An Invalid Number!'):format(accountName, self.playerId))
return
end
if money > 0 then
local account, index = self.getAccount(accountName)
if account then
if accountName == 'bank' then
exports.pefcl:removeBankBalance(self.playerId, {
amount = ESX.Math.Round(money),
message = reason and tostring(reason) or 'Untilted'
})
return
end
money = account.round and ESX.Math.Round(money) or money
self.accounts[index].money -= money
self.triggerEvent('esx:setAccountMoney', account)
else
print(('[^1ERROR^7] Tried To Set Add To Invalid Account ^5%s^0 For Player ^5%s^0!'):format(accountName, self.playerId))
end
else
print(('[^1ERROR^7] Tried To Set Account ^5%s^0 For Player ^5%s^0 To An Invalid Number!'):format(accountName, self.playerId))
end
end
Describe the issue
Looks like owner
role is not enough to withdraw money from account, to add people to accounts, this is sad
it also require to be the creator of the account.
Expected behavior
When you are owner but not creator of an account, you are not able to add more people, and you are not able to withdraw money.
To Reproduce
Steps to reproduce the behavior:
ownerIdentifier
to anything (I tried with a job name as string)addUserToUniqueAccount
exportAdditional context
We should be able to withdraw and manage people when having owner
role.
'contributor' should only let people see the account amount, see peoples who have access, and deposit money (imo)
Is your feature request related to a problem? Please describe.
I think the documentation needs some more clarity on how to manipulate company accounts, ex. how to withdraw money from a company account, this might be needed in scripts, ex. car dealer where you got a restocking fee you have to pay.
Describe the solution you'd like
Either integrate a way to achive this or document the feature if it's there.
Tryed to figure this one out.
Let's say the police hands over a ticket for speeding, how to a ensure the money goes in to the police account, and not the players account?
And in general for other accounts how would this work, and be done ?
You still have access to account when leaving job for esx_society / business accounts. Fix please
Describe the issue
Hey, i turn up my server after i installed this new update, and this happened. ↓↓
Sorry, that i didn't make full template i'm lazy.
Needed information (please complete the following information):
Describe the issue
Getting a timeout when trying to transfer to an external account, been debugging and it gets to getAccountFromExternalAccount
but isn't able to retrieve the account. Can't figure out why it can't find any accounts from the extenal_accounts
table. I've checked the database and the account is listed in there so drawing blanks :/
Expected behavior
Should successfully retrieve the account from the external_accounts
table and be able to link that up with the account in question and successfully transfer the specified amount.
To Reproduce
Steps to reproduce the behavior:
Needed information (please complete the following information):
Additional context
While testing this, it has become apparent that when it runs through the process and eventually times out, nobody on the server is able to make any interaction with PEFCL while it tries to process the event and result in a timeout. This causes problems especially on larger servers where many players are trying to complete actions at the same time and facing longer load times and unresponsiveness due to one players action that results in a timeout.
Not sure if this is doable but admins can rename the account and remove people however it will just re-add the person next time they load unless they are removed from the job.
when deposit money into a bank to have a small fee
Create a separate/ Second Account is not shown up after close and reopen until you Relog into Game
I create a second Account as shared type, then it will show up.
If i switch to a submenu and click on accounts, or close an open Account-Menu the second Account is not shown.
Its registered in Database Correctly.
After Relogging into Game, the Account is shown...
Expected
If you create second oder Multi Accounts, they should shown correctly without Relog of course.
To Reproduce
Steps to reproduce the behavior:
Needed information (please complete the following information):
Additional context
The discord button doesn't send to the discord 😢
Hey,
Noticed the project seems like it's on standby, is it still alive and kicking, or is it put on hold or whats going on?
Is your feature request related to a problem? Please describe.
Webpack is slow af compared to Vite and its bundle size is so huge whereas Vite bundles and compresses it by default. On top of that, it's even slower if you use top-level imports especially for mui
Describe the solution you'd like
Convert Webpack to Vite for faster build time, and convert all component imports from mui/material/** to path imports
Describe alternatives you've considered
NA
Hey can you add the fact of being able to consult the incoming transaction / invoice (with reason etc) of a job account
Hey, I have written a banking app for my phone through which you should make transactions in your banking script. I have managed that the transactions arrive in the accounts. The only problem I'm encountering is that the account balance is not updated in the UI, Even though it has changed in the database. I understand that it's because your script only updates when actions happen through the UI and doesn't randomly request values from the database every time it opens.
Is there any way to update the invidual accounts via a trigger or is there an export with which you can directly use the functions from Pefcl for a transfer?
pefcl doesnt sync with esx_scoiety
so the job account balance on the phone app and in the banks is different to the jobs actual funds
id like for it to sync with each other
If applicable, add a screenshot or a video to help explain your problem.
Needed information (please complete the following information):
V: 1.0.10
Framework: none (standalone)
Issue: All exports seems to work fine, but included RemoveCash export in my code for players to buy stuff didn't work.
So, I created a simple command in the server file of the script to test an export:
RegisterCommand("remcash", function(source, args, rawCommand)
local player = source
local amount = tonumber(args[1])
if amount ~= nil then
print("Taking from player: "..player.." | Amount: "..amount)
exports.pefcl:removeCash(player, amount)
end
end)
Arguments:
/remcash 1000
Console after running the command: (silly debug option)
[script:test-script] Taking from player: 1 | Amount: 1000
[script:pefcl] [PEFCL] [cash] [debug]: Taking undefined from undefined
It would be nice to have a configurable transaction fee.
When the balance is updated for a specific account, emit an event with the update balance and broadcast this to related player.
Preferable this should be done on the DB level
I think one of the functionalities pefcl really is missing is data logging to a remote service such as https://www.datadoghq.com/ or https://grafana.com/oss/loki/. Of course people would really want discord logging but my opinion is that discord isn't a place to have any logs. Previously mentioned services both are supported by good other resources which would allow us using the resource to combine data logging with inventories or other resources. There are LUA libraries available to trigger data logging to these services as well. Of course it can be also some other platform which allows cost effective way to visualize your money flow on your server.
Make it so you can't delete unique accounts or when you create a unique account you can choose if it can be deleted or not
Not sure if its feasible or not
Unable to get players when framework integration enabled
When you enable framework integration Userservice.getUser doesn't get user sources anymore. This will happen on playerjoin or when you restart the resource. usersBySource doesn't contain players sources. This will prevent of course further server side exports triggering.
With usersBySource im referring to src\server\services\user\user.service.ts function getUser where it's looking for the players from usersBySource.
Problem seems to be existing on other servers this problem was reported also by other discord community member.
What I understand the structure the initial design is not to push sources from some framework?
Describe the issue
After blocking created cards its not possible to delete them in the bank UI.
Expected behavior
Disabling card -> Deleting it
To Reproduce
Steps to reproduce the behavior:
Is your feature request related to a problem? Please describe.
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
Describe the solution you'd like
A clear and concise description of what you want to happen.
Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.
Additional context
Add any other context or screenshots about the feature request here.
Describe the issue
Can move when UI is displayed (with controller)
Can withdraw or deposit while moving far away the bank or the ATM.
Expected behavior
Restrict withdraw and deposit to bank zone
To Reproduce
Steps to reproduce the behavior:
Describe the issue
Theres a huge issue with shared accounts. If a player uses a shared account and a contributor opens the bank UI it shows the wrong data.
Expected behavior
If someone uses a shared account it should sync properly with every contributor.
To Reproduce
Steps to reproduce the behavior:
When you want to withdraw cash from the panel it shows the current player cash. But for withdrawing it would be better to have the total balance displaying
Would be nice to have default accounts that do not have a specified owner. This can be used for stuff like PD, EMS, DOJ and businesses with changing owners IE mechanic shops.
Add Card System for ATM use
Would be nice to either have a copy button or be able to highlight/select the bank identifier on the card as right now you have to type it out if you want to send it to someone
UI doesnt reload when switching characters in ESX Legacy, can still manage prev character
Expected behavior
Should update to display new char's details
To Reproduce
Steps to reproduce the behavior:
Switch char in ESX Legacy
Needed information (please complete the following information):
Additional context
Correct in DB but not ingame
[ script:pefcl-esx] SCRIPT ERROR: @pefcl-esx/server.lua:73: attempt to index a nil value (global 'ESX')
[ script:pefcl-esx] > ref (@pefcl-esx/server.lua:73)
[ script:pefcl-esx] > AccountService.createInitialAccount (@pefcl/src/dist/server.js:108150)
[ script:pefcl-esx] > processTicksAndRejections (node:internal/process/task_queues:96)
[ script:pefcl] SCRIPT ERROR in promise (unhandled rejection): Error: An error occurred while calling export getBank of resource pefcl-esx - see above for details
[ script:pefcl] > AccountService.createInitialAccount (@pefcl/src/dist/server.js:108150)
[ script:pefcl] > processTicksAndRejections (node:internal/process/task_queues:96)
[ script:pefcl]
[ script:pefcl] [PEFCL] [events] [silly]: netPromise > pefcl:getAccounts > RequestObj
[ script:pefcl] [PEFCL] [events] [silly]: { source: 1, data: null }
[ script:pefcl] [PEFCL] [accounts] [debug]: Retrieving accounts
[ script:pefcl] [PEFCL] [events] [silly]: Response Promise Event pefcl:getAccounts:712a8017-b3fd-4df7-998e-c0e438d20394 (15.8302ms), Data >>
[ script:pefcl] [PEFCL] [events] [silly]: { status: 'ok', data: [] }
Hello in the Polish translation there are more characters than in English and in the app on the phone unfortunately the inscription home is broken
And I don’t have a translation of when the transactions were made on the bank account.
I’m the person who did the translation, and I changed a few things that I just couldn’t see, but I didn’t notice how I did the translation.
Describe the issue
The key DATE_FORMAT
in fr
language return DATE_FORMAT
instead of DD/MM/YYYY
that cause weird translation
Expected behavior
return DD/MM/YYYY
instead of DATE_FORMAT
To Reproduce
Steps to reproduce the behavior:
fr
at general.language
in config.json
Media
Needed information (please complete the following information):
A bug with fetching? recepient list in NPWD
Running on ESX, NPWD latest version, pefcl release.
When I try to create recepient in NPWD, it will create in DB (bank shows it) but the app will not display any account other than my personal one.
To Reproduce
Description
A bug, that allows you to withdraw money "for free"
Cause
When player loses connection to internet with ATM ui open, he will be able to spam withdrawal multiple times before it goes black (non-clickable). Disabling the option is good solution, but it is not quick enough / reliable to prevent players from clicking it atleast once, thus getting free money.
Temp solution
Make max money withdrawal to low money, so they can dupe max 5K or so.
Desired outcome
Do not let them dupe money, lol.
add the debug types to documentation, and what reports. thx
Describe the issue
Using the exports.pefcl:setBankBalance
export, I can see that the account balance is updated in the pefcl_accounts database table however when opening the bank UI the old balance is still displayed. I have confirmed that exports.pefcl:addBankBalance
and exports.pefcl:removeBankBalance
works correctly so it is just the "set" which isn't working.
This only seems to affect the main bank UI as I can see the balance is updated when checking the NPWD PEFCL app.
Expected behavior
Using the set export, it should update the account balance and correctly display that when opening the bank UI. So far it updates the balance but doesn't reflect the change on the UI.
To Reproduce
Steps to reproduce the behavior:
exports.pefcl:setBankBalance
to update the players account (in my case this is being used in qb-pefcl QBCore:Server:OnMoneyChange
event)pefcl_accounts
database table to make sure the balance was set to the value providedMedia
Needed information (please complete the following information):
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.