From 6fe08003b2d7acf27092e27bca9962e2efd04795 Mon Sep 17 00:00:00 2001 From: Chris Blanchard Date: Fri, 18 Sep 2015 13:35:17 +0100 Subject: [PATCH 1/2] Add helper method for new gathers url --- app/helpers/application_helper.rb | 8 ++++++++ app/views/application/_navigation.html.erb | 22 +++++++++++++++++++--- app/views/gathers/show.html.erb | 4 ++++ 3 files changed, 31 insertions(+), 3 deletions(-) diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 9b9d542..561202d 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -189,4 +189,12 @@ module ApplicationHelper def latest_rules article_path(Article::RULES) end + + def gathers_url + if Rails.env.production? + "http://gathers.ensl.org" + else + "http://gathers.staging.ensl.org" + end + end end diff --git a/app/views/application/_navigation.html.erb b/app/views/application/_navigation.html.erb index ad687f7..ea46bd0 100644 --- a/app/views/application/_navigation.html.erb +++ b/app/views/application/_navigation.html.erb @@ -25,14 +25,19 @@