diff --git a/app/views/order_items/_order_item.html.erb b/app/views/order_items/_order_item.html.erb index 2245ebb..db1c817 100644 --- a/app/views/order_items/_order_item.html.erb +++ b/app/views/order_items/_order_item.html.erb @@ -6,15 +6,7 @@
- <% if product.calories %> - <%= content_tag :small do - concat product.calories - concat ' kcal' - end - %> - <% else %> -   - <% end %> + <%= kcal_tag product.calories %>

<%= content_tag :span, product.name %> diff --git a/app/views/products/_product.html.erb b/app/views/products/_product.html.erb index 3ee3c50..095e73a 100644 --- a/app/views/products/_product.html.erb +++ b/app/views/products/_product.html.erb @@ -4,13 +4,7 @@ <%= image_tag product.avatar %>

-
- <% if product.calories %> - <%= product.calories %> kcal - <% else %> -   - <% end %> -
+ <%= kcal_tag product.calories %>

<%= product.name %>

<%= euro(product.price) %>

(In stock: <%= product.stock %>)