This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from flask import jsonify | |
@app.route('/data/ideas') | |
def data_ideas(): | |
# query for the ideas - return oldest first, limit 10 | |
ideas = models.Idea.objects().order_by('+timestamp').limit(10) | |
if ideas: |