feat: configure hot leagues in match center
This commit is contained in:
@@ -52,7 +52,8 @@ class MatchController extends BaseApiController
|
||||
if ($sportType > 0) {
|
||||
$query->where('sport_type', $sportType);
|
||||
}
|
||||
$leagues = $query->field('id, label, sport_type, icon, sort')
|
||||
$leagues = $query->field('id, label, sport_type, icon, sort, is_hot')
|
||||
->order('is_hot desc')
|
||||
->order('sort asc')
|
||||
->select()
|
||||
->toArray();
|
||||
@@ -82,6 +83,7 @@ class MatchController extends BaseApiController
|
||||
'id' => $item['id'],
|
||||
'league_name' => $item['label'],
|
||||
'icon' => $item['icon'],
|
||||
'is_hot' => (int)$item['is_hot'],
|
||||
'count' => $counts[$item['label']] ?? 0,
|
||||
];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user