nouser require role
This commit is contained in:
@@ -143,6 +143,7 @@ def desktop(user_uuid, course_id, chapter_name, lesson_name):
|
|||||||
)
|
)
|
||||||
|
|
||||||
@bp.route("/desktop_nouser/<course_id>/<chapter_name>/<lesson_name>")
|
@bp.route("/desktop_nouser/<course_id>/<chapter_name>/<lesson_name>")
|
||||||
|
@require_role
|
||||||
def desktop_nouser(course_id, chapter_name, lesson_name):
|
def desktop_nouser(course_id, chapter_name, lesson_name):
|
||||||
if "user_uuid" not in session:
|
if "user_uuid" not in session:
|
||||||
return redirect(url_for("auth.login")) # 如果你有 auth 蓝图
|
return redirect(url_for("auth.login")) # 如果你有 auth 蓝图
|
||||||
|
|||||||
Reference in New Issue
Block a user