From f3654718cf80fb81d5c76ebef6ea65f741ef142e Mon Sep 17 00:00:00 2001 From: Nicolas Bally Date: Wed, 6 Oct 2021 10:41:51 +0200 Subject: [PATCH] Blocage fonctions --- app/controllers/application_controller.rb | 4 ++-- app/controllers/public/joins_controller.rb | 2 +- app/controllers/public/orders_controller.rb | 1 + app/controllers/public/renews_controller.rb | 1 + 4 files changed, 5 insertions(+), 3 deletions(-) diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb index 0c68ea7..efc755d 100644 --- a/app/controllers/application_controller.rb +++ b/app/controllers/application_controller.rb @@ -54,8 +54,8 @@ class ApplicationController < ActionController::Base def current_fuser - - @current_fuser ||= ForumUser.find_by_auth_token!(cookies[:forum_auth_token]) if cookies[:forum_auth_token] + @current_fuser = nil + #@current_fuser ||= ForumUser.find_by_auth_token!(cookies[:forum_auth_token]) if cookies[:forum_auth_token] #if session[:forum_user_id] and ForumUser.exists?(session[:forum_user_id]) diff --git a/app/controllers/public/joins_controller.rb b/app/controllers/public/joins_controller.rb index f0d23b6..93d6a1f 100644 --- a/app/controllers/public/joins_controller.rb +++ b/app/controllers/public/joins_controller.rb @@ -7,7 +7,7 @@ class Public::JoinsController < ApplicationController def select_sheet - + raise if !session[:sheet_id] or !(@sheet = Sheet.where(:id => session[:sheet_id]).first) @sheet = Sheet.new(:sheet_type => 1, :web => true) @sheet.people.build(:web => true) diff --git a/app/controllers/public/orders_controller.rb b/app/controllers/public/orders_controller.rb index 565f0f0..325d24c 100644 --- a/app/controllers/public/orders_controller.rb +++ b/app/controllers/public/orders_controller.rb @@ -6,6 +6,7 @@ class Public::OrdersController < ApplicationController skip_before_filter :verify_authenticity_token, :only => [:ipn] def new + raise @order = Order.new(:country => "France") end diff --git a/app/controllers/public/renews_controller.rb b/app/controllers/public/renews_controller.rb index 382c3b1..f9c2c46 100644 --- a/app/controllers/public/renews_controller.rb +++ b/app/controllers/public/renews_controller.rb @@ -7,6 +7,7 @@ class Public::RenewsController < ApplicationController def select_sheet + raise @renew = Renew.new(:sheet_number => params[:s]) end