From 896072d698be3f83d9956c4ebd686f5ba13ae4dc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oliver=20G=C3=BCnther?= Date: Fri, 30 Jan 2026 09:56:15 +0100 Subject: [PATCH] Release attribute highlighting to community --- app/models/query/highlighting.rb | 4 - .../work_packages_general/show.html.erb | 12 +- config/constants/settings/definition.rb | 5 +- config/locales/en.yml | 3 - config/static_links.yml | 4 - .../work-package-settings/README.md | 4 +- .../README.md | 2 - .../tabs/highlighting-tab.component.html | 8 - .../tabs/highlighting-tab.component.ts | 14 -- .../wp-view-highlighting.service.ts | 10 +- .../switch_display_representations_spec.rb | 2 +- package-lock.json | 1 + .../work_packages/highlighting_spec.rb | 5 +- .../queries/query_representer_parsing_spec.rb | 2 +- .../query_representer_rendering_spec.rb | 160 ++++++++---------- spec/models/query/default_query_spec.rb | 2 +- spec/models/query_spec.rb | 119 ++++++------- spec/models/setting_spec.rb | 12 +- .../update_query_from_params_service_spec.rb | 27 +-- 19 files changed, 144 insertions(+), 252 deletions(-) diff --git a/app/models/query/highlighting.rb b/app/models/query/highlighting.rb index ccdf0692edc..4c9d216c584 100644 --- a/app/models/query/highlighting.rb +++ b/app/models/query/highlighting.rb @@ -69,8 +69,6 @@ module Query::Highlighting end def highlighted_attributes - return [] unless EnterpriseToken.allows_to?(:conditional_highlighting) - val = super if val.present? @@ -81,8 +79,6 @@ module Query::Highlighting end def highlighting_mode - return :none unless EnterpriseToken.allows_to?(:conditional_highlighting) - val = super if val.present? diff --git a/app/views/admin/settings/work_packages_general/show.html.erb b/app/views/admin/settings/work_packages_general/show.html.erb index baecea49136..815fdd0e856 100644 --- a/app/views/admin/settings/work_packages_general/show.html.erb +++ b/app/views/admin/settings/work_packages_general/show.html.erb @@ -1,4 +1,4 @@ -<%#-- copyright +<%# -- copyright OpenProject is an open source project management software. Copyright (C) the OpenProject GmbH @@ -25,7 +25,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_general) -%> @@ -66,19 +66,12 @@ See COPYRIGHT and LICENSE files for more details. end, Hash.new.tap do |options| options[:container_class] = "-middle" - options[:disabled] = "disabled" unless EnterpriseToken.allows_to?(:conditional_highlighting) options[:data] = { show_when_value_selected_target: "cause", target_name: "work_package_list_default_highlighting_mode" } end ) %> -
- <%= - render(EnterpriseEdition::BannerComponent.new(:conditional_highlighting, mt: 2)) - %> -
- <% if EnterpriseToken.allows_to? :conditional_highlighting %>
- <% end %> diff --git a/config/constants/settings/definition.rb b/config/constants/settings/definition.rb index 8aeb4c77414..283c4d4c138 100644 --- a/config/constants/settings/definition.rb +++ b/config/constants/settings/definition.rb @@ -1261,9 +1261,8 @@ module Settings }, work_package_list_default_highlighting_mode: { format: :string, - default: -> { EnterpriseToken.allows_to?(:conditional_highlighting) ? "inline" : "none" }, - allowed: -> { Query::QUERY_HIGHLIGHTING_MODES.map(&:to_s) }, - writable: -> { EnterpriseToken.allows_to?(:conditional_highlighting) } + default: -> { "inline" }, + allowed: -> { Query::QUERY_HIGHLIGHTING_MODES.map(&:to_s) } }, work_package_list_default_columns: { default: %w[id subject type status assigned_to priority], diff --git a/config/locales/en.yml b/config/locales/en.yml index 3b20d2b8859..07a8c0f7913 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -2557,7 +2557,6 @@ en: board_view: Advanced Boards calculated_values: Calculated values capture_external_links: Capture External Links - conditional_highlighting: Conditional Highlighting internal_comments: Internal Comments custom_actions: Custom Actions custom_field_hierarchies: Hierarchies @@ -2612,8 +2611,6 @@ en: description: "Create automatically generated subjects using referenced attributes and text." customize_life_cycle: description: "Create and organize different project phases than the ones provided by PM2 project cycle planning." - conditional_highlighting: - description: "Need certain work packages to stand out from the mass? Use conditional highlighting in the work packages table." capture_external_links: description: "Prevent social engineering attacks by capturing and warning about external links before users visit them." work_package_query_relation_columns: diff --git a/config/static_links.yml b/config/static_links.yml index 69d533768ca..5e73d2b6007 100644 --- a/config/static_links.yml +++ b/config/static_links.yml @@ -42,14 +42,10 @@ docker_installation: documents_docs: href: https://www.openproject.org/docs/user-guide/documents/ enterprise_features: - attribute_highlighting: - href: https://www.openproject.org/docs/user-guide/work-packages/work-package-table-configuration/#attribute-highlighting-enterprise-add-on board_view: href: https://www.openproject.org/docs/user-guide/agile-boards/#action-boards-enterprise-add-on boards: href: https://www.openproject.org/docs/user-guide/agile-boards/#action-boards-enterprise-add-on - conditional_highlighting: - href: https://www.openproject.org/enterprise-edition/?op_referrer=settings-wp-attribute-highlighting#attribute-highlighting custom_field_hierarchies: href: https://www.openproject.org/docs/system-admin-guide/custom-fields/#hierarchy-custom-field-enterprise-add-on custom_field_multiselect: diff --git a/docs/system-admin-guide/manage-work-packages/work-package-settings/README.md b/docs/system-admin-guide/manage-work-packages/work-package-settings/README.md index ee6a7204fd5..15e543fd1d1 100644 --- a/docs/system-admin-guide/manage-work-packages/work-package-settings/README.md +++ b/docs/system-admin-guide/manage-work-packages/work-package-settings/README.md @@ -21,9 +21,7 @@ You can adjust the following: 4. **Default highlighting mode** defines which should be the default [attribute highlighting](../../../user-guide/work-packages/work-package-table-configuration/#attribute-highlighting-enterprise-add-on) mode, e.g. to highlight the following criteria in the work package table. -[feature: conditional_highlighting ] - - ![default highlighting mode](openproject_system_guide_default_highlighting_mode.png) +![default highlighting mode](openproject_system_guide_default_highlighting_mode.png) 5. Customize the appearance of the work package lists to **define which work package attributes are displayed in the work package lists by default and in what order**. diff --git a/docs/user-guide/work-packages/work-package-table-configuration/README.md b/docs/user-guide/work-packages/work-package-table-configuration/README.md index ceaeafea8ef..250d5153311 100644 --- a/docs/user-guide/work-packages/work-package-table-configuration/README.md +++ b/docs/user-guide/work-packages/work-package-table-configuration/README.md @@ -235,8 +235,6 @@ If you group the work package table, sums will be shown for each group. ## Attribute highlighting (Enterprise add-on) -[feature: conditional_highlighting ] - You can highlight attributes in the work package table to emphasize the importance of certain attributes and have important topics at a glance. To activate attribute highlighting open the work package configuration table and select the **Highlighting** tab. The following attributes can be highlighted in the table: diff --git a/frontend/src/app/features/work-packages/components/wp-table/configuration-modal/tabs/highlighting-tab.component.html b/frontend/src/app/features/work-packages/components/wp-table/configuration-modal/tabs/highlighting-tab.component.html index 93730dc1ace..0b24ad62bae 100644 --- a/frontend/src/app/features/work-packages/components/wp-table/configuration-modal/tabs/highlighting-tab.component.html +++ b/frontend/src/app/features/work-packages/components/wp-table/configuration-modal/tabs/highlighting-tab.component.html @@ -1,14 +1,9 @@
- -