-
Notifications
You must be signed in to change notification settings - Fork 29
/
init.rb
59 lines (50 loc) · 2.35 KB
/
init.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
# This file is a part of Redmin Agile (redmine_agile) plugin,
# Agile board plugin for redmine
#
# Copyright (C) 2011-2015 RedmineCRM
# http://www.redminecrm.com/
#
# redmine_agile is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# redmine_agile is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with redmine_agile. If not, see <http://www.gnu.org/licenses/>.
require 'redmine'
AGILE_VERSION_NUMBER = '1.3.12'
AGILE_VERSION_TYPE = "Light version"
Redmine::Plugin.register :redmine_agile do
name "Redmine Agile plugin (#{AGILE_VERSION_TYPE})"
author 'RedmineCRM'
description 'Scrum and Agile project management plugin for redmine'
version AGILE_VERSION_NUMBER
url 'http://redminecrm.com'
author_url 'mailto:[email protected]'
requires_redmine :version_or_higher => '2.3'
settings :default => {
'issues_per_column' => "10",
'default_columns' => %w(tracker assigned_to)
},
:partial => 'settings/agile/general'
menu :project_menu, :agile, {:controller => 'agile_boards', :action => 'index' },
:caption => :label_agile,
:after => :gantt,
:param => :project_id
menu :admin_menu, :agile, {:controller => 'settings', :action => 'plugin', :id => "redmine_agile"}, :caption => :label_agile
project_module :agile do
permission :manage_public_agile_queries, {:agile_queries => [:new, :create, :edit, :update, :destroy]}, :require => :member
permission :manage_agile_verions, {:agile_versions => [:index, :update]}
permission :add_agile_queries, {:agile_queries => [:new, :create, :edit, :update, :destroy]}, :require => :loggedin
permission :view_agile_queries, {:agile_boards => [:index], :agile_queries => :index}
permission :view_agile_charts, {:agile_charts => [:show, :render_chart, :select_version_chart]}
end
end
ActionDispatch::Callbacks.to_prepare do
require 'redmine_agile'
end