Merge pull request #2304 from r888888888/admin-dashboard
Admin dashboard
This commit is contained in:
9
app/controllers/admin/dashboards_controller.rb
Normal file
9
app/controllers/admin/dashboards_controller.rb
Normal file
@@ -0,0 +1,9 @@
|
||||
module Admin
|
||||
class DashboardsController < ApplicationController
|
||||
before_filter :admin_only
|
||||
|
||||
def show
|
||||
@dashboard = AdminDashboard.new
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -18,7 +18,8 @@ class UserNameChangeRequestsController < ApplicationController
|
||||
if @change_request.errors.any?
|
||||
render :action => "new"
|
||||
else
|
||||
redirect_to user_name_change_request_path(@change_request), :notice => "Your request has been submitted and is pending admin review"
|
||||
@change_request.approve!
|
||||
redirect_to user_name_change_request_path(@change_request), :notice => "Your name has been changed"
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user