Module: Authpds::Controllers::AuthpdsController
- Includes:
- Helpers::CurrentUserHelper, Helpers::Institution::CurrentInstitutionHelper, Helpers::Institution::UrlHelper
- Defined in:
- lib/authpds/controllers/authpds_controller.rb
Class Method Summary collapse
Instance Method Summary collapse
-
#user_session_redirect_url(url) ⇒ Object
Controller method to generate the Appropriate redirect url.
Methods included from Helpers::Institution::UrlHelper
Methods included from Helpers::Institution::ParamHelper
#institution_param, #institution_param_key
Methods included from Helpers::Institution::CurrentInstitutionHelper
Methods included from Helpers::CurrentUserHelper
#current_user, #current_user_session
Class Method Details
.included(klass) ⇒ Object
8 9 10 11 12 13 14 |
# File 'lib/authpds/controllers/authpds_controller.rb', line 8 def self.included(klass) # Include klass.class_eval do helper_method :current_user_session, :current_user helper_method :current_primary_institution end end |
Instance Method Details
#user_session_redirect_url(url) ⇒ Object
Controller method to generate the Appropriate redirect url
17 18 19 20 21 22 23 24 25 26 27 |
# File 'lib/authpds/controllers/authpds_controller.rb', line 17 def user_session_redirect_url(url) # Work with what we have case when url.present? url when request.referer.present? request.referer else root_url end end |