2016-08-08 21:04:02 +08:00
|
|
|
<div class="panel panel-default panel-archive">
|
|
|
|
|
|
|
|
<div class="panel-heading">
|
|
|
|
|
|
|
|
<div class="dropdown pull-right">
|
|
|
|
<button class="btn btn-link dropdown-toggle" type="button" id="dropdownMenu1" data-toggle="dropdown" aria-haspopup="true" aria-expanded="true">
|
|
|
|
<span class="caret"></span>
|
|
|
|
</button>
|
|
|
|
<% my_module_form = nil %>
|
|
|
|
<%= form_for my_module, method: :patch, format: :html do |f| %>
|
|
|
|
<% my_module_form = f %>
|
|
|
|
<%= f.hidden_field :archived, value: false %>
|
|
|
|
<% end %>
|
|
|
|
<ul class="dropdown-menu dropdown-menu-right" aria-labelledby="dropdownMenu1">
|
2021-09-14 17:08:35 +08:00
|
|
|
<% if can_restore_my_module?(my_module) %>
|
2018-07-19 23:56:42 +08:00
|
|
|
<li><a href="#" class="form-submit-link" data-turbolinks="false" data-submit-form="<%= my_module_form.options[:html][:id] %>"><%= t "experiments.module_archive.restore_option" %></a></li>
|
2016-08-08 21:04:02 +08:00
|
|
|
<% end %>
|
|
|
|
</ul>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<h3 class="panel-title"><%= my_module.name %></h3>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="panel-body">
|
2020-12-13 05:46:30 +08:00
|
|
|
<% if my_module.archived? %>
|
|
|
|
<div class="row">
|
|
|
|
<div class="col-xs-6">
|
|
|
|
<%=t "experiments.module_archive.archived_on" %>
|
|
|
|
</div>
|
|
|
|
<div class="col-xs-6">
|
|
|
|
<span title="<%=t "experiments.module_archive.archived_on_title", date: l(my_module.archived_on, format: :full_date), time: l(my_module.archived_on, format: :time) %>">
|
|
|
|
<%= l(my_module.archived_on, format: :full_date) %>
|
|
|
|
</span>
|
|
|
|
</div>
|
2016-08-08 21:04:02 +08:00
|
|
|
</div>
|
2020-12-13 05:46:30 +08:00
|
|
|
<% end %>
|
2016-08-08 21:04:02 +08:00
|
|
|
</div>
|
|
|
|
|
|
|
|
</div>
|