mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2024-11-11 01:44:34 +08:00
23 lines
932 B
Text
23 lines
932 B
Text
<div class="modal-header">
|
|
<span class="file-name"><%= report.name %></span>
|
|
<div class="sci-btn-group">
|
|
<a class="btn btn-light file-download-link" href="<%= rails_blob_path(report_type == 'docx' ? report.docx_file : report.pdf_file, disposition: 'attachment') %>" data-turbolinks="false">
|
|
<span class="fas fa-download"></span> <%= t('Download')%>
|
|
</a>
|
|
<button type="button" class="btn icon-btn btn-light" data-dismiss="modal"><span class="fas fa-times"></span></button>
|
|
</div>
|
|
</div>
|
|
<div class="modal-body">
|
|
<div class="file-preview-container">
|
|
<% if report_type == 'pdf' %>
|
|
<%= render partial: 'shared/pdf_viewer.html.erb', locals: { asset: report.pdf_file, report_document: true } %>
|
|
<% else %>
|
|
<div>
|
|
<i class="fas fa-10x fa-file-word"></i>
|
|
<h3 class="file-name"><%= report.name %></h3>
|
|
</div>
|
|
<% end %>
|
|
</div>
|
|
</div>
|
|
<div class="modal-footer">
|
|
</div>
|