Remove not-very-useful caching for homepage modeling
Huh, I hadn't realized that like, we'd already set up the controller to always *run* basically all of the modeling logic, and the caching in the view layer wasn't saving us any queries anymore. Kinda silly! Remove the caching call, just to simplify the codebase (I like to avoid caching things that don't specifically need it!). And hey, love that the modeling code in the controller is now *way* faster to run! You love to see it!
This commit is contained in:
parent
61e22e3943
commit
860b8eef72
1 changed files with 8 additions and 9 deletions
|
@ -90,15 +90,14 @@
|
|||
%h3= t '.newest_items.unmodeled.header'
|
||||
%ul#newest-unmodeled-items
|
||||
- @newest_unmodeled_items.each do |item|
|
||||
- cache "items/#{item.id} modeling_progress locale=#{I18n.locale} updated_at=#{item.updated_at.to_i}" do
|
||||
%li{'data-item-id' => item.id}
|
||||
= link_to image_tag(item.thumbnail_url), item, :class => 'image-link'
|
||||
= link_to item, :class => 'header' do
|
||||
%h2= item.name
|
||||
%span.meter{style: "width: #{@newest_unmodeled_items_predicted_modeled_ratio[item]*100}%"}
|
||||
.missing-bodies
|
||||
= render_predicted_missing_species_by_color(@newest_unmodeled_items_predicted_missing_species_by_color[item])
|
||||
.models
|
||||
%li{'data-item-id' => item.id}
|
||||
= link_to image_tag(item.thumbnail_url), item, :class => 'image-link'
|
||||
= link_to item, :class => 'header' do
|
||||
%h2= item.name
|
||||
%span.meter{style: "width: #{@newest_unmodeled_items_predicted_modeled_ratio[item]*100}%"}
|
||||
.missing-bodies
|
||||
= render_predicted_missing_species_by_color(@newest_unmodeled_items_predicted_missing_species_by_color[item])
|
||||
.models
|
||||
- if @newest_modeled_items.present?
|
||||
%h3= t '.newest_items.modeled.header'
|
||||
%ul#newest-modeled-items
|
||||
|
|
Loading…
Reference in a new issue