2.0.0 Alpha: Data Refinery
This commit is contained in:
+3
-13
@@ -33,19 +33,9 @@ def detail(match_id):
|
||||
|
||||
rounds = StatsService.get_match_rounds(match_id)
|
||||
|
||||
# --- Roster Identification ---
|
||||
# Fetch active roster to identify "Our Team" players
|
||||
from web.services.web_service import WebService
|
||||
lineups = WebService.get_lineups()
|
||||
# Assume we use the first/active lineup
|
||||
active_roster_ids = []
|
||||
if lineups:
|
||||
try:
|
||||
active_roster_ids = json.loads(lineups[0]['player_ids_json'])
|
||||
except:
|
||||
pass
|
||||
|
||||
# Mark roster players (Ensure strict string comparison)
|
||||
from web.services.team_context_service import TeamContextService
|
||||
|
||||
active_roster_ids = TeamContextService.get_active_roster_ids()
|
||||
roster_set = set(str(uid) for uid in active_roster_ids)
|
||||
for p in players:
|
||||
p['is_in_roster'] = str(p['steam_id_64']) in roster_set
|
||||
|
||||
Reference in New Issue
Block a user