54 lines
2.4 KiB
Plaintext
54 lines
2.4 KiB
Plaintext
<script src="https://kit.fontawesome.com/1fa49cfdc9.js" crossorigin="anonymous"></script>
|
|
<script>
|
|
function MergeUrl(){
|
|
location.href = '<%= merge_admin_patents_path %>'
|
|
}
|
|
</script>
|
|
<table class="table main-list">
|
|
<thead>
|
|
<tr>
|
|
<th class="span1"><%= t('personal_patent.publication_date') %></th>
|
|
<th class="span2"><%= t('personal_patent.patent_title') %></th>
|
|
<th class="span2"><%= t('personal_patent.patent_no') %></th>
|
|
<th class="span2"><%= t('personal_patent.patent_country') %></th>
|
|
<th class="span2"><%= t('personal_patent.authors') %></th>
|
|
</tr>
|
|
</thead>
|
|
<tbody id="tbody_patents" class="sort-holder">
|
|
<%= render 'patent' %>
|
|
</tbody>
|
|
</table>
|
|
|
|
<div class="bottomnav clearfix">
|
|
<div class="action pull-right">
|
|
<div class="dropup upload-button">
|
|
<button class="btn btn-primary" type="button" onclick="MergeUrl()">
|
|
<i class="far fa-object-group"></i>
|
|
<span class="group"></span><%= t('personal_patent.merge') %>
|
|
</button>
|
|
<button class="btn btn-primary dropdown-toggle" type="button" data-toggle="dropdown">
|
|
<i class="icon-upload-alt icon-white"></i><%= t('personal_patent.upload') %>
|
|
<span class="caret"></span>
|
|
</button>
|
|
<div class="dropdown-menu upload-box">
|
|
<form action="/admin/patents/import_from_excel" method="post" enctype="multipart/form-data">
|
|
<%= hidden_field_tag :authenticity_token, form_authenticity_token %>
|
|
<input type="file" name="import_file" >
|
|
<button class="btn btn-primary" type="submit"><%= t(:submit) %></button>
|
|
<a class="" href="/admin/patents/download_excel_format.xlsx">Download excel format</a>
|
|
</form>
|
|
</div>
|
|
</div>
|
|
<%= link_to content_tag(:i, nil, :class => 'icon-plus icon-white') + t(:new_), new_admin_patent_path, :class => 'btn btn-primary' %>
|
|
<%= link_to content_tag(:i, nil, :class => 'icon-cog icon-white') + t('setting'), admin_patent_setting_path, :class => 'btn btn-primary pull-right' %>
|
|
</div>
|
|
<div class="pagination pagination-centered">
|
|
<%= content_tag :div, paginate(@patents), class: "pagination pagination-centered" %>
|
|
</div>
|
|
</div>
|
|
<% if params[:error] == "1" %>
|
|
<script type="text/javascript">
|
|
alert("File cannot be imported. File has more than 500 entries. Please seperate the entries in different files.");
|
|
window.location.href = "<%= admin_patents_url %>"
|
|
</script>
|
|
<% end %> |