forked from OpenNeo/impress
campaign bar in infinite closet
This commit is contained in:
parent
8f0f37b4c8
commit
94d9aab547
2 changed files with 3 additions and 1 deletions
|
@ -17,6 +17,7 @@ class ItemsController < ApplicationController
|
||||||
assign_closeted!
|
assign_closeted!
|
||||||
respond_to do |format|
|
respond_to do |format|
|
||||||
format.html {
|
format.html {
|
||||||
|
@campaign = Campaign.current rescue nil
|
||||||
if @items.total_count == 1
|
if @items.total_count == 1
|
||||||
redirect_to @items.first
|
redirect_to @items.first
|
||||||
else
|
else
|
||||||
|
@ -47,6 +48,7 @@ class ItemsController < ApplicationController
|
||||||
else
|
else
|
||||||
respond_to do |format|
|
respond_to do |format|
|
||||||
format.html {
|
format.html {
|
||||||
|
@campaign = Campaign.current rescue nil
|
||||||
unless localized_fragment_exist?('items#index newest_items')
|
unless localized_fragment_exist?('items#index newest_items')
|
||||||
@newest_items = Item.newest.includes(:translations).limit(18)
|
@newest_items = Item.newest.includes(:translations).limit(18)
|
||||||
end
|
end
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
- content_for :before_title, campaign_progress
|
- content_for :before_title, campaign_progress(@campaign)
|
||||||
- content_for :title_category do
|
- content_for :title_category do
|
||||||
#{t 'infinite_closet'}: #{t '.title_tagline'}
|
#{t 'infinite_closet'}: #{t '.title_tagline'}
|
||||||
- content_for :before_flashes do
|
- content_for :before_flashes do
|
||||||
|
|
Loading…
Reference in a new issue