Auto commit for release 'branch-v6.2' on 2024-12-21

This commit is contained in:
github-actions
2024-12-21 12:27:07 +01:00
parent 4fbf7b38fb
commit 4aaea89f2c
25 changed files with 302 additions and 276 deletions

View File

@@ -55,11 +55,11 @@ class BillObserver
private function updateNativeAmount(Bill $bill): void
{
$userCurrency = app('amount')->getDefaultCurrencyByUserGroup($bill->user->userGroup);
$userCurrency = app('amount')->getDefaultCurrencyByUserGroup($bill->user->userGroup);
$bill->native_amount_min = null;
$bill->native_amount_max = null;
if ($bill->transactionCurrency->id !== $userCurrency->id) {
$converter = new ExchangeRateConverter();
$converter = new ExchangeRateConverter();
$converter->setIgnoreSettings(true);
$bill->native_amount_min = $converter->convert($bill->transactionCurrency, $userCurrency, today(), $bill->amount_min);
$bill->native_amount_max = $converter->convert($bill->transactionCurrency, $userCurrency, today(), $bill->amount_max);