From c1b126845df8b5305b529f5564b929e5550b45b6 Mon Sep 17 00:00:00 2001 From: FrederikBaerentsen Date: Fri, 19 Apr 2024 10:21:00 +0200 Subject: [PATCH] Added extra Show options --- app.py | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/app.py b/app.py index b3233fc..cfbf974 100644 --- a/app.py +++ b/app.py @@ -299,6 +299,25 @@ def new_set(set_num): count = 0 socketio.emit('task_completed', namespace='/progress') +@app.route('/missing',methods=['POST','GET']) +def missing(): + conn = sqlite3.connect('app.db') + cursor = conn.cursor() + cursor.execute('SELECT id, part_num, color_id, element_id, SUM(quantity) AS total_quantity FROM missing GROUP BY id, part_num, color_id, element_id;') + + results = cursor.fetchall() + missing_list = [list(i) for i in results] + cursor.close() + conn.close() + + + return render_template('missing.html',missing_list=missing_list) + +@app.route('/minifigs',methods=['POST','GET']) +def minifigs(): + + return 0 + @app.route('/create',methods=['POST','GET']) def create():