mirror of
https://gitlab.fdmci.hva.nl/technische-informatica-sm3/ti-projectten/rooziinuubii79.git
synced 2025-08-05 12:54:57 +00:00
Compare commits
2 Commits
b2432ab9cd
...
5c4a0f1e9d
Author | SHA1 | Date | |
---|---|---|---|
|
5c4a0f1e9d | ||
|
e77aa4b2dc |
1
docs/scrum/retrospective/retro_sprint_4.md
Normal file
1
docs/scrum/retrospective/retro_sprint_4.md
Normal file
@@ -0,0 +1 @@
|
||||
# retro sprint 4
|
@@ -61,9 +61,19 @@ def phpmyadmin_passthrough(path):
|
||||
|
||||
@app.route("/database")
|
||||
def database():
|
||||
cur = mysql.connection.cursor()
|
||||
# cur.execute("SELECT * FROM kobuki_data")
|
||||
return "hi",404
|
||||
try:
|
||||
cur = mysql.connection.cursor()
|
||||
cur.execute("SELECT * FROM kobuki_data")
|
||||
rows = cur.fetchall() # Haal alle rijen op uit het resultaat
|
||||
cur.close()
|
||||
|
||||
return str(rows)
|
||||
except Exception as e:
|
||||
print(f"Database error: {e}")
|
||||
return "Er is een fout opgetreden bij het ophalen van de databasegegevens.", 500
|
||||
|
||||
def add_command(command):
|
||||
command_query = "INSERT INTO kobuki (command) VALUES ();"
|
||||
|
||||
if __name__ == '__main__':
|
||||
app.run(debug=True, port=5000)
|
||||
|
Reference in New Issue
Block a user