Merge pull request #10845 from firefly-iii/release-1756752249

🤖 Automatically merge the PR into the develop branch.
This commit is contained in:
github-actions[bot]
2025-09-01 20:44:18 +02:00
committed by GitHub
4 changed files with 122 additions and 118 deletions

View File

@@ -63,6 +63,7 @@ class ShowRequest extends FormRequest
public function rules(): array
{
$keys = implode(',', array_keys($this->types));
return [
'date' => 'date',
'start' => 'date|present_with:end|before_or_equal:end|before:2038-01-17|after:1970-01-02',

View File

@@ -144,7 +144,8 @@ class AccountEnrichment implements EnrichmentInterface
{
$set = AccountMeta::whereIn('name', ['is_multi_currency', 'include_net_worth', 'currency_id', 'account_role', 'account_number', 'BIC', 'liability_direction', 'interest', 'interest_period', 'current_debt'])
->whereIn('account_id', $this->ids)
->get(['account_meta.id', 'account_meta.account_id', 'account_meta.name', 'account_meta.data'])->toArray();
->get(['account_meta.id', 'account_meta.account_id', 'account_meta.name', 'account_meta.data'])->toArray()
;
/** @var array $entry */
foreach ($set as $entry) {
@@ -172,7 +173,8 @@ class AccountEnrichment implements EnrichmentInterface
$notes = Note::query()->whereIn('noteable_id', $this->ids)
->whereNotNull('notes.text')
->where('notes.text', '!=', '')
->where('noteable_type', Account::class)->get(['notes.noteable_id', 'notes.text'])->toArray();
->where('noteable_type', Account::class)->get(['notes.noteable_id', 'notes.text'])->toArray()
;
foreach ($notes as $note) {
$this->notes[(int)$note['noteable_id']] = (string)$note['text'];
}
@@ -182,7 +184,8 @@ class AccountEnrichment implements EnrichmentInterface
private function collectLocations(): void
{
$locations = Location::query()->whereIn('locatable_id', $this->ids)
->where('locatable_type', Account::class)->get(['locations.locatable_id', 'locations.latitude', 'locations.longitude', 'locations.zoom_level'])->toArray();
->where('locatable_type', Account::class)->get(['locations.locatable_id', 'locations.latitude', 'locations.longitude', 'locations.zoom_level'])->toArray()
;
foreach ($locations as $location) {
$this->locations[(int)$location['locatable_id']]
= [
@@ -204,7 +207,8 @@ class AccountEnrichment implements EnrichmentInterface
->setUserGroup($this->userGroup)
->setAccounts($this->collection)
->withAccountInformation()
->setTypes([TransactionTypeEnum::OPENING_BALANCE->value]);
->setTypes([TransactionTypeEnum::OPENING_BALANCE->value])
;
$journals = $collector->getExtractedJournals();
foreach ($journals as $journal) {
$this->openingBalances[(int)$journal['source_account_id']]
@@ -370,7 +374,8 @@ class AccountEnrichment implements EnrichmentInterface
$set = DB::table('object_groupables')
->whereIn('object_groupable_id', $this->ids)
->where('object_groupable_type', Account::class)
->get(['object_groupable_id', 'object_group_id']);
->get(['object_groupable_id', 'object_group_id'])
;
$ids = array_unique($set->pluck('object_group_id')->toArray());
@@ -421,7 +426,7 @@ class AccountEnrichment implements EnrichmentInterface
}
$startBalance = $this->startBalances[$id] ?? [];
$endBalance = $this->endBalances[$id] ?? [];
if (count($startBalance) === 0 || count($endBalance) === 0) {
if (0 === count($startBalance) || 0 === count($endBalance)) {
return null;
}
$start = $startBalance[$currency->code] ?? '0';
@@ -429,6 +434,4 @@ class AccountEnrichment implements EnrichmentInterface
return bcsub($end, $start);
}
}

View File

@@ -79,7 +79,7 @@ return [
// see cer.php for exchange rates feature flag.
],
'version' => 'develop/2025-09-01',
'build_time' => 1756729173,
'build_time' => 1756752129,
'api_version' => '2.1.0', // field is no longer used.
'db_version' => 26,