from flask import Blueprint
from src.utils.decorators import handle_exceptions
from src.controller.students import (
    submit_func,
    adaptive_func,
    ai_func,
    difficulty_func,
    get_ass_func,
    login_func,
    practice_set_func,
    submit_ans_func,
    teacher_assignment_func
)

students_bp = Blueprint('students', __name__)


@students_bp.route("/submit", methods=["POST"])
@handle_exceptions
def submit():
    return submit_func()


@students_bp.route("/get_adaptive_ass", methods=['POST'])
@handle_exceptions
def adaptive():
    return adaptive_func()


@students_bp.route("/get_ai_resp", methods=['POST'])
@handle_exceptions
def ai_res():
    return ai_func()


@students_bp.route("/get_difficulty", methods=['POST'])
@handle_exceptions
def diffculty():
    return difficulty_func()


@students_bp.route("/submit_answer", methods=['POST'])
@handle_exceptions
def submit_ans():
    return submit_ans_func()


@students_bp.route("/get-assesment", methods=['POST'])
@handle_exceptions
def get_asses():
    return get_ass_func()


@students_bp.route("/student-login", methods=['POST'])
@handle_exceptions
def student_log():
    return login_func()


@students_bp.route("/get-practise-assesment", methods=['GET'])
def get_prac():
    return practice_set_func()


@students_bp.route("/teacher-assignments", methods=['GET'])
@handle_exceptions
def teacher_assignments():
    return teacher_assignment_func()



