Firefly III: a personal finances manager
PHP accountingbudgetbudgetingbudgetscash-flowcashflowcredit-carddockerexpensesfinancefinancesfinanciallinuxmoneypaycheckpersonal-financephpphp7
Clean up some code.
James Colee449395f3fcc
diff --git a/.ci/php-cs-fixer/composer.lock b/.ci/php-cs-fixer/composer.lockindex d8a944d9a1..97d0a4a42a 100644--- a/.ci/php-cs-fixer/composer.lock+++ b/.ci/php-cs-fixer/composer.lock@@ -226,16 +226,16 @@},{"name": "friendsofphp/php-cs-fixer",- "version": "v3.47.1",+ "version": "v3.48.0","source": {"type": "git","url": "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer.git",- "reference": "173c60d1eff911c9c54322704623a45561d3241d"+ "reference": "a92472c6fb66349de25211f31c77eceae3df024e"},"dist": {"type": "zip",- "url": "https://api.github.com/repos/PHP-CS-Fixer/PHP-CS-Fixer/zipball/173c60d1eff911c9c54322704623a45561d3241d",- "reference": "173c60d1eff911c9c54322704623a45561d3241d",+ "url": "https://api.github.com/repos/PHP-CS-Fixer/PHP-CS-Fixer/zipball/a92472c6fb66349de25211f31c77eceae3df024e",+ "reference": "a92472c6fb66349de25211f31c77eceae3df024e","shasum": ""},"require": {@@ -305,7 +305,7 @@],"support": {"issues": "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues",- "source": "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/tree/v3.47.1"+ "source": "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/tree/v3.48.0"},"funding": [{@@ -313,7 +313,7 @@"type": "github"}],- "time": "2024-01-16T18:54:21+00:00"+ "time": "2024-01-19T21:44:39+00:00"},{"name": "psr/container",diff --git a/app/Models/Transaction.php b/app/Models/Transaction.phpindex 4626848073..974cc3d7a7 100644--- a/app/Models/Transaction.php+++ b/app/Models/Transaction.php@@ -99,28 +99,28 @@ class Transaction extends Modelprotected $casts= [- 'created_at' => 'datetime',- 'updated_at' => 'datetime',- 'deleted_at' => 'datetime',- 'identifier' => 'int',- 'encrypted' => 'boolean', // model does not have these fields though- 'bill_name_encrypted' => 'boolean',- 'reconciled' => 'boolean',- 'date' => 'datetime',- ];+ 'created_at' => 'datetime',+ 'updated_at' => 'datetime',+ 'deleted_at' => 'datetime',+ 'identifier' => 'int',+ 'encrypted' => 'boolean', // model does not have these fields though+ 'bill_name_encrypted' => 'boolean',+ 'reconciled' => 'boolean',+ 'date' => 'datetime',+ ];protected $fillable= [- 'account_id',- 'transaction_journal_id',- 'description',- 'amount',- 'identifier',- 'transaction_currency_id',- 'foreign_currency_id',- 'foreign_amount',- 'reconciled',- ];+ 'account_id',+ 'transaction_journal_id',+ 'description',+ 'amount',+ 'identifier',+ 'transaction_currency_id',+ 'foreign_currency_id',+ 'foreign_amount',+ 'reconciled',+ ];protected $hidden = ['encrypted'];diff --git a/app/TransactionRules/Engine/SearchRuleEngine.php b/app/TransactionRules/Engine/SearchRuleEngine.phpindex e85773599d..d4828acdbf 100644--- a/app/TransactionRules/Engine/SearchRuleEngine.php+++ b/app/TransactionRules/Engine/SearchRuleEngine.php@@ -299,6 +299,7 @@ class SearchRuleEngine implements RuleEngineInterfaceapp('log')->debug(sprintf('Now at rule trigger #%d: %s:"%s" (%s).', $ruleTrigger->id, $ruleTrigger->trigger_type, $ruleTrigger->trigger_value, var_export($ruleTrigger->stop_processing, true)));if (false === $ruleTrigger->active) {app('log')->debug('Trigger is not active, continue.');+continue;}if ('user_action' === $ruleTrigger->trigger_type) {diff --git a/app/Validation/FireflyValidator.php b/app/Validation/FireflyValidator.phpindex e5b2620182..66e89d4f7b 100644--- a/app/Validation/FireflyValidator.php+++ b/app/Validation/FireflyValidator.php@@ -342,21 +342,7 @@ class FireflyValidator extends Validator// these triggers need just the word "true":// TODO create a helper to automatically return these.$needTrue = [- 'reconciled',- 'has_attachments',- 'has_any_category',- 'has_any_budget',- 'has_any_bill',- 'has_any_tag',- 'any_notes',- 'any_external_url',- 'has_no_attachments',- 'has_no_category',- 'has_no_budget',- 'has_no_bill',- 'has_no_tag',- 'no_notes',- 'no_external_url',+ 'reconciled', 'has_attachments', 'has_any_category', 'has_any_budget', 'has_any_bill', 'has_any_tag', 'any_notes', 'any_external_url', 'has_no_attachments', 'has_no_category', 'has_no_budget', 'has_no_bill', 'has_no_tag', 'no_notes', 'no_external_url','source_is_cash','destination_is_cash','account_is_cash',