wip
This commit is contained in:
1 parent
aee0a202c1
commit
e94802334d
3 files changed
+8
-4
No files matched your search
@@ -36,6 +36,11 @@ class LoadPlayer
|
||||
$counting[$tm_player_id]++;
|
||||
}
|
||||
}
|
||||
|
||||
if (! $counting) {
|
||||
return [];
|
||||
}
|
||||
|
||||
$colorlevel = round(max($counting)/3);
|
||||
|
||||
$arr = [];
|
||||
@@ -43,7 +48,7 @@ class LoadPlayer
|
||||
$tm_player_id = $val->tm_player_id;
|
||||
$matches_played = isset($counting[$tm_player_id]) ? $counting[$tm_player_id] : 0;
|
||||
if($matches_played < $colorlevel){
|
||||
$arr[$val->position][$val->tm_player_id] = '<span class="text-gray-500">'.$val->name.' ('.$matches_played.')</span>';
|
||||
$arr[$val->position][$val->tm_player_id] = '<span class="text-red-600">'.$val->name.' ('.$matches_played.')</span>';
|
||||
}
|
||||
else if($matches_played < $colorlevel*2){
|
||||
$arr[$val->position][$val->tm_player_id] = '<span class="text-blue-500">'.$val->name.' ('.$matches_played.')</span>';
|
||||
|
||||
Reference in new issue
Block a user