Easy icons

This commit is contained in:
Karel Pičman 2023-10-25 15:02:17 +02:00
parent b005bf8d50
commit 8b7f158951
3 changed files with 7 additions and 5 deletions

View File

@ -48,11 +48,11 @@
</p>
</div>
<p>
<%= submit_tag l(:button_copy), id: 'copy_button' %>
<%= submit_tag l(:button_copy), id: 'copy_button', data: { cy: "button__copy--dmsf" } %>
<%# TODO: Lock and proper permissions %>
<% if User.current.allowed_to?(:folder_manipulation, @project) &&
User.current.allowed_to?(:file_manipulation, @project)%>
<%= submit_tag l(:button_move), id: 'move_button' %>
<%= submit_tag l(:button_move), id: 'move_button', data: { cy: "button__move--dmsf" } %>
<% end %>
</p>
<% end %>

View File

@ -76,7 +76,7 @@
<li>
<%= context_menu_link l(:field_mail), entries_operations_dmsf_path(id: project, folder_id: folder,
ids: params[:ids], email_entries: true, back_url: back_url), method: :post, class: 'icon icon-email',
disabled: !email_allowed %>
data: { cy: "icon__email--dmsf_file_#{dmsf_file.id}" }, disabled: !email_allowed %>
</li>
<% if Setting.plugin_redmine_dmsf['dmsf_webdav'].present? %>
<li>

View File

@ -21,7 +21,9 @@
%>
<div class="box tabular">
<strong><%= l(:heading_new_revision) %> <a href="#" id="new_revision_form_content_toggle">[+]</a></strong>
<strong><%= l(:heading_new_revision) %>
<a href="#" id="new_revision_form_content_toggle" data-cy="toggle__new_revision_from_content--dmsf">[+]</a>
</strong>
<div id="new_revision_form_content">
<% if @file.locked_for_user? %>
<p class="warning"><%= l(:info_file_locked) %></p>
@ -75,7 +77,7 @@
<%= f.text_area :comment, rows: 2, label: l(:label_comment), class: 'wiki-edit dmsf-description' %>
</p>
<div class="form-actions">
<%= f.submit l(:button_create), class: 'button-positive' %>
<%= f.submit l(:button_create), class: 'button-positive', data: { cy: "button__submit--file_dmsf"} %>
</div>
<% end %>
<% end %>