This commit is contained in:
5t4l1n
2025-07-25 23:58:20 +05:30
parent b70e81d201
commit 4d8061616d
112 changed files with 14445 additions and 59 deletions
+32
View File
@@ -0,0 +1,32 @@
from flask import Blueprint, jsonify
bp = Blueprint('quizzes', __name__)
# Handle both with and without trailing slash
@bp.route("/", methods=["GET"])
@bp.route("", methods=["GET"]) # Add this line
def list_quizzes():
quizzes = [
{
"id": "python-quiz",
"title": "Python Fundamentals Quiz",
"topic": "Programming",
"difficulty": "Easy",
"recent_performance": 85
},
{
"id": "java-quiz",
"title": "Java OOP Concepts Quiz",
"topic": "Programming",
"difficulty": "Medium",
"recent_performance": 78
},
{
"id": "security-quiz",
"title": "Cybersecurity Basics Quiz",
"topic": "Security",
"difficulty": "Hard",
"recent_performance": 72
}
]
return jsonify(quizzes)