Example #1
0
def index_events():
    events = Event.select()
    event_list = []
    for event in events:
        event = model_to_dict(event)
        event_list.append(event)
    return jsonify(event_list)
Example #2
0
def index():
    events = Event.select()
    return render_template('events/index.html', events=events)