From dc01fb947510ef44298ebfa078a9e08e2febfc25 Mon Sep 17 00:00:00 2001 From: David Gay Date: Fri, 28 May 2021 10:01:18 -0400 Subject: Tweak results output --- app/views/look/_results.html.erb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/views/look/_results.html.erb b/app/views/look/_results.html.erb index 8b5466e..beb2deb 100644 --- a/app/views/look/_results.html.erb +++ b/app/views/look/_results.html.erb @@ -2,9 +2,9 @@ <% results.each do |result| %> <% case result[:type] %> <% when "item" %> -

You got <%= result[:quantity] %> <%= link_to result[:item].name, item_path(result[:item])%> +

You got <%= result[:quantity] %> <%= link_to result[:item].name, item_path(result[:item])%>. <% if result[:xp]&.any? %> - (<%= result[:xp].map { |award| "#{award[:amount] * result[:quantity]} xp #{award[:skill].name}" }.join(", ") %>) + (<%= result[:xp].map { |award| "#{award[:amount] * result[:quantity]} #{award[:skill].name} XP" }.join(", ") %>) <% end %>

<% when "hearth_amenity" %> -- cgit v1.2.3