forked from OpenNeo/impress
capitalize each word of a species/color name (for Swamp Gas)
This commit is contained in:
parent
dafc922fa5
commit
1caa296359
1 changed files with 10 additions and 9 deletions
|
@ -7,7 +7,7 @@ class PetAttribute < StaticResource
|
||||||
end
|
end
|
||||||
|
|
||||||
def human_name
|
def human_name
|
||||||
self.name.capitalize
|
@human_name ||= self.name.split(' ').each { |word| word.capitalize! }.join(' ')
|
||||||
end
|
end
|
||||||
|
|
||||||
class << self
|
class << self
|
||||||
|
@ -52,3 +52,4 @@ class PetAttribute < StaticResource
|
||||||
@objects_ordered_by_name = @objects.sort { |a,b| a.name <=> b.name }
|
@objects_ordered_by_name = @objects.sort { |a,b| a.name <=> b.name }
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue