поправил отображение каналов на расписании тура, когда матч live, каналы не пишутся
This commit is contained in:
2
app.py
2
app.py
@@ -1483,7 +1483,7 @@ def vmix_schedule(session_token: str):
|
||||
),
|
||||
"channel": (
|
||||
rf"D:\Графика\ФУТБОЛ\Женская Суперлига 2026\Лого каналов\{row[7]}.png"
|
||||
if row[7]
|
||||
if row[7] and row[5] == "scheduled"
|
||||
else r"D:\Графика\ФУТБОЛ\Женская Суперлига 2026\Лого каналов\EMPTY.png"
|
||||
),
|
||||
}
|
||||
|
||||
@@ -217,10 +217,10 @@ def fetch_match_live_data(match_id: int) -> dict:
|
||||
live = soup.find("section", class_=lambda c: c and "game--live" in c)
|
||||
if live:
|
||||
return {"status": "live", "home_score": home, "away_score": away}
|
||||
elif not live and home and away:
|
||||
else:
|
||||
return {"status": "finished", "home_score": home, "away_score": away}
|
||||
|
||||
return {"status": "scheduled", "home_score": home, "away_score": away}
|
||||
# return {"status": "scheduled", "home_score": home, "away_score": away}
|
||||
|
||||
# =========================================================
|
||||
# ЛОГИКА ЗАПУСКА WATCHER'ОВ
|
||||
|
||||
Reference in New Issue
Block a user