mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-10-12 15:35:15 +00:00
Fix methods
This commit is contained in:
@@ -370,7 +370,17 @@ class PiggyBankRepository implements PiggyBankRepositoryInterface
|
||||
#[\Override]
|
||||
public function purgeAll(): void
|
||||
{
|
||||
throw new FireflyException('TODO Not implemented');
|
||||
PiggyBank::withTrashed()
|
||||
->whereNotNull('piggy_banks.deleted_at')
|
||||
->leftJoin('account_piggy_bank', 'account_piggy_bank.piggy_bank_id', '=', 'piggy_banks.id')
|
||||
->leftJoin('accounts', 'accounts.id', '=', 'account_piggy_bank.account_id')
|
||||
->where('accounts.user_id', auth()->user()->id)
|
||||
->with(
|
||||
[
|
||||
'objectGroups',
|
||||
]
|
||||
)
|
||||
->delete();
|
||||
}
|
||||
|
||||
#[\Override]
|
||||
|
Reference in New Issue
Block a user