예제 #1
0
def archetype(archetype_id):
    season_id = get_season_id()
    a = archs.load_archetype(archetype_id.replace('+', ' '),
                             season_id=season_id)
    view = Archetype(
        a, archs.load_archetypes_deckless_for(a.id, season_id=season_id),
        archs.load_matchups(a.id, season_id=season_id), season_id)
    return view.page()
예제 #2
0
def archetype(archetype_id: str) -> str:
    season_id = get_season_id()
    a = archs.load_archetype(archetype_id.replace('+', ' '),
                             season_id=season_id)
    deckless_archetypes = archs.load_archetypes_deckless_for(
        a.id, season_id=season_id)
    archetype_matchups = archs.load_matchups(a.id, season_id=season_id)
    view = Archetype(a, deckless_archetypes, archetype_matchups, season_id)
    return view.page()
예제 #3
0
def archetype(archetype_id: str, deck_type: Optional[str] = None) -> str:
    tournament_only = validate_deck_type(
        deck_type, [DeckType.ALL, DeckType.TOURNAMENT]) == DeckType.TOURNAMENT
    season_id = get_season_id()
    a = archs.load_archetype(archetype_id.replace('+', ' '),
                             season_id=season_id,
                             tournament_only=tournament_only)
    deckless_archetypes = archs.load_archetypes_deckless_for(
        a.id, season_id=season_id, tournament_only=tournament_only)
    archetype_matchups = archs.load_matchups(archetype_id=a.id,
                                             season_id=season_id,
                                             tournament_only=tournament_only)
    view = Archetype(a,
                     deckless_archetypes,
                     archetype_matchups,
                     tournament_only=tournament_only,
                     season_id=season_id)
    return view.page()
예제 #4
0
def archetype(archetype_id):
    view = Archetype(archs.load_archetype(archetype_id),
                     archs.load_archetypes_deckless_for(archetype_id),
                     archs.load_matchups(archetype_id))
    return view.page()
예제 #5
0
def archetype(archetype_id):
    a = archs.load_archetype(archetype_id.replace('+', ' '))
    view = Archetype(a, archs.load_archetypes_deckless_for(a.id), archs.load_matchups(a.id))
    return view.page()