Guest User

Untitled

a guest
Apr 25th, 2018
61
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.37 KB | None | 0 0
  1. # all of this is in /app/controllers/
  2.  
  3. # file: application_controller.rb
  4. class ApplicationController < ActionController::Base
  5. #...
  6. end
  7.  
  8. # file: admin_controller.rb
  9. class AdminController < ApplicationController
  10. before_filter :auth_required
  11.  
  12. def auth_required
  13. #...
  14. end
  15. end
  16.  
  17. # file: admin/something_controller.rb
  18. class Admin::SomethingController < AdminController
  19. #...
  20. end
Add Comment
Please, Sign In to add comment