diff --git a/config/locales/en.yml b/config/locales/en.yml index 33190f3..04cfca7 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -80,4 +80,6 @@ en: label_load_customer: "Load Customer" label_door: "Door" label_trim: "Trim" + label_bill_time: "Bill Time" + label_share: "Share" \ No newline at end of file diff --git a/lib/issues_show_hook_listener.rb b/lib/issues_show_hook_listener.rb index 9b159f0..5b5ea15 100644 --- a/lib/issues_show_hook_listener.rb +++ b/lib/issues_show_hook_listener.rb @@ -60,9 +60,10 @@ class IssuesShowHookListener < Redmine::Hook::ViewListener }) end + # Display Buttons under the issue above subtasks def view_issues_show_description_bottom(context={}) - bill_button = button_to "Bill Time", bill_path( context[:issue].id ), method: :get if User.current.admin? - share_button = button_to "Share", share_path( context[:issue].id ), method: :get if User.current.logged? + bill_button = button_to I18n.t(:label_bill_time), bill_path( context[:issue].id ), method: :get if User.current.admin? + share_button = button_to I18n.t(:label_share), share_path( context[:issue].id ), method: :get if User.current.logged? return "
#{bill_button} #{share_button}" end