2021-06-10 16:59:34 +08:00
|
|
|
<% table ||= report_element.table %>
|
2016-07-21 19:11:15 +08:00
|
|
|
<% timestamp = table.created_at %>
|
2021-06-10 16:59:34 +08:00
|
|
|
<div class="report-element report-step-attachment-element report-step-table-element">
|
2016-02-12 23:52:43 +08:00
|
|
|
<div class="report-element-header">
|
|
|
|
<div class="row">
|
|
|
|
<div class="pull-left attachment-icon">
|
2021-06-10 16:59:34 +08:00
|
|
|
<span class="fas fa-table"></span>
|
2016-02-12 23:52:43 +08:00
|
|
|
</div>
|
2018-08-29 12:56:47 +08:00
|
|
|
<div class="pull-left table-name">
|
2018-09-18 11:40:43 +08:00
|
|
|
<% if defined? export_all and export_all %>
|
2021-06-08 20:21:34 +08:00
|
|
|
<% file_link = @obj_filenames.dig(:tables, table.id, :file) %>
|
|
|
|
<a href="<%= file_link %>">
|
2021-06-10 16:59:34 +08:00
|
|
|
<em>
|
|
|
|
<%= t('projects.reports.elements.step_table.table_name', name: file_link&.split('/')&.last) %>
|
|
|
|
</em>
|
2018-08-29 12:56:47 +08:00
|
|
|
</a>
|
|
|
|
<% else %>
|
2018-10-12 13:33:03 +08:00
|
|
|
<% if table.try(:name) %>
|
2021-06-10 16:59:34 +08:00
|
|
|
<em>
|
|
|
|
<%= t('projects.reports.elements.step_table.table_name', name: truncate(table.name, length: Constants::FILENAME_TRUNCATION_LENGTH)) %>
|
|
|
|
</em>
|
2018-08-29 12:56:47 +08:00
|
|
|
<% end %>
|
|
|
|
<% end %>
|
|
|
|
</div>
|
2016-02-12 23:52:43 +08:00
|
|
|
<div class="pull-left user-time">
|
2021-06-10 16:59:34 +08:00
|
|
|
<%= t('projects.reports.elements.step_table.user_time', timestamp: l(timestamp, format: :full)) %>
|
2016-02-12 23:52:43 +08:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="report-element-body">
|
2019-07-15 19:27:27 +08:00
|
|
|
<input type="hidden" class="hot-table-contents" value="<%= table.contents_utf_8 %>" />
|
|
|
|
<div class="hot-table-container"></div>
|
|
|
|
<table class="report-common-table-format"></table>
|
2016-02-12 23:52:43 +08:00
|
|
|
</div>
|
2021-05-20 20:16:39 +08:00
|
|
|
<% if defined?(children) %>
|
|
|
|
<div class="report-element-children">
|
|
|
|
<%= children %>
|
|
|
|
</div>
|
|
|
|
<% end %>
|
2016-08-01 19:19:19 +08:00
|
|
|
</div>
|