From d5d65f74d11dddb3fdeb0c34e76cd5abec9876e2 Mon Sep 17 00:00:00 2001 From: Christophe Bliard Date: Fri, 5 Apr 2024 16:13:11 +0200 Subject: [PATCH] Remove Disabled option from Progress calculation setting Also renamed the other options to Work-based and Status-based, and added an explanation of the two options. --- app/models/work_package.rb | 2 +- .../settings/work_packages_settings/show.html.erb | 7 ++++++- config/locales/en.yml | 10 ++++++---- 3 files changed, 13 insertions(+), 6 deletions(-) diff --git a/app/models/work_package.rb b/app/models/work_package.rb index bea6bce410ae..d873070c3e91 100644 --- a/app/models/work_package.rb +++ b/app/models/work_package.rb @@ -43,7 +43,7 @@ class WorkPackage < ApplicationRecord include OpenProject::Journal::AttachmentHelper - DONE_RATIO_OPTIONS = %w(field status disabled).freeze + DONE_RATIO_OPTIONS = %w[field status].freeze belongs_to :project belongs_to :type diff --git a/app/views/admin/settings/work_packages_settings/show.html.erb b/app/views/admin/settings/work_packages_settings/show.html.erb index 83a19c617520..0151e41e51fa 100644 --- a/app/views/admin/settings/work_packages_settings/show.html.erb +++ b/app/views/admin/settings/work_packages_settings/show.html.erb @@ -36,7 +36,12 @@ See COPYRIGHT and LICENSE files for more details.
<%= setting_check_box :cross_project_work_package_relations %>
<%= setting_check_box :display_subprojects_work_packages %>
<%= setting_check_box :work_package_startdate_is_adddate %>
-
<%= setting_select :work_package_done_ratio, WorkPackage::DONE_RATIO_OPTIONS.collect { |i| [t("setting_work_package_done_ratio_#{i}"), i] }, container_class: "-middle" %>
+
+ <%= setting_select :work_package_done_ratio, + WorkPackage::DONE_RATIO_OPTIONS.collect { |i| [t("setting_work_package_done_ratio_#{i}"), i] }, + container_class: "-middle" %> +
<%= t("setting_work_package_done_ratio_explanation_html") %>
+
<%= setting_select(:work_package_list_default_highlighting_mode, Query::Highlighting::QUERY_HIGHLIGHTING_MODES.map do |mode| diff --git a/config/locales/en.yml b/config/locales/en.yml index c3ff0f725072..2db9ec9bcc29 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -3019,10 +3019,12 @@ Project attributes and sections are defined in the + In work-based mode, % Complete is calculated from how much work is done in relation to total work.
+ In status-based mode, each status has a % Complete value associated with it. Changing status will change % Complete. setting_work_package_properties: "Work package properties" setting_work_package_startdate_is_adddate: "Use current date as start date for new work packages" setting_work_packages_projects_export_limit: "Work packages / Projects export limit"