Numeri/flaskapp.py

22 lines
477 B
Python
Raw Normal View History

2021-09-15 20:08:03 +00:00
from flask import Flask, render_template
app = Flask("Project Numeri")
from plots import Cijferlijst
import base64
cf = Cijferlijst()
import matplotlib.pyplot as plt
2021-09-15 20:08:03 +00:00
@app.route('/')
def index():
data = cf.GetSubjectByYear("godsdienst", "2010/2011")
x = data['Datum invoer(Voortgangsdossier)']
y = data['Cijfer(Voortgangsdossier)']
plt.plot(x,y)
return render_template('index.html', title="joe", imgdata=None)
2021-09-15 20:08:03 +00:00
def RunWeb():
app.run(debug=True)