summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Wintermeyer <stefan.wintermeyer@amooma.de>2013-01-10 12:29:07 +0100
committerStefan Wintermeyer <stefan.wintermeyer@amooma.de>2013-01-10 12:29:07 +0100
commit2b57fadfebf7f7df6a589ab089eec522413e8390 (patch)
treef2b9e1b27f0534f6383489cf691f8821ee7aa105
parent7b1295884861b222e441f431089ea3a6d99fd569 (diff)
Added fragment caching to gs_parameters.
-rw-r--r--app/views/gs_parameters/_index_core.html.haml2
-rw-r--r--app/views/gs_parameters/index.html.haml2
-rw-r--r--config/environments/development.rb3
3 files changed, 5 insertions, 2 deletions
diff --git a/app/views/gs_parameters/_index_core.html.haml b/app/views/gs_parameters/_index_core.html.haml
index ece3922..0c36560 100644
--- a/app/views/gs_parameters/_index_core.html.haml
+++ b/app/views/gs_parameters/_index_core.html.haml
@@ -1,6 +1,6 @@
- cache([gs_parameters.first.section, gs_parameters.reorder(:updated_at).last, gs_parameters.pluck(:id)]) do
%tr
- %th= t('gs_parameters.index.name') + 'asd'
+ %th= t('gs_parameters.index.name')
- if !@sections
%th= t('gs_parameters.index.section')
%th= t('gs_parameters.index.value')
diff --git a/app/views/gs_parameters/index.html.haml b/app/views/gs_parameters/index.html.haml
index 51957b6..3c16806 100644
--- a/app/views/gs_parameters/index.html.haml
+++ b/app/views/gs_parameters/index.html.haml
@@ -8,7 +8,7 @@
%tr
%td{:colspan => 3}
%h3= section
- / Template Dependency: gs_parameters/index_core
+ -# Template Dependency: gs_parameters/_index_core
= render "index_core", :gs_parameters => @gs_parameters.where(:section => section)
- else
%table
diff --git a/config/environments/development.rb b/config/environments/development.rb
index 5130681..5076f48 100644
--- a/config/environments/development.rb
+++ b/config/environments/development.rb
@@ -11,7 +11,10 @@ Gemeinschaft42c::Application.configure do
# Show full error reports and disable caching
config.consider_all_requests_local = true
+
+ # Enable caching for development
config.action_controller.perform_caching = true
+ CacheDigests::TemplateDigestor.cache = ActiveSupport::Cache::NullStore.new
# Don't care if the mailer can't send
config.action_mailer.raise_delivery_errors = false