auditionadmin/app/Console/Commands/RecalculateScores.php

39 lines
810 B
PHP

<?php
namespace App\Console\Commands;
use App\Actions\Tabulation\ForceRecalculateTotalScores;
use Illuminate\Console\Command;
/**
* @codeCoverageIgnore
*/
class RecalculateScores extends Command
{
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'audition:recalculate-scores';
/**
* The console command description.
*
* @var string
*/
protected $description = 'Forces the recalculation of total scores for all entries';
/**
* Execute the console command.
*/
public function handle(ForceRecalculateTotalScores $action): void
{
$this->info('Starting score recalculation...');
$action();
$this->info('Score recalculation completed successfully.');
}
}