fix error
This commit is contained in:
parent
09121746a2
commit
38ab0c654c
|
@ -2,12 +2,12 @@ class Admin::FeedsController < OrbitAdminController
|
||||||
layout :compute_layout
|
layout :compute_layout
|
||||||
helper_method :search_all_words
|
helper_method :search_all_words
|
||||||
def compute_layout
|
def compute_layout
|
||||||
if action_name== 'annc_content'
|
if action_name== 'annc_content'
|
||||||
false
|
false
|
||||||
else
|
else
|
||||||
'back_end'
|
'back_end'
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
def index
|
def index
|
||||||
@site_feeds = SiteFeed.all.group_by(&:remote_site_url)
|
@site_feeds = SiteFeed.all.group_by(&:remote_site_url)
|
||||||
@school_urls = @site_feeds.keys
|
@school_urls = @site_feeds.keys
|
||||||
|
|
|
@ -20,7 +20,7 @@ class SiteFeedAnnc
|
||||||
Array(self[:all_contents_for_feed]).collect do |v|
|
Array(self[:all_contents_for_feed]).collect do |v|
|
||||||
tmp = v
|
tmp = v
|
||||||
if hidden_annc.exclude?(v['id']) && !tmp["title_translations"][locale].blank?
|
if hidden_annc.exclude?(v['id']) && !tmp["title_translations"][locale].blank?
|
||||||
if self.channel_key == "announcement"
|
if self.channel_key == "announcement" && (tmp["postdate"].blank? || tmp["postdate"].to_time<=Time.now)
|
||||||
tmp['statuses'] = []
|
tmp['statuses'] = []
|
||||||
if self[:top_list].count == 0 || self[:top_list].exclude?(tmp['id'])
|
if self[:top_list].count == 0 || self[:top_list].exclude?(tmp['id'])
|
||||||
tmp[:is_top] = false
|
tmp[:is_top] = false
|
||||||
|
|
Loading…
Reference in New Issue