2023-08-21 22:07:38 +08:00
|
|
|
<div class="text-3xl font-semibold flex flex-row flex-nowrap">
|
|
|
|
<span class="inline-block whitespace-nowrap mr-1">
|
|
|
|
</span>
|
|
|
|
<span class="inline-block truncate module-name" title="<%= @my_module.name %>">
|
|
|
|
<%= @my_module.name %>
|
|
|
|
</span>
|
|
|
|
</div>
|
2023-08-07 16:45:52 +08:00
|
|
|
|
2023-10-10 20:22:48 +08:00
|
|
|
<div class="my-5 flex-1">
|
|
|
|
<div class="content-pane with-grey-background flexible">
|
2023-08-07 16:45:52 +08:00
|
|
|
<%= render partial: 'shareable_links/my_modules/header_actions' %>
|
2023-10-10 20:22:48 +08:00
|
|
|
<div>
|
|
|
|
<div class="my-4 p-3 bg-sn-white" id="results-toolbar">
|
|
|
|
<div class="flex items-center gap-4 collapse-expand-result">
|
|
|
|
<button class="btn btn-secondary" id="results-collapse-btn">
|
|
|
|
<span><%= t'my_modules.results.collapse_label' %></span>
|
2023-08-21 22:07:38 +08:00
|
|
|
</button>
|
2023-10-10 20:22:48 +08:00
|
|
|
<button class="btn btn-secondary" id="results-expand-btn">
|
|
|
|
<span><%= t'my_modules.results.expand_label' %></span>
|
2023-08-21 22:07:38 +08:00
|
|
|
</button>
|
|
|
|
</div>
|
|
|
|
<div class="sort-result-dropdown dropdown">
|
|
|
|
<button id="sort-result-button" class="btn btn-light icon-btn" data-toggle="dropdown" aria-haspopup="true" aria-expanded="true">
|
2023-10-10 20:22:48 +08:00
|
|
|
<i class="sn-icon sn-icon-sort"></i>
|
2023-08-21 22:07:38 +08:00
|
|
|
</button>
|
|
|
|
<ul class="dropdown-menu dropdown-menu-right" aria-labelledby="sort-result-button">
|
|
|
|
<li><%= link_to t('general.sort_new.atoz'), shared_protocol_results_path(@shareable_link.uuid, page: params[:page], order: 'atoz'), class: (@results_order == 'atoz' ? 'selected' : '') %></li>
|
|
|
|
<li><%= link_to t('general.sort_new.ztoa'), shared_protocol_results_path(@shareable_link.uuid, page: params[:page], order: 'ztoa'), class: (@results_order == 'ztoa' ? 'selected' : '') %></li>
|
|
|
|
<li><%= link_to t('general.sort_new.old'), shared_protocol_results_path(@shareable_link.uuid, page: params[:page], order: 'old'), class: (@results_order == 'old' ? 'selected' : '') %></li>
|
|
|
|
<li><%= link_to t('general.sort_new.new'), shared_protocol_results_path(@shareable_link.uuid, page: params[:page], order: 'new'), class: (@results_order == 'new' ? 'selected' : '') %></li>
|
|
|
|
<li><%= link_to t('general.sort_new.old_updated'), shared_protocol_results_path(@shareable_link.uuid, page: params[:page], order: 'old_updated'), class: (@results_order == 'old_updated' ? 'selected' : '') %></li>
|
|
|
|
<li><%= link_to t('general.sort_new.new_updated'), shared_protocol_results_path(@shareable_link.uuid, page: params[:page], order: 'new_updated'), class: (@results_order == 'new_updated' ? 'selected' : '') %></li>
|
|
|
|
</ul>
|
|
|
|
</div>
|
2023-08-07 16:45:52 +08:00
|
|
|
</div>
|
2023-08-21 22:07:38 +08:00
|
|
|
<div id="results">
|
|
|
|
<% @results.each do |result| %>
|
|
|
|
<%= render partial: "shareable_links/my_modules/results/result", locals: { result: result, gallery: @gallery } %>
|
2023-10-10 20:22:48 +08:00
|
|
|
<%= render partial: "shareable_links/my_modules/result_comments_sidebar", locals: { result: result } %>
|
2023-08-21 22:07:38 +08:00
|
|
|
<% end %>
|
|
|
|
</div>
|
|
|
|
<div class="kaminari-pagination">
|
|
|
|
<%= paginate @results, outer_window: 1, window: 1 %>
|
2023-08-07 16:45:52 +08:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<%= javascript_include_tag "handsontable.full" %>
|
|
|
|
<%= render 'shared/formulas_libraries' %>
|
|
|
|
<%= javascript_include_tag 'shareable_links/my_module_results_show' %>
|
|
|
|
|
|
|
|
<%= javascript_include_tag 'shared/file_preview' %>
|
|
|
|
<%= javascript_include_tag 'pdf_js' %>
|
|
|
|
<%= stylesheet_link_tag 'pdf_js_styles' %>
|