I am trying to run Time Tracker plugin with Redmine 2.0.1 on Bitnami Stack.
I found that it's imcompatible with Redmine 2.* but it couldn't stop me.
So, I placed this plugin in ../redmine/htdocs/plugins/redmine_time_tracker
, migrated it with rake db:migrate_plugins RAILS_ENV=production
, changed routes to Rails 3 style in redmine_time_tracker/config/routes.rb
and renamed all files in redmine_time_tracker/app/views
from *.rhtml to *.html.erb. After another Redmine's restart I rested against the wall. There is an error message in Redmine's production.log:
Started GET "/redmine" for 127.0.0.1 at Tue Jun 12 22:36:05 +0400 2012
Processing by WelcomeController#index as HTML
Rendered welcome/index.html.erb within layouts/base (9.5ms)
Rendered plugins/redmine_time_tracker/app/views/time_trackers/_embed_menu.html.erb (203.0ms)
Rendered plugins/redmine_time_tracker/app/views/time_trackers/_update_menu.html.erb (203.5ms)
Completed 500 Internal Server Error in 252ms
ActionView::Template::Error (undefined method `time_tracker_for' for #<#<Class:0x7f5efb458e48>:0x7f5efb322290>):
1: <% time_tracker = time_tracker_for(User.current) %>
2: <% if !time_tracker.nil? %>
3: <% if time_tracker.paused %>
4: <%# A time tracker is in pause, display the tracked issue, the time spent and the resume/stop actions %>
lib/redmine/hook.rb:110:in `send'
lib/redmine/hook.rb:110:in `view_layouts_base_body_bottom'
lib/redmine/hook.rb:61:in `send'
lib/redmine/hook.rb:61:in `call_hook'
lib/redmine/hook.rb:61:in `each'
lib/redmine/hook.rb:61:in `call_hook'
lib/redmine/hook.rb:58:in `tap'
lib/redmine/hook.rb:58:in `call_hook'
lib/redmine/hook.rb:151:in `call_hook'
app/views/layouts/base.html.erb:80:in `_app_views_layouts_base_html_erb___1317325009_70022959536540'
time_tracker_for
helper is placed in redmine_time_tracker/app/helpers/application_helper.rb
and I think it should be loaded automatically according to "Plugin constructor" in redmine/htdocs/lib/redmine/plugin.rb
.
I am new to Ruby and Rails and need some directions to continue fight this magic.