2023-10-05 19:25:08 +08:00
|
|
|
<% timestamp = step_text.created_at %>
|
2022-05-27 19:26:40 +08:00
|
|
|
<div class="report-element report-step-attachment-element report-step-text-element">
|
2023-10-03 17:06:53 +08:00
|
|
|
<div class="report-element-header">
|
|
|
|
<div class="text-name">
|
|
|
|
<% if step_text.name.present? %>
|
|
|
|
<em>
|
|
|
|
<%= truncate(step_text.name, length: Constants::FILENAME_TRUNCATION_LENGTH) %>
|
|
|
|
</em>
|
|
|
|
<% end %>
|
2023-10-05 19:25:08 +08:00
|
|
|
</div>
|
|
|
|
<div class="user-time">
|
|
|
|
<%= t("projects.reports.elements.step_text.user_time", timestamp: l(timestamp, format: :full)) %>
|
|
|
|
</div>
|
2023-10-03 17:06:53 +08:00
|
|
|
</div>
|
2022-05-27 19:26:40 +08:00
|
|
|
<div class="report-element-body">
|
|
|
|
<% if step_text.text.present? %>
|
2023-10-09 16:41:10 +08:00
|
|
|
<%= custom_auto_link(step_text.prepare_for_report(:text),
|
|
|
|
team: current_team,
|
|
|
|
simple_format: false,
|
|
|
|
tags: %w(img),
|
|
|
|
base64_encoded_imgs: true) %>
|
2022-05-27 19:26:40 +08:00
|
|
|
<% else %>
|
|
|
|
<em><%= t('projects.reports.elements.step.no_description') %></em>
|
|
|
|
<% end %>
|
|
|
|
</div>
|
|
|
|
<% if defined?(children) %>
|
|
|
|
<div class="report-element-children">
|
|
|
|
<%= children %>
|
|
|
|
</div>
|
|
|
|
<% end %>
|
|
|
|
</div>
|