Added correct requires for monkeypatching to work

pull/6827/head
Sebastian Schuster 12 years ago
parent 183beae595
commit fd74ecabf7
  1. 1
      lib/open_project/reporting/engine.rb
  2. 5
      lib/widget/settings_patch.rb

@ -35,6 +35,7 @@ module OpenProject::Reporting
end
config.to_prepare do
require_dependency 'widget/settings_patch'
unless Redmine::Plugin.registered_plugins.include?(:openproject_reporting)
Redmine::Plugin.register :openproject_reporting do
name 'Reporting Plugin'

@ -1,4 +1,9 @@
#explicitly require what will be patched to be loaded from the ReportingEngine
require_dependency 'widget/settings'
class Widget::Settings < Widget::Base
#make sure this patch gets unloaded as it does not fit
#the standard rails path
unloadable
@@settings_to_render.insert -2, :cost_types

Loading…
Cancel
Save