From ce868cfcf244ffb6536fc35e1b3fab72aebf27b9 Mon Sep 17 00:00:00 2001 From: Toru Takahashi Date: Sun, 13 May 2018 20:19:58 +0900 Subject: [PATCH] [phase-6]project menu --- config/locales/en.yml | 4 +++- config/locales/ja.yml | 1 + init.rb | 11 +++++++++++ 3 files changed, 15 insertions(+), 1 deletion(-) diff --git a/config/locales/en.yml b/config/locales/en.yml index adb138d..76087ed 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -5,4 +5,6 @@ en: label_glossary_term_new: "New glossary term" label_glossary_categories: "Glossary categories" label_glossary_category: "Glossary category" - label_glossary_category_new: "New glossary category" \ No newline at end of file + label_glossary_category_new: "New glossary category" + + glossary_title: Glossary \ No newline at end of file diff --git a/config/locales/ja.yml b/config/locales/ja.yml index 7b1ab05..e84965a 100644 --- a/config/locales/ja.yml +++ b/config/locales/ja.yml @@ -5,3 +5,4 @@ ja: label_glossary_categories: "用語のカテゴリ" label_glossary_category: "用語のカテゴリ" label_glossary_category_new: "カテゴリの作成" + glossary_title: 用語集 \ No newline at end of file diff --git a/init.rb b/init.rb index c9b8d71..64a28fc 100644 --- a/init.rb +++ b/init.rb @@ -5,4 +5,15 @@ Redmine::Plugin.register :redmine_glossary do version '1.0.1' url 'https://github.com/torutk/redmine_glossary' author_url 'http://www.torutk.com' + + + project_module :glossary do + permission :all_glossary, glossary_terms: :index + end + + menu :project_menu, :glossary, + { controller: :glossary_terms, action: :index }, + caption: :glossary_title, + param: :project_id + end