Skip to content

Commit

Permalink
Merge pull request #181 from epwinchell/decorator_font_icon_cleanup
Browse files Browse the repository at this point in the history
decorator icon cleanup
  • Loading branch information
himdel authored Jan 19, 2017
2 parents 685f055 + ad0346a commit f8f252b
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 3 deletions.
7 changes: 6 additions & 1 deletion app/decorators/miq_request_decorator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,12 @@ class MiqRequestDecorator < Draper::Decorator
delegate_all

def fonticon
nil
case request_status.to_s.downcase
when "ok"
"pficon pficon-ok"
when "error"
"pficon pficon-error-circle-o"
end
end

def listicon_image
Expand Down
2 changes: 1 addition & 1 deletion app/decorators/resource_pool_decorator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ class ResourcePoolDecorator < Draper::Decorator
delegate_all

def fonticon
nil
"pficon pficon-resource-pool"
end

def listicon_image
Expand Down
2 changes: 1 addition & 1 deletion app/decorators/service_resource_decorator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ class ServiceResourceDecorator < Draper::Decorator
delegate_all

def fonticon
nil
resource_type.to_s == 'VmOrTemplate' ? 'pficon pficon-virtual-machine' : 'product product-template'
end

def listicon_image
Expand Down

0 comments on commit f8f252b

Please sign in to comment.