13 lines
212 B
Ruby
13 lines
212 B
Ruby
module ProductsHelper
|
|
def kcal(calories)
|
|
calories.to_s + " kcal"
|
|
end
|
|
|
|
def kcal_tag(calories)
|
|
if calories
|
|
content_tag :small, kcal(calories)
|
|
else
|
|
' '.html_safe
|
|
end
|
|
end
|
|
end
|