Problems with context menu in Easy
This commit is contained in:
parent
cfa997c8b8
commit
afc81d3046
@ -22,6 +22,12 @@
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
%>
|
||||
|
||||
<% if defined?(EasyExtensions) %>
|
||||
<% content_for :header_tags do %>
|
||||
<%= javascript_include_tag 'context_menu', 'application', defer: true %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
|
||||
<% html_title l(:dmsf) %>
|
||||
<div class="contextual">
|
||||
<% if @file_manipulation_allowed && !@locked_for_user && !@system_folder %>
|
||||
|
||||
@ -20,6 +20,12 @@
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
%>
|
||||
|
||||
<% if defined?(EasyExtensions) %>
|
||||
<% content_for :header_tags do %>
|
||||
<%= javascript_include_tag 'context_menu', 'application', defer: true %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
|
||||
<% html_title l(:dmsf) %>
|
||||
|
||||
<h2><%= l(:link_trash_bin) %></h2>
|
||||
|
||||
@ -23,18 +23,14 @@ module RedmineDmsf
|
||||
include Redmine::Hook
|
||||
|
||||
class DmsfViewListener < Redmine::Hook::ViewListener
|
||||
|
||||
|
||||
def view_layouts_base_html_head(context={})
|
||||
return unless /^(Dmsf|Projects|Issues)/.match?(context[:controller].class.name)
|
||||
meta = "\n".html_safe + stylesheet_link_tag('redmine_dmsf.css', plugin: :redmine_dmsf) +
|
||||
return unless context[:controller].class.name.match?(/^(Dmsf|Projects)/)
|
||||
"\n".html_safe + stylesheet_link_tag('redmine_dmsf.css', plugin: :redmine_dmsf) +
|
||||
"\n".html_safe + stylesheet_link_tag('select2.min.css', plugin: :redmine_dmsf) +
|
||||
"\n".html_safe + javascript_include_tag('select2.min.js', plugin: :redmine_dmsf, defer: true) +
|
||||
"\n".html_safe + javascript_include_tag('redmine_dmsf.js', plugin: :redmine_dmsf, defer: true) +
|
||||
"\n".html_safe + javascript_include_tag('attachments_dmsf.js', plugin: :redmine_dmsf, defer: true)
|
||||
if defined?(EasyExtensions) && /^Dmsf/.match?(context[:controller].class.name)
|
||||
meta << "\n".html_safe + javascript_include_tag('context_menu', 'application', defer: true)
|
||||
end
|
||||
meta
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user