diff --git a/app/views/additionals/settings/_issues.html.slim b/app/views/additionals/settings/_issues.html.slim index f773e25b..d6518c2b 100644 --- a/app/views/additionals/settings/_issues.html.slim +++ b/app/views/additionals/settings/_issues.html.slim @@ -19,8 +19,6 @@ p = additionals_settings_checkbox :issue_change_status_in_sidebar p = additionals_settings_checkbox :issue_autowatch_involved -p - = additionals_settings_checkbox :issue_close_with_open_children p = additionals_settings_checkbox :issue_freezed_with_close em.info = t(:rule_issue_freezed_with_close_info) diff --git a/config/locales/de.yml b/config/locales/de.yml index 0b35e4dd..d292f602 100644 --- a/config/locales/de.yml +++ b/config/locales/de.yml @@ -105,7 +105,6 @@ de: label_remove_mypage: "Entferne 'Meine Seite' aus dem Topmenü" label_remove_news: "Entferne 'Letzte News' von der Übersichtsseite" label_issue_auto_assign: "Wird \"Zugewiesen an\" nicht zugewiesen und der neue Ticketstatus ist x, dann wird die ersten Gruppe mit Benutzern der festgelegten Rolle das Ticket zugewiesen." - label_issue_close_with_open_children: Tickets mit offenen Untertickets können nicht geschlossen werden label_issue_current_user_status: "Der Ticketstatus x ist nur erlaubt, wenn \"Zugewiesen an\" der aktuelle Benutzer zugewiesen wird." label_issue_status_change: "Wird \"Zugewiesen an\" nicht verändert und der Ticketstatus von x auf y geändert, dann wird das Ticket automatisch dem Ersteller zugewiesen" label_issue_timelog_required: Zeiterfassung für Ticket erforderlich diff --git a/config/locales/en.yml b/config/locales/en.yml index 3e891a29..43a269ae 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -105,7 +105,6 @@ en: label_remove_mypage: "Remove 'My Page' from top menu" label_remove_news: "Remove 'Lastest news' from overview page" label_issue_auto_assign: "If \"Assigned to\" is not assigned to a user and the new issue status is x then the issue is auto assigned to the first group with users of the pre-defined role." - label_issue_close_with_open_children: Issues with open sub-issues cannot be closed label_issue_current_user_status: "Current issue status x is only allowed if \"Assignee\" is the current user." label_issue_status_change: "If \"Assignee\" is unchanged and the issue status changed from x to y, than the author is assigned to the issue" label_issue_timelog_required: Time log for issues required diff --git a/config/locales/es.yml b/config/locales/es.yml index 6d562d82..e70c3949 100644 --- a/config/locales/es.yml +++ b/config/locales/es.yml @@ -105,7 +105,6 @@ es: label_remove_mypage: "Quitar 'Mi página' del menú superior" label_remove_news: "Quitar 'Últimas noticias' del vistazo de un proyecto" label_issue_auto_assign: "Si \"Asignado a\" no es asignado a un usuario y el estado de la nueva petición es x, entonces la petición es auto asignada al primer grupo con usuarios del rol predefinido." - label_issue_close_with_open_children: Peticiones con sub-peticiones abiertas no pueden ser cerradas label_issue_current_user_status: "Estado de la petición actual x solo está permitido si la petición está asignada al usuario actual." label_issue_status_change: "Si no se modifica el usuario \"Asignado\" y la el estado de la petición es modificado de x a y, entonces la petición es asignada al autor de la petición" label_issue_timelog_required: Se requiere Registro de tiempo para las peticiones diff --git a/config/locales/fr.yml b/config/locales/fr.yml index 164c615e..a5e90ed6 100644 --- a/config/locales/fr.yml +++ b/config/locales/fr.yml @@ -105,7 +105,6 @@ fr: label_remove_mypage: "Remove 'My Page' from top menu" label_remove_news: "Remove 'Lastest news' from overview page" label_issue_auto_assign: "If \"Assigned to\" is not assigned to a user and the new issue status is x then the issue is auto assigned to the first group with users of the pre-defined role." - label_issue_close_with_open_children: "Les questions avec des sous-questions en suspens ne peuvent pas être clôturées." label_issue_current_user_status: "Current issue status x is only allowed if \"Assignee\" is the current user." label_issue_status_change: "If \"Assignee\" is unchanged and the issue status changed from x to y, than the author is assigned to the issue" label_issue_timelog_required: Time log for issues required diff --git a/config/locales/it.yml b/config/locales/it.yml index 18d7a652..3fa9bd1c 100644 --- a/config/locales/it.yml +++ b/config/locales/it.yml @@ -105,7 +105,6 @@ it: label_remove_mypage: "Remove 'My Page' from top menu" label_remove_news: "Remove 'Lastest news' from overview page" label_issue_auto_assign: "If \"Assigned to\" is not assigned to a user and the new issue status is x then the issue is auto assigned to the first group with users of the pre-defined role." - label_issue_close_with_open_children: Issues with open sub-issues cannot be closed label_issue_current_user_status: "Current issue status x is only allowed if \"Assignee\" is the current user." label_issue_status_change: "If \"Assignee\" is unchanged and the issue status changed from x to y, than the author is assigned to the issue" label_issue_timelog_required: "Time log per i problemi richiesti" diff --git a/config/locales/ja.yml b/config/locales/ja.yml index 765f5314..3d74a292 100644 --- a/config/locales/ja.yml +++ b/config/locales/ja.yml @@ -105,7 +105,6 @@ ja: label_remove_mypage: "「マイ・ページ」をトップメニューから外す" label_remove_news: "Remove 'Lastest news' from overview page" label_issue_auto_assign: "If \"Assigned to\" is not assigned to a user and the new issue status is x then the issue is auto assigned to the first group with users of the pre-defined role." - label_issue_close_with_open_children: Issues with open sub-issues cannot be closed label_issue_current_user_status: "Current issue status x is only allowed if \"Assignee\" is the current user." label_issue_status_change: "If \"Assignee\" is unchanged and the issue status changed from x to y, than the author is assigned to the issue" label_issue_timelog_required: Time log for issues required diff --git a/config/locales/zh-TW.yml b/config/locales/zh-TW.yml index 60161f92..f6baf805 100644 --- a/config/locales/zh-TW.yml +++ b/config/locales/zh-TW.yml @@ -105,7 +105,6 @@ label_remove_mypage: "從頂部選單中移除 \"帳戶首頁\" 項" label_remove_news: "從概觀頁中移除 \"最近新聞\" 區域" label_issue_auto_assign: "若建立新議題的 \"被分派者\" 未設定,且狀態為 X 時,將被自動分派給指定角色。" - label_issue_close_with_open_children: "子任務中若有狀態為開啟中的議題不能被結束。" label_issue_current_user_status: " \"被分派者\"為目前用戶時,議題狀態只能被設定為 X 。" label_issue_status_change: "若未修改 \"被分派者\" ,且議題狀態要從 X 變更為 Y ,則該議題必須被分派給議題作者。" label_issue_timelog_required: Time log for issues required diff --git a/config/locales/zh.yml b/config/locales/zh.yml index 3aa9b8fd..6b312297 100644 --- a/config/locales/zh.yml +++ b/config/locales/zh.yml @@ -105,7 +105,6 @@ zh: label_remove_mypage: "从顶部菜单栏中移除 '我的工作台' 项" label_remove_news: "从概览页中移除 '最近新闻' 区域" label_issue_auto_assign: "若 \"指派给\" 的值未设置为具体用户,且新建问题的状态为 X, 那么问题将自动指派给预定义角色用户的对应组。" - label_issue_close_with_open_children: 包含打开状态子任务的问题不能关闭。 label_issue_current_user_status: "当前问题状态 X 仅在 \"指派给\" 的值设置为当前用户时生效。" label_issue_status_change: "若 \"指派给\" 的值未修改,且问题状态要从 X 变更为 Y,那么该问题必须指派给问题作者自己。" label_issue_timelog_required: Time log for issues required diff --git a/config/settings.yml b/config/settings.yml index 409211ae..c6941b07 100644 --- a/config/settings.yml +++ b/config/settings.yml @@ -18,7 +18,6 @@ issue_auto_assign_status: '' issue_auto_assign: 0 issue_autowatch_involved: 0 issue_change_status_in_sidebar: 0 -issue_close_with_open_children: 0 issue_current_user_status: 0 issue_freezed_with_close: 0 issue_status_change: 0 diff --git a/lib/additionals/patches/issue_patch.rb b/lib/additionals/patches/issue_patch.rb index 193d6a52..13e1a188 100644 --- a/lib/additionals/patches/issue_patch.rb +++ b/lib/additionals/patches/issue_patch.rb @@ -8,7 +8,6 @@ module Additionals alias_method :editable?, :editable_with_additionals? validate :validate_change_on_closed validate :validate_timelog_required - validate :validate_open_sub_issues validate :validate_current_user_status before_validation :auto_assigned_to before_save :change_status_with_assigned_to_change, @@ -154,14 +153,6 @@ module Additionals errors.add :base, :issue_changes_not_allowed end - def validate_open_sub_issues - return true unless Additionals.setting?(:issue_close_with_open_children) - - errors.add :base, :issue_cannot_close_with_open_children if subject.present? && - closing? && - descendants.find { |d| !d.closed? } - end - def validate_current_user_status if (assigned_to_id_changed? || status_id_changed?) && status_x_affected?(status_id) &&