mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-03-03 11:13:06 +08:00
Remove projects archive page
This commit is contained in:
parent
4730e7bfee
commit
2db39c049e
4 changed files with 0 additions and 119 deletions
|
@ -1,54 +0,0 @@
|
||||||
<% provide(:head_title, t("projects.archive.head_title")) %>
|
|
||||||
<%= render partial: "shared/sidebar", locals: { page: 'project' } %>
|
|
||||||
<%= render partial: "shared/secondary_navigation" %>
|
|
||||||
|
|
||||||
<div class="content-pane" id="project-archive">
|
|
||||||
<% if @archived_projects_by_teams.length > 0 %>
|
|
||||||
<div id="projects-toolbar">
|
|
||||||
|
|
||||||
<form class="form-inline" action="<%= projects_archive_path %>">
|
|
||||||
|
|
||||||
<div class="form-group">
|
|
||||||
<!-- project sort -->
|
|
||||||
<div class="dropdown">
|
|
||||||
<button class="btn btn-default dropdown-toggle" type="button" id="sortMenu" data-toggle="dropdown" aria-haspopup="true" aria-expanded="true">
|
|
||||||
<span class="hidden-xs"><%= t'projects.index.sort' %></span>
|
|
||||||
<span class="visible-xs-inline"><i class="fas fa-sort"></i></span>
|
|
||||||
<span class="caret"></span>
|
|
||||||
</button>
|
|
||||||
<ul class="dropdown-menu" aria-labelledby="sortMenu">
|
|
||||||
<% ["new", "old", "atoz", "ztoa"].each do |sort| %>
|
|
||||||
<% if @current_sort != sort %>
|
|
||||||
<li><a href="?<%= {team: @current_team.id, sort: sort}.reject{|k,v| v.to_s == "0"}.to_query %>"><%= t('projects.index.sort_' + sort) %></a></li>
|
|
||||||
<% else %>
|
|
||||||
<li class="disabled"><a href="#"><%= t('projects.index.sort_' + sort) %></a></li>
|
|
||||||
<% end %>
|
|
||||||
<% end %>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<% @archived_projects_by_teams.each do |team, projects| %>
|
|
||||||
<%= render partial: 'projects/archive/team_projects',
|
|
||||||
locals: {team: team, projects: projects} %>
|
|
||||||
<% end %>
|
|
||||||
<% else %>
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-xs-12">
|
|
||||||
<h4><%=t "projects.index.no_archived_projects" %></h4>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
<div class="col-xs-12">
|
|
||||||
<%= link_to t("projects.index.back_to_projects_index"), projects_path %>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<!-- Some spacing... -->
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-xs-12" style="height: 30px;"></div>
|
|
||||||
</div>
|
|
||||||
<% end %>
|
|
||||||
</div>
|
|
|
@ -1,46 +0,0 @@
|
||||||
<div class="panel panel-default panel-project panel-archive">
|
|
||||||
<div class="panel-heading">
|
|
||||||
<% if can_restore_project?(project) %>
|
|
||||||
<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>
|
|
||||||
<% project_form = nil %>
|
|
||||||
<%= form_for project, method: :patch, format: :html do |f| %>
|
|
||||||
<% project_form = f %>
|
|
||||||
<%= f.hidden_field :archived, value: false %>
|
|
||||||
<% end %>
|
|
||||||
<ul class="dropdown-menu dropdown-menu-right" aria-labelledby="dropdownMenu1">
|
|
||||||
<li class="dropdown-header"><%= t('projects.index.options_header') %></li>
|
|
||||||
<li><a href="#"
|
|
||||||
class="form-submit-link"
|
|
||||||
data-turbolinks="false"
|
|
||||||
data-submit-form="<%= project_form.options[:html][:id] %>"><%= t 'projects.index.restore_option' %></a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
<% end %>
|
|
||||||
|
|
||||||
<h3 class="panel-title">
|
|
||||||
<% if project.hidden? then %>
|
|
||||||
<span class="fas fa-eye-slash" aria-hidden="true" title="<%=t "projects.index.visibility_private" %>"></span>
|
|
||||||
<% else %>
|
|
||||||
<span class="fas fa-eye" aria-hidden="true" title="<%=t "projects.index.visibility_public" %>"></span>
|
|
||||||
<% end %>
|
|
||||||
<span><%= project.name %></span>
|
|
||||||
</h3>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="panel-body">
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-xs-6"><%= t('projects.index.start_date') %></div>
|
|
||||||
<div class="col-xs-6">
|
|
||||||
<%=l project.created_at, format: :full_date %>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
|
@ -1,16 +0,0 @@
|
||||||
<div class="row">
|
|
||||||
<% projects.each_index do |i| project = projects[i] %>
|
|
||||||
<div class="col-lg-3 col-md-4 col-sm-6 col-xs-12">
|
|
||||||
<%= render partial: "projects/archive/project", locals: { project: project } %>
|
|
||||||
</div>
|
|
||||||
<% if (i+1) % 4 == 0 %>
|
|
||||||
<div class="clearfix visible-lg-block"></div>
|
|
||||||
<% end %>
|
|
||||||
<% if (i+1) % 3 == 0 %>
|
|
||||||
<div class="clearfix visible-md-block"></div>
|
|
||||||
<% end %>
|
|
||||||
<% if (i+1) % 2 == 0 %>
|
|
||||||
<div class="clearfix visible-sm-block"></div>
|
|
||||||
<% end %>
|
|
||||||
<% end %>
|
|
||||||
</div>
|
|
|
@ -281,8 +281,6 @@ en:
|
||||||
options_header: "Options"
|
options_header: "Options"
|
||||||
comment_placeholder: "Your Message"
|
comment_placeholder: "Your Message"
|
||||||
more_comments: "More Comments"
|
more_comments: "More Comments"
|
||||||
no_archived_projects: "No archived projects!"
|
|
||||||
back_to_projects_index: "Back to home"
|
|
||||||
modal_new_project:
|
modal_new_project:
|
||||||
modal_title: "Create new project"
|
modal_title: "Create new project"
|
||||||
create: "Create"
|
create: "Create"
|
||||||
|
@ -331,7 +329,6 @@ en:
|
||||||
success_flash: "Project <strong>%{name}</strong> successfully updated."
|
success_flash: "Project <strong>%{name}</strong> successfully updated."
|
||||||
error_flash: "Project <strong>%{name}</strong> not updated."
|
error_flash: "Project <strong>%{name}</strong> not updated."
|
||||||
archive:
|
archive:
|
||||||
head_title: "Projects Archive"
|
|
||||||
success_flash: "Project <strong>%{name}</strong> successfully archived."
|
success_flash: "Project <strong>%{name}</strong> successfully archived."
|
||||||
error_flash: "Project <strong>%{name}</strong> not archived."
|
error_flash: "Project <strong>%{name}</strong> not archived."
|
||||||
restore:
|
restore:
|
||||||
|
|
Loading…
Reference in a new issue