wip events_played / by zero
This commit is contained in:
1 parent
e198a7aa00
commit
4f53fe8023
1 file changed
+4
-3
@@ -2,9 +2,9 @@
|
|||||||
|
|
||||||
namespace App\Actions\Selections;
|
namespace App\Actions\Selections;
|
||||||
|
|
||||||
use App\Models\SofaScorePlayerPerSeason;
|
|
||||||
use App\Models\SofaScorePlayerPosition;
|
|
||||||
use App\Models\StatistikoEvent;
|
use App\Models\StatistikoEvent;
|
||||||
|
use App\Models\SofaScorePlayerPosition;
|
||||||
|
use App\Models\SofaScorePlayerPerSeason;
|
||||||
use Filament\Schemas\Components\Utilities\Get;
|
use Filament\Schemas\Components\Utilities\Get;
|
||||||
|
|
||||||
class LoadPlayer
|
class LoadPlayer
|
||||||
@@ -69,7 +69,8 @@ class LoadPlayer
|
|||||||
$infostring = $events_played;
|
$infostring = $events_played;
|
||||||
if ($preferred_foot)
|
if ($preferred_foot)
|
||||||
$infostring .= ' - ' . $preferred_foot;
|
$infostring .= ' - ' . $preferred_foot;
|
||||||
$infostring .= ' - ' . round($minues_played / $events_played) . 'min';
|
if ($events_played)
|
||||||
|
$infostring .= ' - ' . round($minues_played / $events_played) . 'min';
|
||||||
|
|
||||||
if ($events_played < $colorlevel) {
|
if ($events_played < $colorlevel) {
|
||||||
$arr[$position][$val->ss_player_id] = '<span class="text-red-600 dark:text-red-500"><b>' . $val->details->player_name . '</b><br>' . $infostring . '</span>';
|
$arr[$position][$val->ss_player_id] = '<span class="text-red-600 dark:text-red-500"><b>' . $val->details->player_name . '</b><br>' . $infostring . '</span>';
|
||||||
|
|||||||
Reference in new issue
Block a user