Remove some silly view template caching calls
When I was trying to debug slow view code one time long long ago, I was like "let's cache any part of the template that's static!" And like. no that's silly, I don't trust that this speeds anything up, but it _definitely_ adds complexity. Let's just not.
This commit is contained in:
parent
1f53615654
commit
73e0b3bb3c
4 changed files with 125 additions and 132 deletions
|
@ -9,7 +9,6 @@
|
|||
= will_paginate @items
|
||||
- else
|
||||
#search-info
|
||||
- localized_cache :action_suffix => 'search_help' do
|
||||
#search-help
|
||||
%h2= t '.search_help_header'
|
||||
%dl
|
||||
|
|
|
@ -16,12 +16,11 @@
|
|||
= f.select :list_id, neopets_page_list_options(current_user)
|
||||
= f.submit t('.submit')
|
||||
|
||||
- localized_cache :action_suffix => 'explanation' do
|
||||
%p
|
||||
%p
|
||||
= t '.help.welcome', :name => @import_task.page.name
|
||||
= t '.help.intro', :name => @import_task.page.name
|
||||
|
||||
%ol
|
||||
%ol
|
||||
%li
|
||||
= twl '.help.check_frame.header', :page_link_url => @import_task.page.url,
|
||||
:name => @import_task.page.name, :index => @import_task.page.expected_index
|
||||
|
|
|
@ -22,7 +22,6 @@
|
|||
DTI here for a long time to come!
|
||||
|
||||
#outfit-forms
|
||||
- localized_cache :action_suffix => 'outfit_forms_intro' do
|
||||
#pet-preview
|
||||
= image_tag 'default_preview.png', :alt => ''
|
||||
%span
|
||||
|
@ -109,18 +108,16 @@
|
|||
= image_tag item.thumbnail_url
|
||||
= nc_icon_for(item)
|
||||
|
||||
|
||||
- localized_cache :action_suffix => 'templates' do
|
||||
%script#pet-query-notice-template{:type => 'text/x-jquery-tmpl'}
|
||||
%script#pet-query-notice-template{:type => 'text/x-jquery-tmpl'}
|
||||
.notice
|
||||
%img.inline-image{:src => '${pet_image_url}'}
|
||||
= t '.pet_query.notice_html', :pet_name => '${pet_name}'
|
||||
|
||||
%script#preview-pet-type-not-found-template{:type => 'text/x-jquery-tmpl'}
|
||||
%script#preview-pet-type-not-found-template{:type => 'text/x-jquery-tmpl'}
|
||||
= t '.preview.pet_type_not_found', :color_name => '${color_name}',
|
||||
:species_name => '${species_name}'
|
||||
|
||||
%script#preview-pet-not-found-template{:type => 'text/x-jquery-tmpl'}
|
||||
%script#preview-pet-not-found-template{:type => 'text/x-jquery-tmpl'}
|
||||
= t '.preview.pet_not_found'
|
||||
|
||||
- content_for :javascripts do
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
- title t('modeling_hub')
|
||||
|
||||
= form_tag load_pet_path, :id => 'bulk-pets-form' do
|
||||
- localized_cache :action_suffix => 'bulk_pets_content' do
|
||||
%p= t '.explanation'
|
||||
|
||||
= origin_tag bulk_pets_path
|
||||
|
@ -15,8 +14,7 @@
|
|||
%button#bulk-pets-form-clear{:type => "button"}= t '.clear'
|
||||
%ul
|
||||
|
||||
- localized_cache :action_suffix => 'templates' do
|
||||
%script#item-template{:type => 'text/x-jquery-tmpl'}
|
||||
%script#item-template{:type => 'text/x-jquery-tmpl'}
|
||||
%li{:class => 'object{{if owned}} owned{{/if}}'}
|
||||
= link_to item_path(':id').sub(':id', '${id}') do
|
||||
%img{:src => '${thumbnail_url}', :alt => '${description}', :title => '${description}'}
|
||||
|
@ -39,10 +37,10 @@
|
|||
%span.object-owned= t '.needed_items.item_owned'
|
||||
{{/if}}
|
||||
|
||||
%script#needed-items-pet-header-template{:type => 'text/x-jquery/tmpl'}
|
||||
%script#needed-items-pet-header-template{:type => 'text/x-jquery/tmpl'}
|
||||
= t '.needed_items.pet_header', :pet_name => '${pet_name}'
|
||||
|
||||
%script#bulk-pets-submission-template{:type => 'text/x-jquery/tmpl'}
|
||||
%script#bulk-pets-submission-template{:type => 'text/x-jquery/tmpl'}
|
||||
%li.waiting
|
||||
%img{:src => '${pet_thumbnail}'}
|
||||
%span.name ${pet_name}
|
||||
|
@ -50,7 +48,7 @@
|
|||
%span.loading-message= t '.loading'
|
||||
%span.response
|
||||
|
||||
%script#bulk-pets-submission-success-template{:type => 'text/x-jquery/tmpl'}
|
||||
%script#bulk-pets-submission-success-template{:type => 'text/x-jquery/tmpl'}
|
||||
= t '.submission_success', :points => '${points}'
|
||||
|
||||
- content_for :javascripts do
|
||||
|
|
Loading…
Reference in a new issue