public
Description: This plugin will let you enter timelogs in bulk
Homepage: https://projects.littlestreamsoftware.com/projects/show/redmine-bte
Clone URL: git://github.com/edavis10/redmine-bulk_time_entry_plugin.git
redmine-bulk_time_entry_plugin / lib / bulk_time_entry_compatibility.rb
100644 15 lines (14 sloc) 0.436 kb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
# Wrappers around the Redmine core API changes between versions
module BulkTimeEntryCompatibility
  class Enumeration
    # Wrapper around Redmine's API since Enumerations changed in r2472
    # This can be removed once 0.9.0 is stable
    def self.activities
      if ::Enumeration.respond_to?(:activities)
        return ::Enumeration.activities
      else
        return ::Enumeration::get_values('ACTI')
      end
    end
  end
end