From 86b4f58026c7f983b362ea4a892cc2bf45621d5e Mon Sep 17 00:00:00 2001 From: Eric Davis Date: Wed, 7 Jul 2010 12:28:56 -0700 Subject: [PATCH] Move rails/init.rb into init.rb --- init.rb | 42 +++++++++++++++++++++++++++++++++++++++++- rails/init.rb | 42 +----------------------------------------- 2 files changed, 42 insertions(+), 42 deletions(-) diff --git a/init.rb b/init.rb index 7c16c46..ce0bb3f 100644 --- a/init.rb +++ b/init.rb @@ -1 +1,41 @@ -require File.dirname(__FILE__) + "/rails/init" +require 'redmine' + +# Patches to the Redmine core. +require 'dispatcher' +require 'overhead_deliverable_patch' +require 'overhead_hourly_deliverable_patch' +require 'overhead_fixed_deliverable_patch' +require 'overhead_issue_patch' +require 'overhead_time_entry_patch' +require 'overhead_time_entry_activity_patch' +Dispatcher.to_prepare do + Deliverable.send(:include, OverheadDeliverablePatch) + HourlyDeliverable.send(:include, OverheadHourlyDeliverablePatch) + FixedDeliverable.send(:include, OverheadFixedDeliverablePatch) + Issue.send(:include, OverheadIssuePatch) + TimeEntry.send(:include, OverheadTimeEntryPatch) + TimeEntryActivity.send(:include, OverheadTimeEntryActivityPatch) +end + +require 'overhead_budget_hook' +require 'overhead_issue_hook' +require 'overhead_timesheet_hook' + +Redmine::Plugin.register :redmine_overhead do + name 'Overhead plugin' + author 'Eric Davis' + description 'Overhead is a plugin that can be used to group Time Entry Activities into billable and overhead groups' + url 'https://projects.littlestreamsoftware.com/projects/redmine-overhead' + author_url 'http://www.littlestreamsoftware.com' + version '0.1.0' + + requires_redmine :version_or_higher => '0.8.0' + + + settings :default => { + 'custom_field' => nil, + 'billable_value' => nil, + 'overhead_value' => nil + }, :partial => 'settings/overhead_settings' + +end diff --git a/rails/init.rb b/rails/init.rb index ce0bb3f..48087f0 100644 --- a/rails/init.rb +++ b/rails/init.rb @@ -1,41 +1 @@ -require 'redmine' - -# Patches to the Redmine core. -require 'dispatcher' -require 'overhead_deliverable_patch' -require 'overhead_hourly_deliverable_patch' -require 'overhead_fixed_deliverable_patch' -require 'overhead_issue_patch' -require 'overhead_time_entry_patch' -require 'overhead_time_entry_activity_patch' -Dispatcher.to_prepare do - Deliverable.send(:include, OverheadDeliverablePatch) - HourlyDeliverable.send(:include, OverheadHourlyDeliverablePatch) - FixedDeliverable.send(:include, OverheadFixedDeliverablePatch) - Issue.send(:include, OverheadIssuePatch) - TimeEntry.send(:include, OverheadTimeEntryPatch) - TimeEntryActivity.send(:include, OverheadTimeEntryActivityPatch) -end - -require 'overhead_budget_hook' -require 'overhead_issue_hook' -require 'overhead_timesheet_hook' - -Redmine::Plugin.register :redmine_overhead do - name 'Overhead plugin' - author 'Eric Davis' - description 'Overhead is a plugin that can be used to group Time Entry Activities into billable and overhead groups' - url 'https://projects.littlestreamsoftware.com/projects/redmine-overhead' - author_url 'http://www.littlestreamsoftware.com' - version '0.1.0' - - requires_redmine :version_or_higher => '0.8.0' - - - settings :default => { - 'custom_field' => nil, - 'billable_value' => nil, - 'overhead_value' => nil - }, :partial => 'settings/overhead_settings' - -end +require File.dirname(__FILE__) + "/../init"