modified chinese status class problem

This commit is contained in:
Harry Bomrah 2014-06-18 17:59:03 +08:00
parent ae93ba9309
commit 5946031125
1 changed files with 6 additions and 6 deletions

View File

@ -3,10 +3,10 @@ class AnnouncementsController < ApplicationController
def index
announcements = Bulletin.where(:is_preview.in=>[false,nil]).can_display.order_by(:created_at=>'desc').filter_by_categories
anns = announcements.collect do |a|
statuses = a.statuses.collect do |status|
statuses = a.statuses_with_classname.collect do |status|
{
"status" => status,
"status-class" => "status-#{status.downcase}"
"status" => status["name"],
"status-class" => "status-#{status['classname']}"
}
end
{
@ -30,10 +30,10 @@ class AnnouncementsController < ApplicationController
def widget
announcements = Bulletin.where(:is_preview.in=>[false,nil]).can_display.order_by(:created_at=>'desc').filter_by_widget_categories
anns = announcements.collect do |a|
statuses = a.statuses.collect do |status|
statuses = a.statuses_with_classname.collect do |status|
{
"status" => status,
"status-class" => "status-#{status.downcase}"
"status" => status["name"],
"status-class" => "status-#{status['classname']}"
}
end
{