Fix small commands

This commit is contained in:
James Cole
2023-04-16 08:01:40 +02:00
parent 49c27aff2d
commit d5f5df82b6
2 changed files with 10 additions and 10 deletions

View File

@@ -90,7 +90,7 @@ class CorrectAmounts extends Command
$set = AutoBudget::where('amount', '<', 0)->get();
$count = $set->count();
if (0 === $count) {
$this->info('All auto budget amounts are positive.');
$this->info('Correct: All auto budget amounts are positive.');
return;
}
/** @var AutoBudget $item */
@@ -109,7 +109,7 @@ class CorrectAmounts extends Command
$set = AvailableBudget::where('amount', '<', 0)->get();
$count = $set->count();
if (0 === $count) {
$this->info('All available budget amounts are positive.');
$this->info('Correct: All available budget amounts are positive.');
return;
}
/** @var AvailableBudget $item */
@@ -128,7 +128,7 @@ class CorrectAmounts extends Command
$set = Bill::where('amount_min', '<', 0)->orWhere('amount_max', '<', 0)->get();
$count = $set->count();
if (0 === $count) {
$this->info('All bill amounts are positive.');
$this->info('Correct: All bill amounts are positive.');
return;
}
/** @var Bill $item */
@@ -147,7 +147,7 @@ class CorrectAmounts extends Command
$set = BudgetLimit::where('amount', '<', 0)->get();
$count = $set->count();
if (0 === $count) {
$this->info('All budget limit amounts are positive.');
$this->info('Correct: All budget limit amounts are positive.');
return;
}
/** @var BudgetLimit $item */
@@ -166,7 +166,7 @@ class CorrectAmounts extends Command
$set = CurrencyExchangeRate::where('rate', '<', 0)->get();
$count = $set->count();
if (0 === $count) {
$this->info('All currency exchange rates are positive.');
$this->info('Correct: All currency exchange rates are positive.');
return;
}
/** @var BudgetLimit $item */
@@ -185,7 +185,7 @@ class CorrectAmounts extends Command
$set = PiggyBankRepetition::where('currentamount', '<', 0)->get();
$count = $set->count();
if (0 === $count) {
$this->info('All piggy bank repetition amounts are positive.');
$this->info('Correct: All piggy bank repetition amounts are positive.');
return;
}
/** @var PiggyBankRepetition $item */
@@ -204,7 +204,7 @@ class CorrectAmounts extends Command
$set = PiggyBank::where('targetamount', '<', 0)->get();
$count = $set->count();
if (0 === $count) {
$this->info('All piggy bank amounts are positive.');
$this->info('Correct: All piggy bank amounts are positive.');
return;
}
/** @var PiggyBankRepetition $item */
@@ -225,7 +225,7 @@ class CorrectAmounts extends Command
->get();
$count = $set->count();
if (0 === $count) {
$this->info('All recurring transaction amounts are positive.');
$this->info('Correct: All recurring transaction amounts are positive.');
return;
}
/** @var PiggyBankRepetition $item */
@@ -254,7 +254,7 @@ class CorrectAmounts extends Command
}
}
if (0 === $fixed) {
$this->info('All rule trigger amounts are positive.');
$this->info('Correct: All rule trigger amounts are positive.');
return;
}
$this->line(sprintf('Corrected %d rule trigger amount(s).', $fixed));

View File

@@ -98,7 +98,7 @@ class UpgradeDatabase extends Command
private function callInitialCommands(): void
{
$this->line('Now seeding the database...');
$this->call('migrate', ['--seed' => true, '--force' => true,' --no-interaction' => true]);
$this->call('migrate', ['--seed' => true, '--force' => true,'--no-interaction' => true]);
$this->line('Fix PostgreSQL sequences.');
$this->call('firefly-iii:fix-pgsql-sequences');