Work in progress: has_many_polymorphs does not work with rails 3.2 because of intrusive changes in rails internals. I think we need to rip out this dependency...

This commit is contained in:
Reinier Balt 2012-04-05 22:19:47 +02:00
parent a83c8b3f92
commit 86afd42148
162 changed files with 704 additions and 8724 deletions

View file

@ -9,6 +9,9 @@ if defined?(Bundler)
# Bundler.require(:default, :assets, Rails.env)
end
require 'yaml'
SITE_CONFIG = YAML.load_file(File.join(File.dirname(__FILE__), 'site.yml'))
module Tracksapp
class Application < Rails::Application
# Settings in config/environments/* take precedence over those specified here.
@ -28,6 +31,7 @@ module Tracksapp
# Set Time.zone default to the specified zone and make Active Record auto-convert to this zone.
# Run "rake -D time" for a list of tasks for finding time zone names. Default is UTC.
# config.time_zone = 'Central Time (US & Canada)'
config.time_zone = SITE_CONFIG['time_zone']
# The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.
# config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
@ -49,11 +53,20 @@ module Tracksapp
# in your app. As such, your models will need to explicitly whitelist or blacklist accessible
# parameters by using an attr_accessible or attr_protected declaration.
config.active_record.whitelist_attributes = true
# Set timezone of dates in database
config.active_record.default_timezone = :utc
# Enable the asset pipeline
config.assets.enabled = true
# Version of your assets, change this if you want to expire all your assets
config.assets.version = '1.0'
# configure Tracks to handle deployment in a subdir
config.action_controller.relative_url_root = SITE_CONFIG['subdir'] if SITE_CONFIG['subdir']
# allow onenote:// and message:// as protocols for urls
config.action_view.sanitized_allowed_protocols = 'onenote', 'message'
end
end