OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub
Ruby agile-developmentangularbcfboardsbug-trackerganttgantt-chartifcissue-trackerjira-alternativekanbanopenprojectproduct-managementproject-managementproject-planningroadmaprubyscrumtimelineworkflows
Add radio group to progress tracking form
Aaron Contreras793d7581f352
diff --git a/app/models/work_package.rb b/app/models/work_package.rbindex 100b19aac31..51d387b21e6 100644--- a/app/models/work_package.rb+++ b/app/models/work_package.rb@@ -45,6 +45,7 @@ class WorkPackage < ApplicationRecordinclude OpenProject::Journal::AttachmentHelperDONE_RATIO_OPTIONS = %w[field status].freeze+ TOTAL_PERCENT_COMPLETE_MODE_OPTIONS = %w[work_weighted_average simple_average].freezebelongs_to :projectbelongs_to :typediff --git a/app/views/admin/settings/progress_tracking/show.html.erb b/app/views/admin/settings/progress_tracking/show.html.erbindex 391de8f1a50..1e32f237b00 100644--- a/app/views/admin/settings/progress_tracking/show.html.erb+++ b/app/views/admin/settings/progress_tracking/show.html.erb@@ -26,9 +26,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.See COPYRIGHT and LICENSE files for more details.++#%>-<% html_title t(:label_administration), t(:label_work_package_plural), t(:label_progress_tracking) -%>-<%=render Primer::OpenProject::PageHeader.new do |header|header.with_title { t(:label_progress_tracking) }@@ -37,7 +35,6 @@ See COPYRIGHT and LICENSE files for more details.t(:label_progress_tracking)])end%>-<%=primer_form_with(scope: :settings, action: :update, method: :patch,@@ -70,6 +67,10 @@ primer_form_with(disabled: WorkPackage.status_based_mode?,data: { admin__progress_tracking_target: "statusClosedRadioGroup" })+ form.radio_button_group(+ name: "total_percent_complete_mode",+ values: WorkPackage::TOTAL_PERCENT_COMPLETE_MODE_OPTIONS+ )form.submitendenddiff --git a/config/locales/en.yml b/config/locales/en.ymlindex 2194c9f433e..fb7c765bc2b 100644--- a/config/locales/en.yml+++ b/config/locales/en.yml@@ -3370,6 +3370,14 @@ en:setting_sys_api_enabled: "Enable repository management web service"setting_sys_api_description: "The repository management web service provides integration and user authorization for accessing repositories."setting_time_format: "Time"+ setting_total_percent_complete_mode: "Calculation of % Complete hierarchy totals"+ setting_total_percent_complete_mode_work_weighted_average: "Weighted by work"+ setting_total_percent_complete_mode_work_weighted_average_caption_html: >-+ The <i>total % Complete</i> will be weighted against the <i>Work</i> of each work package in the hierarchy.+ Work packages without <i>Work</i> will be ignored (current behaviour).+ setting_total_percent_complete_mode_simple_average: "Simple average"+ setting_total_percent_complete_mode_simple_average_caption_html: >-+ <i>Work</i> is ignored and the <i>total % Complete</i> will be a simple average of <i>% Complete</i> values of work packages in the hierarchy.setting_accessibility_mode_for_anonymous: "Enable accessibility mode for anonymous users"setting_user_format: "Users name format"setting_user_default_timezone: "Users default time zone"