redmine_dmsf/app/views/dmsf/show.html.erb

75 lines
2.9 KiB
Plaintext

<%
# encoding: utf-8
#
# Redmine plugin for Document Management System "Features"
#
# Copyright © 2011 Vít Jonáš <vit.jonas@gmail.com>
# Copyright © 2012 Daniel Munn <dan.munn@munnster.co.uk>
# Copyright © 2011-20 Karel Pičman <karel.picman@kontron.com>
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
%>
<% html_title l(:dmsf) %>
<div class="contextual">
<% if @file_manipulation_allowed && !@locked_for_user && !@system_folder %>
<%= link_to l(:label_attachment_new), multi_dmsf_upload_path(id: @project, folder_id: @folder),
class: 'icon icon-add' %>
<% end %>
<% if defined?(EasyExtensions) %>
<%= render partial: 'dmsf_context_menus/main', locals: {
folder_manipulation_allowed: @folder_manipulation_allowed,
system_folder: @system_folder,
folder: @folder,
project: @project,
locked_for_user: @locked_for_user,
file_manipulation_allowed: @file_manipulation_allowed,
trash_enabled: @trash_enabled } %>
<% else %>
<%= actions_dropdown do %>
<%= render partial: 'dmsf_context_menus/main', locals: {
folder_manipulation_allowed: @folder_manipulation_allowed,
system_folder: @system_folder,
folder: @folder,
project: @project,
locked_for_user: @locked_for_user,
file_manipulation_allowed: @file_manipulation_allowed,
trash_enabled: @trash_enabled } %>
<% end %>
<% end %>
</div>
<%= render partial: 'path', locals: { folder: @folder, filename: nil, title: nil } %>
<div class="dmsf-header">
<div class="wiki">
<%= textilizable(@folder ? @folder.description : @project.dmsf_description) %>
</div>
</div>
<%= form_tag(dmsf_folder_path(d: @project, folder_id: @folder), method: :get, id: 'query_form') do %>
<%= render partial: 'queries/query_form' %>
<% end %>
<%= render partial: 'query_list', locals: { query: @query, dmsf_pages: @dmsf_pages } %>
<span class="pagination"><%= pagination_links_full @dmsf_pages, @dmsf_count %></span>
<%= context_menu %>
<% unless @folder && @folder.system %>
<% other_formats_links do |f| %>
<%= f.link_to 'CSV', url: { action: :show, id: @project, dmsf_folder_id: @folder } %>
<% end %>
<% end %>