Removed hard coded links from mailer and views.

* Not tested every mail template. Hopefully everything works ;-)
This commit is contained in:
Benjamin Meichsner 2010-03-20 14:49:46 +01:00
parent 2c1952d625
commit f49c6493f4
9 changed files with 25 additions and 11 deletions

View file

@ -5,6 +5,12 @@ development: &defaults
# Don't forget to setup databases for each foodcoop. See also MULTI_COOP_INSTALL
multi_coop_install: false
# http config for this host
# Required for action mailer
protocol: http
host: localhost
port: 3000
# name of this foodcoop
name: FC Test
# foodcoop contact information (used for FAX messages)

View file

@ -17,6 +17,13 @@ end
# Initial load the default config and database from rails environment
Foodsoft.env = RAILS_ENV
# Set action mailer default host for url generating
ActionMailer::Base.default_url_options = {
:host => Foodsoft.config[:host],
:port => Foodsoft.config[:port],
:protocol => Foodsoft.config[:protocol]
}
# Configuration of the exception_notification plugin
# Mailadresses are set in config/foodsoft.yaml
ExceptionNotifier.exception_recipients = Foodsoft.config[:notification]['error_recipients']

View file

@ -7,6 +7,7 @@ ActionController::Routing::Routes.draw do |map|
map.root :controller => 'home', :action => 'index'
# User specific
map.login "/login", :controller => 'login', :action => 'login'
map.logout '/logout', :controller => 'login', :action => 'logout'
map.my_profile '/home/profile', :controller => 'home', :action => 'profile'
map.my_ordergroup '/home/ordergroup', :controller => 'home', :action => 'ordergroup'