mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-09-04 03:43:07 +00:00
Clean up code.
This commit is contained in:
@@ -92,8 +92,8 @@ class AccountController extends Controller
|
||||
// user's preferences
|
||||
$defaultSet = $this->repository->getAccountsByType([AccountType::ASSET])->pluck('id')->toArray();
|
||||
/** @var Preference $frontPage */
|
||||
$frontPage = app('preferences')->get('frontPageAccounts', $defaultSet);
|
||||
$default = app('amount')->getDefaultCurrency();
|
||||
$frontPage = app('preferences')->get('frontPageAccounts', $defaultSet);
|
||||
$default = app('amount')->getDefaultCurrency();
|
||||
|
||||
if (!(is_array($frontPage->data) && count($frontPage->data) > 0)) {
|
||||
$frontPage->data = $defaultSet;
|
||||
|
@@ -229,7 +229,7 @@ class ExportController extends Controller
|
||||
* @throws ContainerExceptionInterface
|
||||
* @throws FireflyException
|
||||
* @throws NotFoundExceptionInterface
|
||||
* @SuppressWarnings(PHPMD.UnusedFormalParameter)
|
||||
* @SuppressWarnings(PHPMD.UnusedFormalParameter)
|
||||
*/
|
||||
public function tags(ExportRequest $request): LaravelResponse
|
||||
{
|
||||
|
@@ -92,7 +92,7 @@ class BillController extends Controller
|
||||
$foreignKey = sprintf('%d-%d', $billId, $foreignCurrencyId);
|
||||
|
||||
if (0 !== $currencyId) {
|
||||
$response[$key] = $response[$key] ?? [
|
||||
$response[$key] ??= [
|
||||
'id' => (string)$billId,
|
||||
'name' => $journal['bill_name'],
|
||||
'difference' => '0',
|
||||
@@ -104,7 +104,7 @@ class BillController extends Controller
|
||||
$response[$key]['difference_float'] = (float)$response[$key]['difference']; // intentional float
|
||||
}
|
||||
if (0 !== $foreignCurrencyId) {
|
||||
$response[$foreignKey] = $response[$foreignKey] ?? [
|
||||
$response[$foreignKey] ??= [
|
||||
'difference' => '0',
|
||||
'difference_float' => 0,
|
||||
'currency_id' => (string)$foreignCurrencyId,
|
||||
@@ -147,7 +147,7 @@ class BillController extends Controller
|
||||
$foreignCurrencyId = (int)$journal['foreign_currency_id'];
|
||||
|
||||
if (0 !== $currencyId) {
|
||||
$response[$currencyId] = $response[$currencyId] ?? [
|
||||
$response[$currencyId] ??= [
|
||||
'difference' => '0',
|
||||
'difference_float' => 0,
|
||||
'currency_id' => (string)$currencyId,
|
||||
@@ -157,7 +157,7 @@ class BillController extends Controller
|
||||
$response[$currencyId]['difference_float'] = (float)$response[$currencyId]['difference']; // intentional float
|
||||
}
|
||||
if (0 !== $foreignCurrencyId) {
|
||||
$response[$foreignCurrencyId] = $response[$foreignCurrencyId] ?? [
|
||||
$response[$foreignCurrencyId] ??= [
|
||||
'difference' => '0',
|
||||
'difference_float' => 0,
|
||||
'currency_id' => (string)$foreignCurrencyId,
|
||||
|
@@ -58,7 +58,7 @@ class PeriodController extends Controller
|
||||
$foreignCurrencyId = (int)$journal['foreign_currency_id'];
|
||||
|
||||
if (0 !== $currencyId) {
|
||||
$response[$currencyId] = $response[$currencyId] ?? [
|
||||
$response[$currencyId] ??= [
|
||||
'difference' => '0',
|
||||
'difference_float' => 0,
|
||||
'currency_id' => (string)$currencyId,
|
||||
@@ -68,7 +68,7 @@ class PeriodController extends Controller
|
||||
$response[$currencyId]['difference_float'] = (float)$response[$currencyId]['difference']; // intentional float
|
||||
}
|
||||
if (0 !== $foreignCurrencyId) {
|
||||
$response[$foreignCurrencyId] = $response[$foreignCurrencyId] ?? [
|
||||
$response[$foreignCurrencyId] ??= [
|
||||
'difference' => '0',
|
||||
'difference_float' => 0,
|
||||
'currency_id' => (string)$foreignCurrencyId,
|
||||
|
@@ -83,7 +83,7 @@ class TagController extends Controller
|
||||
$foreignCurrencyId = (int)$journal['foreign_currency_id'];
|
||||
|
||||
if (0 !== $currencyId) {
|
||||
$response[$currencyId] = $response[$currencyId] ?? [
|
||||
$response[$currencyId] ??= [
|
||||
'difference' => '0',
|
||||
'difference_float' => 0,
|
||||
'currency_id' => (string)$currencyId,
|
||||
@@ -93,7 +93,7 @@ class TagController extends Controller
|
||||
$response[$currencyId]['difference_float'] = (float)$response[$currencyId]['difference']; // float but on purpose.
|
||||
}
|
||||
if (0 !== $foreignCurrencyId) {
|
||||
$response[$foreignCurrencyId] = $response[$foreignCurrencyId] ?? [
|
||||
$response[$foreignCurrencyId] ??= [
|
||||
'difference' => '0',
|
||||
'difference_float' => 0,
|
||||
'currency_id' => (string)$foreignCurrencyId,
|
||||
@@ -148,7 +148,7 @@ class TagController extends Controller
|
||||
|
||||
// on currency ID
|
||||
if (0 !== $currencyId) {
|
||||
$response[$key] = $response[$key] ?? [
|
||||
$response[$key] ??= [
|
||||
'id' => (string)$tagId,
|
||||
'name' => $tag['name'],
|
||||
'difference' => '0',
|
||||
|
@@ -58,7 +58,7 @@ class PeriodController extends Controller
|
||||
$foreignCurrencyId = (int)$journal['foreign_currency_id'];
|
||||
|
||||
if (0 !== $currencyId) {
|
||||
$response[$currencyId] = $response[$currencyId] ?? [
|
||||
$response[$currencyId] ??= [
|
||||
'difference' => '0',
|
||||
'difference_float' => 0,
|
||||
'currency_id' => (string)$currencyId,
|
||||
@@ -68,7 +68,7 @@ class PeriodController extends Controller
|
||||
$response[$currencyId]['difference_float'] = (float)$response[$currencyId]['difference']; // float but on purpose.
|
||||
}
|
||||
if (0 !== $foreignCurrencyId) {
|
||||
$response[$foreignCurrencyId] = $response[$foreignCurrencyId] ?? [
|
||||
$response[$foreignCurrencyId] ??= [
|
||||
'difference' => '0',
|
||||
'difference_float' => 0,
|
||||
'currency_id' => (string)$foreignCurrencyId,
|
||||
|
@@ -84,7 +84,7 @@ class TagController extends Controller
|
||||
$foreignCurrencyId = (int)$journal['foreign_currency_id'];
|
||||
|
||||
if (0 !== $currencyId) {
|
||||
$response[$currencyId] = $response[$currencyId] ?? [
|
||||
$response[$currencyId] ??= [
|
||||
'difference' => '0',
|
||||
'difference_float' => 0,
|
||||
'currency_id' => (string)$currencyId,
|
||||
@@ -94,7 +94,7 @@ class TagController extends Controller
|
||||
$response[$currencyId]['difference_float'] = (float)$response[$currencyId]['difference'];
|
||||
}
|
||||
if (0 !== $foreignCurrencyId) {
|
||||
$response[$foreignCurrencyId] = $response[$foreignCurrencyId] ?? [
|
||||
$response[$foreignCurrencyId] ??= [
|
||||
'difference' => '0',
|
||||
'difference_float' => 0,
|
||||
'currency_id' => (string)$foreignCurrencyId,
|
||||
@@ -152,7 +152,7 @@ class TagController extends Controller
|
||||
|
||||
// on currency ID
|
||||
if (0 !== $currencyId) {
|
||||
$response[$key] = $response[$key] ?? [
|
||||
$response[$key] ??= [
|
||||
'id' => (string)$tagId,
|
||||
'name' => $tag['name'],
|
||||
'difference' => '0',
|
||||
|
@@ -58,7 +58,7 @@ class PeriodController extends Controller
|
||||
$foreignCurrencyId = (int)$journal['foreign_currency_id'];
|
||||
|
||||
if (0 !== $currencyId) {
|
||||
$response[$currencyId] = $response[$currencyId] ?? [
|
||||
$response[$currencyId] ??= [
|
||||
'difference' => '0',
|
||||
'difference_float' => 0,
|
||||
'currency_id' => (string)$currencyId,
|
||||
@@ -68,7 +68,7 @@ class PeriodController extends Controller
|
||||
$response[$currencyId]['difference_float'] = (float)$response[$currencyId]['difference'];
|
||||
}
|
||||
if (0 !== $foreignCurrencyId) {
|
||||
$response[$foreignCurrencyId] = $response[$foreignCurrencyId] ?? [
|
||||
$response[$foreignCurrencyId] ??= [
|
||||
'difference' => '0',
|
||||
'difference_float' => 0,
|
||||
'currency_id' => (string)$foreignCurrencyId,
|
||||
|
@@ -81,7 +81,7 @@ class TagController extends Controller
|
||||
$foreignCurrencyId = (int)$journal['foreign_currency_id'];
|
||||
|
||||
if (0 !== $currencyId) {
|
||||
$response[$currencyId] = $response[$currencyId] ?? [
|
||||
$response[$currencyId] ??= [
|
||||
'difference' => '0',
|
||||
'difference_float' => 0,
|
||||
'currency_id' => (string)$currencyId,
|
||||
@@ -91,7 +91,7 @@ class TagController extends Controller
|
||||
$response[$currencyId]['difference_float'] = (float)$response[$currencyId]['difference'];
|
||||
}
|
||||
if (0 !== $foreignCurrencyId) {
|
||||
$response[$foreignCurrencyId] = $response[$foreignCurrencyId] ?? [
|
||||
$response[$foreignCurrencyId] ??= [
|
||||
'difference' => '0',
|
||||
'difference_float' => 0,
|
||||
'currency_id' => (string)$foreignCurrencyId,
|
||||
@@ -149,7 +149,7 @@ class TagController extends Controller
|
||||
|
||||
// on currency ID
|
||||
if (0 !== $currencyId) {
|
||||
$response[$key] = $response[$key] ?? [
|
||||
$response[$key] ??= [
|
||||
'id' => (string)$tagId,
|
||||
'name' => $tag['name'],
|
||||
'difference' => '0',
|
||||
|
@@ -33,7 +33,6 @@ use FireflyIII\Repositories\Budget\BudgetRepositoryInterface;
|
||||
use FireflyIII\Transformers\BudgetLimitTransformer;
|
||||
use FireflyIII\User;
|
||||
use Illuminate\Http\JsonResponse;
|
||||
use Illuminate\Http\Request;
|
||||
use Illuminate\Pagination\LengthAwarePaginator;
|
||||
use League\Fractal\Pagination\IlluminatePaginatorAdapter;
|
||||
use League\Fractal\Resource\Collection as FractalCollection;
|
||||
|
@@ -24,13 +24,11 @@ declare(strict_types=1);
|
||||
namespace FireflyIII\Api\V1\Controllers\Models\ObjectGroup;
|
||||
|
||||
use FireflyIII\Api\V1\Controllers\Controller;
|
||||
use FireflyIII\Exceptions\FireflyException;
|
||||
use FireflyIII\Models\ObjectGroup;
|
||||
use FireflyIII\Repositories\ObjectGroup\ObjectGroupRepositoryInterface;
|
||||
use FireflyIII\Transformers\ObjectGroupTransformer;
|
||||
use FireflyIII\User;
|
||||
use Illuminate\Http\JsonResponse;
|
||||
use Illuminate\Http\Request;
|
||||
use Illuminate\Pagination\LengthAwarePaginator;
|
||||
use League\Fractal\Pagination\IlluminatePaginatorAdapter;
|
||||
use League\Fractal\Resource\Collection as FractalCollection;
|
||||
|
@@ -148,12 +148,12 @@ class BasicController extends Controller
|
||||
/** @var array $transactionJournal */
|
||||
foreach ($set as $transactionJournal) {
|
||||
$currencyId = (int)$transactionJournal['currency_id'];
|
||||
$incomes[$currencyId] = $incomes[$currencyId] ?? '0';
|
||||
$incomes[$currencyId] ??= '0';
|
||||
$incomes[$currencyId] = bcadd(
|
||||
$incomes[$currencyId],
|
||||
bcmul($transactionJournal['amount'], '-1')
|
||||
);
|
||||
$sums[$currencyId] = $sums[$currencyId] ?? '0';
|
||||
$sums[$currencyId] ??= '0';
|
||||
$sums[$currencyId] = bcadd($sums[$currencyId], bcmul($transactionJournal['amount'], '-1'));
|
||||
}
|
||||
|
||||
@@ -171,9 +171,9 @@ class BasicController extends Controller
|
||||
/** @var array $transactionJournal */
|
||||
foreach ($set as $transactionJournal) {
|
||||
$currencyId = (int)$transactionJournal['currency_id'];
|
||||
$expenses[$currencyId] = $expenses[$currencyId] ?? '0';
|
||||
$expenses[$currencyId] ??= '0';
|
||||
$expenses[$currencyId] = bcadd($expenses[$currencyId], $transactionJournal['amount']);
|
||||
$sums[$currencyId] = $sums[$currencyId] ?? '0';
|
||||
$sums[$currencyId] ??= '0';
|
||||
$sums[$currencyId] = bcadd($sums[$currencyId], $transactionJournal['amount']);
|
||||
}
|
||||
|
||||
|
@@ -102,7 +102,7 @@ class AccountController extends Controller
|
||||
$nameWithBalance = sprintf('%s (%s)', $account->name, app('amount')->formatAnything($currency, $balance, false));
|
||||
}
|
||||
$type = (string)trans(sprintf('firefly.%s', $account->accountType->type));
|
||||
$groupedResult[$type] = $groupedResult[$type] ?? [
|
||||
$groupedResult[$type] ??= [
|
||||
'group ' => $type,
|
||||
'items' => [],
|
||||
];
|
||||
@@ -124,8 +124,8 @@ class AccountController extends Controller
|
||||
usort(
|
||||
$allItems,
|
||||
static function (array $left, array $right): int {
|
||||
$order = [AccountType::ASSET, AccountType::REVENUE, AccountType::EXPENSE];
|
||||
$posLeft = (int)array_search($left['type'], $order, true);
|
||||
$order = [AccountType::ASSET, AccountType::REVENUE, AccountType::EXPENSE];
|
||||
$posLeft = (int)array_search($left['type'], $order, true);
|
||||
$posRight = (int)array_search($right['type'], $order, true);
|
||||
|
||||
return $posLeft - $posRight;
|
||||
|
@@ -27,7 +27,6 @@ namespace FireflyIII\Api\V2\Controllers\Chart;
|
||||
use Carbon\Carbon;
|
||||
use FireflyIII\Api\V2\Controllers\Controller;
|
||||
use FireflyIII\Api\V2\Request\Chart\DashboardChartRequest;
|
||||
use FireflyIII\Api\V2\Request\Generic\DateRequest;
|
||||
use FireflyIII\Exceptions\FireflyException;
|
||||
use FireflyIII\Models\Account;
|
||||
use FireflyIII\Models\AccountType;
|
||||
@@ -100,7 +99,7 @@ class AccountController extends Controller
|
||||
$default = app('amount')->getDefaultCurrency();
|
||||
$params = $request->getAll();
|
||||
/** @var Collection $accounts */
|
||||
$accounts = $params['accounts'];
|
||||
$accounts = $params['accounts'];
|
||||
$chartData = [];
|
||||
|
||||
// user's preferences
|
||||
@@ -117,13 +116,13 @@ class AccountController extends Controller
|
||||
}
|
||||
|
||||
// both options are overruled by "preselected"
|
||||
if('all' === $params['preselected']) {
|
||||
if ('all' === $params['preselected']) {
|
||||
$accounts = $this->repository->getAccountsByType([AccountType::ASSET, AccountType::DEFAULT, AccountType::LOAN, AccountType::DEBT, AccountType::MORTGAGE]);
|
||||
}
|
||||
if('assets' === $params['preselected']) {
|
||||
if ('assets' === $params['preselected']) {
|
||||
$accounts = $this->repository->getAccountsByType([AccountType::ASSET, AccountType::DEFAULT]);
|
||||
}
|
||||
if('liabilities' === $params['preselected']) {
|
||||
if ('liabilities' === $params['preselected']) {
|
||||
$accounts = $this->repository->getAccountsByType([AccountType::LOAN, AccountType::DEBT, AccountType::MORTGAGE]);
|
||||
}
|
||||
|
||||
|
@@ -121,7 +121,7 @@ class BalanceController extends Controller
|
||||
$currencies[$currencyId] = $currency; // may just re-assign itself, don't mind.
|
||||
|
||||
// set the array with monetary info, if it does not exist.
|
||||
$data[$currencyId] = $data[$currencyId] ?? [
|
||||
$data[$currencyId] ??= [
|
||||
'currency_id' => (string)$currencyId,
|
||||
'currency_symbol' => $journal['currency_symbol'],
|
||||
'currency_code' => $journal['currency_code'],
|
||||
@@ -135,7 +135,7 @@ class BalanceController extends Controller
|
||||
];
|
||||
|
||||
// set the array (in monetary info) with spent/earned in this $period, if it does not exist.
|
||||
$data[$currencyId][$period] = $data[$currencyId][$period] ?? [
|
||||
$data[$currencyId][$period] ??= [
|
||||
'period' => $period,
|
||||
'spent' => '0',
|
||||
'earned' => '0',
|
||||
|
@@ -198,8 +198,8 @@ class BudgetController extends Controller
|
||||
* @var array $block
|
||||
*/
|
||||
foreach ($array as $currencyId => $block) {
|
||||
$this->currencies[$currencyId] = $this->currencies[$currencyId] ?? TransactionCurrency::find($currencyId);
|
||||
$return[$currencyId] = $return[$currencyId] ?? [
|
||||
$this->currencies[$currencyId] ??= TransactionCurrency::find($currencyId);
|
||||
$return[$currencyId] ??= [
|
||||
'currency_id' => (string)$currencyId,
|
||||
'currency_code' => $block['currency_code'],
|
||||
'currency_name' => $block['currency_name'],
|
||||
|
@@ -109,7 +109,7 @@ class CategoryController extends Controller
|
||||
$nativeAmount = app('steam')->positive($journal['foreign_amount']);
|
||||
}
|
||||
// create arrays
|
||||
$return[$key] = $return[$key] ?? [
|
||||
$return[$key] ??= [
|
||||
'label' => $categoryName,
|
||||
'currency_id' => (string)$currency->id,
|
||||
'currency_code' => $currency->code,
|
||||
|
@@ -28,7 +28,6 @@ use FireflyIII\Api\V2\Controllers\Controller;
|
||||
use FireflyIII\Models\Account;
|
||||
use FireflyIII\Transformers\V2\AccountTransformer;
|
||||
use Illuminate\Http\JsonResponse;
|
||||
use Illuminate\Http\Request;
|
||||
|
||||
/**
|
||||
* Show = show a single account.
|
||||
|
@@ -30,7 +30,6 @@ use FireflyIII\Repositories\UserGroups\Bill\BillRepositoryInterface;
|
||||
use FireflyIII\Support\Http\Api\ValidatesUserGroupTrait;
|
||||
use FireflyIII\Transformers\V2\BillTransformer;
|
||||
use Illuminate\Http\JsonResponse;
|
||||
use Illuminate\Http\Request;
|
||||
use Illuminate\Pagination\LengthAwarePaginator;
|
||||
|
||||
/**
|
||||
|
@@ -31,7 +31,6 @@ use FireflyIII\Repositories\UserGroups\Bill\BillRepositoryInterface;
|
||||
use FireflyIII\Support\Http\Api\ValidatesUserGroupTrait;
|
||||
use FireflyIII\Transformers\V2\BillTransformer;
|
||||
use Illuminate\Http\JsonResponse;
|
||||
use Illuminate\Http\Request;
|
||||
|
||||
/**
|
||||
* Class ShowController
|
||||
|
@@ -28,7 +28,6 @@ use FireflyIII\Api\V2\Controllers\Controller;
|
||||
use FireflyIII\Repositories\Budget\BudgetRepositoryInterface;
|
||||
use FireflyIII\Transformers\V2\BudgetTransformer;
|
||||
use Illuminate\Http\JsonResponse;
|
||||
use Illuminate\Http\Request;
|
||||
use Illuminate\Pagination\LengthAwarePaginator;
|
||||
|
||||
/**
|
||||
|
@@ -25,8 +25,6 @@ declare(strict_types=1);
|
||||
namespace FireflyIII\Api\V2\Controllers\Model\BudgetLimit;
|
||||
|
||||
use FireflyIII\Api\V2\Controllers\Controller;
|
||||
use FireflyIII\Api\V2\Request\Generic\DateRequest;
|
||||
use FireflyIII\Models\Budget;
|
||||
use Illuminate\Http\JsonResponse;
|
||||
|
||||
/**
|
||||
|
@@ -30,7 +30,6 @@ use FireflyIII\Repositories\UserGroups\PiggyBank\PiggyBankRepositoryInterface;
|
||||
use FireflyIII\Support\Http\Api\ValidatesUserGroupTrait;
|
||||
use FireflyIII\Transformers\V2\PiggyBankTransformer;
|
||||
use Illuminate\Http\JsonResponse;
|
||||
use Illuminate\Http\Request;
|
||||
use Illuminate\Pagination\LengthAwarePaginator;
|
||||
|
||||
/**
|
||||
|
@@ -169,10 +169,10 @@ class BasicController extends Controller
|
||||
$nativeAmount = $transactionJournal['foreign_amount'];
|
||||
}
|
||||
// prep the arrays
|
||||
$incomes[$currencyId] = $incomes[$currencyId] ?? '0';
|
||||
$incomes['native'] = $incomes['native'] ?? '0';
|
||||
$sums[$currencyId] = $sums[$currencyId] ?? '0';
|
||||
$sums['native'] = $sums['native'] ?? '0';
|
||||
$incomes[$currencyId] ??= '0';
|
||||
$incomes['native'] ??= '0';
|
||||
$sums[$currencyId] ??= '0';
|
||||
$sums['native'] ??= '0';
|
||||
|
||||
// add values:
|
||||
$incomes[$currencyId] = bcadd($incomes[$currencyId], $amount);
|
||||
@@ -208,10 +208,10 @@ class BasicController extends Controller
|
||||
}
|
||||
|
||||
// prep arrays
|
||||
$expenses[$currencyId] = $expenses[$currencyId] ?? '0';
|
||||
$expenses['native'] = $expenses['native'] ?? '0';
|
||||
$sums[$currencyId] = $sums[$currencyId] ?? '0';
|
||||
$sums['native'] = $sums['native'] ?? '0';
|
||||
$expenses[$currencyId] ??= '0';
|
||||
$expenses['native'] ??= '0';
|
||||
$sums[$currencyId] ??= '0';
|
||||
$sums['native'] ??= '0';
|
||||
|
||||
// add values
|
||||
$expenses[$currencyId] = bcadd($expenses[$currencyId], $amount);
|
||||
|
@@ -31,7 +31,6 @@ use FireflyIII\Models\UserGroup;
|
||||
use FireflyIII\Repositories\UserGroup\UserGroupRepositoryInterface;
|
||||
use FireflyIII\User;
|
||||
use Illuminate\Http\JsonResponse;
|
||||
use Illuminate\Http\Request;
|
||||
use Symfony\Component\HttpKernel\Exception\NotFoundHttpException;
|
||||
|
||||
/**
|
||||
|
@@ -30,7 +30,6 @@ use FireflyIII\Models\UserGroup;
|
||||
use FireflyIII\Repositories\UserGroup\UserGroupRepositoryInterface;
|
||||
use FireflyIII\Transformers\V2\UserGroupTransformer;
|
||||
use Illuminate\Http\JsonResponse;
|
||||
use Illuminate\Http\Request;
|
||||
use Illuminate\Pagination\LengthAwarePaginator;
|
||||
use Illuminate\Support\Collection;
|
||||
|
||||
|
@@ -27,7 +27,6 @@ use FireflyIII\Enums\UserRoleEnum;
|
||||
use FireflyIII\Models\AccountType;
|
||||
use FireflyIII\Support\Request\ChecksLogin;
|
||||
use FireflyIII\Support\Request\ConvertsDataTypes;
|
||||
use FireflyIII\User;
|
||||
use Illuminate\Foundation\Http\FormRequest;
|
||||
|
||||
/**
|
||||
|
@@ -55,7 +55,7 @@ class AutoSum
|
||||
/** @var string $amount */
|
||||
$amount = $getSum($object);
|
||||
|
||||
$return[$currency->id] = $return[$currency->id] ?? [
|
||||
$return[$currency->id] ??= [
|
||||
'id' => (string)$currency->id,
|
||||
'name' => $currency->name,
|
||||
'symbol' => $currency->symbol,
|
||||
|
Reference in New Issue
Block a user