summaryrefslogtreecommitdiffstats
path: root/app/views/projects
diff options
context:
space:
mode:
authorMarius Balteanu <marius.balteanu@zitec.com>2022-04-01 15:08:52 +0000
committerMarius Balteanu <marius.balteanu@zitec.com>2022-04-01 15:08:52 +0000
commit83ed32e8d71fdb8c6a7492a4d82db2d52889534d (patch)
tree3350f753132d7a1d34c7bd83e0c5a4b6fae5db36 /app/views/projects
parent44344cfe8a8693ade7ecd855d20c2ce8857dc302 (diff)
downloadredmine-83ed32e8d71fdb8c6a7492a4d82db2d52889534d.tar.gz
redmine-83ed32e8d71fdb8c6a7492a4d82db2d52889534d.zip
Reuse ProjectQuery filters on the admin project list (#33422).
Patch by Takenori TAKAKI. git-svn-id: https://svn.redmine.org/redmine/trunk@21519 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/views/projects')
-rw-r--r--app/views/projects/_list.html.erb14
1 files changed, 14 insertions, 0 deletions
diff --git a/app/views/projects/_list.html.erb b/app/views/projects/_list.html.erb
index 0abbc59e0..ba26e9d61 100644
--- a/app/views/projects/_list.html.erb
+++ b/app/views/projects/_list.html.erb
@@ -6,6 +6,9 @@
<% @query.inline_columns.each do |column| %>
<%= column_header(@query, column) %>
<% end %>
+ <% if controller_name == 'admin' && action_name == 'projects' %>
+ <th></th>
+ <% end %>
</tr>
</thead>
<tbody>
@@ -23,12 +26,23 @@
<%= link_to_function("#{l(:button_collapse_all)}/#{l(:button_expand_all)}",
"toggleAllRowGroups(this)", :class => 'toggle-all') %>
</td>
+ <% if controller_name == 'admin' && action_name == 'projects' %>
+ <td></td>
+ <% end %>
</tr>
<% end %>
<tr id="project-<%= entry.id %>" class="<%= cycle('odd', 'even') %> <%= entry.css_classes %> <%= level > 0 ? "idnt idnt-#{level}" : nil %>">
<% @query.inline_columns.each do |column| %>
<%= content_tag('td', column_content(column, entry), :class => column.css_classes) %>
<% end %>
+ <% if controller_name == 'admin' && action_name == 'projects' %>
+ <td class="buttons">
+ <%= link_to(l(:button_archive), archive_project_path(entry, :status => params[:status]), :data => {:confirm => l(:text_are_you_sure)}, :method => :post, :class => 'icon icon-lock') unless entry.archived? %>
+ <%= link_to(l(:button_unarchive), unarchive_project_path(entry, :status => params[:status]), :method => :post, :class => 'icon icon-unlock') if entry.archived? %>
+ <%= link_to(l(:button_copy), copy_project_path(entry), :class => 'icon icon-copy') %>
+ <%= link_to(l(:button_delete), project_path(entry), :method => :delete, :class => 'icon icon-del') %>
+ </td>
+ <% end %>
</tr>
<% end -%>
</tbody>