From 999e568a0139da1078438d151a2af9231fb3bf76 Mon Sep 17 00:00:00 2001 From: Harry Bomrah Date: Fri, 22 Dec 2017 03:40:17 +0800 Subject: [PATCH] small fixed --- app/controllers/pseudo_session_controller.rb | 4 ++++ config/routes.rb | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/app/controllers/pseudo_session_controller.rb b/app/controllers/pseudo_session_controller.rb index 3a140a3..7d99e95 100644 --- a/app/controllers/pseudo_session_controller.rb +++ b/app/controllers/pseudo_session_controller.rb @@ -22,6 +22,10 @@ class PseudoSessionController < ApplicationController end end + def member_login_path + "/" + I18n.locale.to_s + Page.where(:module => "pseudo_member").first.url + end + def destroy_pseudo_session session.delete(:current_pseudo_user_id) end diff --git a/config/routes.rb b/config/routes.rb index 2506a2b..5a1a9f3 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -14,7 +14,7 @@ Rails.application.routes.draw do end scope "pseudo_users" do post "/loginpseudouser", to: "pseudo_members#loginuser" - get "/logoutpseudouser", to: "pseudo_members#logoutuser" + get "/logoutpseudouser", to: "pseudo_members#logoutuser", as: "member_logout" post "/register_pseudo_user", to: "pseudo_members#register_user", as: "register_pseudo_user" end end