Add renumber lectures button
This commit is contained in:
@@ -1,5 +1,11 @@
|
||||
module Admin
|
||||
class CoursesController < Admin::ApplicationController
|
||||
def renumber_lectures
|
||||
course = Course.find(params[:id])
|
||||
course.renumber_lectures!
|
||||
redirect_to admin_course_url(course), notice: "Lectures renumbered!"
|
||||
end
|
||||
|
||||
# Overwrite any of the RESTful controller actions to implement custom behavior
|
||||
# For example, you may want to send an email after a foo is updated.
|
||||
#
|
||||
|
||||
Reference in New Issue
Block a user