Auto commit for release 'develop' on 2024-12-30

This commit is contained in:
github-actions
2024-12-30 04:12:18 +01:00
parent 9f25880a59
commit 0579c8565d
40 changed files with 301 additions and 303 deletions

View File

@@ -99,7 +99,7 @@ class PreferencesEventHandler
{
$repository = app(BudgetRepositoryInterface::class);
$repository->setUserGroup($userGroup);
$set = $repository->getBudgets();
$set = $repository->getBudgets();
/** @var Budget $budget */
foreach ($set as $budget) {
@@ -127,13 +127,15 @@ class PreferencesEventHandler
{
// custom query because of the potential size of this update.
$success = DB::table('transactions')
->join('transaction_journals', 'transaction_journals.id', '=', 'transactions.transaction_journal_id')
->where('transaction_journals.user_group_id', $userGroup->id)
->where(static function (Builder $q): void {
$q->whereNotNull('native_amount')
->orWhereNotNull('native_foreign_amount');
})
->update(['native_amount' => null, 'native_foreign_amount' => null]);
->join('transaction_journals', 'transaction_journals.id', '=', 'transactions.transaction_journal_id')
->where('transaction_journals.user_group_id', $userGroup->id)
->where(static function (Builder $q): void {
$q->whereNotNull('native_amount')
->orWhereNotNull('native_foreign_amount')
;
})
->update(['native_amount' => null, 'native_foreign_amount' => null])
;
Log::debug(sprintf('Reset %d transactions.', $success));
}
}

View File

@@ -39,7 +39,7 @@ class AvailableBudgetObserver
public function updated(AvailableBudget $availableBudget): void
{
//Log::debug('Observe "updated" of an available budget.');
// Log::debug('Observe "updated" of an available budget.');
$this->updateNativeAmount($availableBudget);
}