<% if step.completed_on %>✓<% end %>
<%= step.position + 1 %>. <%= step.name %>
<%= step.description.html_safe %>
<% step.checklists.each do |checklist| %>
<%= checklist.name %>
<% checklist.checklist_items.order(position: :asc).each do |checklist_item| %>
<% if checklist_item.checked %>
✓
<% end %>
<%= checklist_item.text %>
<% end %>
<% end %>
<% step.tables.each do |table| %>
<% table_data = JSON.parse(table.contents)["data"] %>
<%= table.name %>
|
<% col = "A" %>
<% table_data[0].length.times do %>
<%= col %> |
<% col.succ! %>
<% end %>
<% table_data.each_with_index do |tr, row| %>
<%= row + 1 %> |
<% tr.each do |td| %>
<%= td %> |
<% end %>
<% end %>
<% end %>
<% step.assets.where(view_mode: "inline").each do |asset| %>
<%= image_tag asset.blob.url %>
<%= asset.blob.filename %>
<% end %>
<% step.assets.where(view_mode: "list").each do |asset| %>
<%= file_extension_icon_html(asset) %>
<%= asset.blob.filename %>
<% end %>
<% step.assets.where(view_mode: "thumbnail").each do |asset| %>
<%= image_tag asset.blob.representation(resize_to_limit: Constants::MEDIUM_PIC_FORMAT).processed %>
<%= asset.blob.filename %>
<% end %>
<% if params[:include_comments] && step.comments.present? %>
<% end %>
<%= t('Comments') %>:
<% step.step_comments.each do |comment| %>