mirror of
https://github.com/internetee/registry.git
synced 2025-05-17 01:47:18 +02:00
Add EppSession for custom session management
This commit is contained in:
parent
3a57126e69
commit
e9f23ba348
9 changed files with 92 additions and 2 deletions
|
@ -11,6 +11,7 @@ class Epp::SessionsController < ApplicationController
|
|||
@epp_user = EppUser.find_by(login_params)
|
||||
|
||||
if @epp_user.try(:active)
|
||||
epp_session[:epp_user_id] = @epp_user.id
|
||||
render 'login_success'
|
||||
else
|
||||
response.headers['X-EPP-Returncode'] = '2200'
|
||||
|
@ -19,6 +20,7 @@ class Epp::SessionsController < ApplicationController
|
|||
end
|
||||
|
||||
def logout
|
||||
epp_session[:epp_user_id] = nil
|
||||
response.headers['X-EPP-Returncode'] = '1500'
|
||||
render 'logout'
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue