From 27eb2857d08c12abcb8e22c96adf37d6d80e1aa0 Mon Sep 17 00:00:00 2001 From: manson Date: Tue, 15 Jul 2014 17:17:05 +0800 Subject: [PATCH] Fix url encode --- app/controllers/admin/labs_controller.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/controllers/admin/labs_controller.rb b/app/controllers/admin/labs_controller.rb index 8842dda..f01151f 100644 --- a/app/controllers/admin/labs_controller.rb +++ b/app/controllers/admin/labs_controller.rb @@ -17,7 +17,7 @@ class Admin::LabsController < OrbitMemberController @member = MemberProfile.find(lab_params['member_profile_id']) rescue nil @lab = Lab.new(lab_params) @lab.save - redirect_to '/admin/members/'+@member.to_param+'/Lab' + redirect_to URI.encode('/admin/members/'+@member.to_param+'/Lab') end def edit @@ -30,7 +30,7 @@ class Admin::LabsController < OrbitMemberController @lab = Lab.find(params[:id]) @lab.update_attributes(lab_params) @lab.save - redirect_to '/admin/members/'+@member.to_param+'/Lab' + redirect_to URI.encode('/admin/members/'+@member.to_param+'/Lab') end def destroy @@ -66,7 +66,7 @@ class Admin::LabsController < OrbitMemberController @intro = @intro.nil? ? LabIntro.new({:member_profile_id=>@member.id}) : @intro @intro.update_attributes(intro_params) @intro.save - redirect_to '/admin/members/'+@member.to_param+'/Lab' + redirect_to URI.encode('/admin/members/'+@member.to_param+'/Lab') end def get_settings