Closed chadtomkiss closed 6 years ago
In all of my current use cases I'm always showing the list of all transactions. It's important for the clients & the admins to see the failed transactions as well otherwise it could confuse them.
That's cool.
I added a method to calculate a running balance next to each transaction, which is wrong due to including failed transactions but I will add a where clause to the transactions I am getting :+1:
Should
$user->transactions()
default to only include transactions that areaccepted
?Similar to how Eloquent filters out soft deleted models, but you can use the
withTrashed()
to include ones that are deleted.Maybe
$user->transactions()->withRejected()->get()
if you wanted every transaction or something?