Пример #1
0
def get_themes(account):
    """
  Will return a list with all the themes for this account
  """

    all_themes = Badges.gql("WHERE creator=:1", account)
    """ Go through the list and remove redundancies """
    theme_set = []
    previous_theme = ""
    for theme in all_themes:
        if theme.theme != previous_theme:
            theme_set.append(theme.theme)
            previous_theme = theme.theme
Пример #2
0
def get_themes(account):
    """
  Will return a list with all the themes for this account
  """

    all_themes = Badges.gql("WHERE creator=:1", account)

    """ Go through the list and remove redundancies """
    theme_set = []
    previous_theme = ""
    for theme in all_themes:
        if theme.theme != previous_theme:
            theme_set.append(theme.theme)
            previous_theme = theme.theme
Пример #3
0
def get_all_badges_for_account(account):
    """
  Will return all badges per the account, ordered by theme
  """

    return Badges.gql("WHERE creator=:1 ORDER BY theme", account)
Пример #4
0
def get_all_badges_for_account(account):
    """
  Will return all badges per the account, ordered by theme
  """

    return Badges.gql("WHERE creator=:1 ORDER BY theme", account)