-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinit.rb
More file actions
24 lines (19 loc) · 754 Bytes
/
init.rb
File metadata and controls
24 lines (19 loc) · 754 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
require 'redmine'
require 'dispatcher'
require 'project_patch'
Redmine::Plugin.register :project_tagger do
name 'ProjectTagger'
author 'Krzysztof Kuźnik, Szymon Depta'
description 'Plugin provides tagging for Redmine projects'
version '1.0'
menu :admin_menu, :tags, { :controller => 'tags', :action => 'index' }, :caption => :tags_name
end
Dispatcher.to_prepare do
Project.send(:include, ProjectPatch)
end
# This class is for registering partials rendered in Redmine hooks
class ProjectTaggerHooks < Redmine::Hook::ViewListener
render_on :view_projects_form, :partial => "tags/tag_field"
render_on :view_projects_show_right, :partial => "tags/project_tags"
render_on :view_layouts_base_html_head, :partial => "tags/css_header"
end