|
|
@ -2,7 +2,8 @@ class CourseModulesController < ApplicationController
|
|
|
|
before_action :require_login, :check_auth
|
|
|
|
before_action :require_login, :check_auth
|
|
|
|
before_action :set_module, except: [:unhidden_modules]
|
|
|
|
before_action :set_module, except: [:unhidden_modules]
|
|
|
|
before_action :find_course, only: [:unhidden_modules]
|
|
|
|
before_action :find_course, only: [:unhidden_modules]
|
|
|
|
before_action :teacher_or_admin_allowed
|
|
|
|
before_action :teacher_or_admin_allowed, except: [:add_second_category]
|
|
|
|
|
|
|
|
before_action :teacher_allowed, only: [:add_second_category]
|
|
|
|
|
|
|
|
|
|
|
|
# 模块置顶
|
|
|
|
# 模块置顶
|
|
|
|
def sticky_module
|
|
|
|
def sticky_module
|
|
|
|