Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Python:
- for i in data['results']:
- add_stod = True
- for j in all_stations:
- if i['company'] == j['company']:
- add_stod = False
- if add_stod:
- all_stations.append(i)
- @route('/')
- def index():
- return template('views/index', all_stations=all_stations)
- HTML:
- <section class="stodvar">
- % for stod in all_stations:
- <div class="stodvar-block">
- <div class="logo">
- <img src="/static/img/{{stod['key'][:2]}}.svg">
- </div>
- <a href="/stod/{{stod['company']}}">
- Nánar um {{stod['company']}}
- </a>
- </div>
- % end
- </section>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement