2020-11-04 23:10:40 +08:00
|
|
|
<div id="projectsToolbar" class="projects-toolbar">
|
2020-12-29 05:49:52 +08:00
|
|
|
<div class="form-inline">
|
2020-12-30 01:38:59 +08:00
|
|
|
<div class="project-actions">
|
2020-12-29 05:49:52 +08:00
|
|
|
<!-- new project button -->
|
|
|
|
<% if current_team && can_create_projects?(current_team) %>
|
2021-01-19 18:28:59 +08:00
|
|
|
<%= link_to new_project_path(project_folder_id: current_folder),
|
2020-12-29 05:49:52 +08:00
|
|
|
class: 'btn btn-primary new-project-btn',
|
2021-01-10 04:27:19 +08:00
|
|
|
data: { view_mode: 'active' },
|
2020-12-29 05:49:52 +08:00
|
|
|
remote: true do %>
|
|
|
|
<span class="fas fa-plus" aria-hidden="true"></span>
|
|
|
|
<span class="hidden-xs"><%= t('projects.index.new') %></span>
|
2020-12-01 16:59:08 +08:00
|
|
|
<% end %>
|
2020-12-29 05:49:52 +08:00
|
|
|
<% end %>
|
|
|
|
<!-- new project folder button -->
|
|
|
|
<% if current_team && can_create_project_folders?(current_team) %>
|
2021-01-19 18:28:59 +08:00
|
|
|
<%= link_to new_project_folder_path(project_folder_id: current_folder, view_mode: projects_view_mode),
|
2021-01-06 18:13:28 +08:00
|
|
|
class: 'btn btn-light new-project-folder-btn',
|
2020-12-29 05:49:52 +08:00
|
|
|
remote: true do %>
|
|
|
|
<span class="fas fa-folder" aria-hidden="true"></span>
|
|
|
|
<span class="hidden-xs"><%= t('projects.index.new_folder') %></span>
|
2020-11-02 20:27:06 +08:00
|
|
|
<% end %>
|
2020-12-29 05:49:52 +08:00
|
|
|
<% end %>
|
2021-01-19 18:22:53 +08:00
|
|
|
<a href="#" class="btn btn-light edit-btn single-object-action hidden" data-for="editable">
|
2021-01-29 05:47:08 +08:00
|
|
|
<span class="fas fa-pencil-alt" aria-hidden="true"></span>
|
2020-12-29 05:49:52 +08:00
|
|
|
<span class="hidden-xs"><%= t('projects.index.edit_button') %></span>
|
|
|
|
</a>
|
2021-01-15 20:49:36 +08:00
|
|
|
<a href="#" class="btn btn-light move-projects-btn multiple-object-action hidden" data-for="moveable" data-url="<%= move_to_modal_project_folders_url %>">
|
2020-12-29 05:49:52 +08:00
|
|
|
<span class="fas fa-arrow-right" aria-hidden="true"></span>
|
|
|
|
<span class="hidden-xs"><%= t('projects.index.move_button') %></span>
|
|
|
|
</a>
|
|
|
|
<%= button_to archive_group_projects_path,
|
2021-01-06 18:13:28 +08:00
|
|
|
class: 'btn btn-light archive-projects-btn multiple-object-action project-only-action hidden',
|
2020-12-29 05:49:52 +08:00
|
|
|
form_class: 'archive-projects-form',
|
2021-01-10 04:27:19 +08:00
|
|
|
data: { for: :archivable, view_mode: 'active' },
|
2020-12-29 05:49:52 +08:00
|
|
|
remote: true,
|
|
|
|
method: :post do %>
|
|
|
|
<span class="fas fa-archive" aria-hidden="true"></span>
|
|
|
|
<span class="hidden-xs"><%= t('projects.index.archive_button') %></span>
|
|
|
|
<% end %>
|
2021-01-10 04:27:19 +08:00
|
|
|
<%= button_to restore_group_projects_path,
|
|
|
|
class: 'btn btn-light restore-projects-btn multiple-object-action project-only-action hidden',
|
|
|
|
form_class: 'restore-projects-form',
|
|
|
|
data: { for: :restorable, view_mode: 'archived' },
|
|
|
|
remote: true,
|
|
|
|
method: :post do %>
|
|
|
|
<span class="fas fa-undo" aria-hidden="true"></span>
|
|
|
|
<span class="hidden-xs"><%= t('projects.index.restore_button') %></span>
|
|
|
|
<% end %>
|
2021-02-12 01:27:16 +08:00
|
|
|
<%= button_to destroy_modal_project_folders_url,
|
|
|
|
class: 'btn btn-light multiple-object-action folders-only-action hidden',
|
|
|
|
form_class: 'delete-folders-btn',
|
|
|
|
data: { for: :deletable },
|
|
|
|
remote: true,
|
|
|
|
method: :post do %>
|
2021-01-22 02:42:25 +08:00
|
|
|
<span class="fas fa-trash" aria-hidden="true"></span>
|
|
|
|
<span class="hidden-xs"><%= t('projects.index.delete_button') %></span>
|
|
|
|
<% end %>
|
2020-12-29 05:49:52 +08:00
|
|
|
<!-- export projects button -->
|
2021-01-06 18:13:28 +08:00
|
|
|
<a href="#" class="btn btn-light export-projects-btn multiple-object-action hidden"
|
2020-12-29 05:49:52 +08:00
|
|
|
data-export-projects-modal-url="<%= export_projects_modal_team_path(current_team) %>">
|
|
|
|
<span class="fas fa-file-export"></span>
|
|
|
|
<span class="hidden-xs-custom"><%= t('projects.export_projects.export_button') %></span>
|
|
|
|
</a>
|
2020-10-26 20:42:32 +08:00
|
|
|
</div>
|
2020-12-29 05:49:52 +08:00
|
|
|
</div>
|
2020-10-26 20:42:32 +08:00
|
|
|
</div>
|