Skip to content

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

[#57816] final polishing

Eric Schubertafab498a8c04
diff --git a/app/components/admin/custom_fields/hierarchy/item_component.html.erb b/app/components/admin/custom_fields/hierarchy/item_component.html.erb
index 125c0300361..369d9234804 100644
--- a/app/components/admin/custom_fields/hierarchy/item_component.html.erb
+++ b/app/components/admin/custom_fields/hierarchy/item_component.html.erb
@@ -48,7 +48,7 @@ See COPYRIGHT and LICENSE files for more details.
item_container.with_column do
render(Primer::Beta::IconButton.new(scheme: :default,
icon: "kebab-horizontal",
- "aria-label": "some aria"))
+ "aria-label": I18n.t("custom_fields.admin.items.more_actions")))
end
end
end
diff --git a/app/contracts/custom_fields/hierarchy/insert_item_contract.rb b/app/contracts/custom_fields/hierarchy/insert_item_contract.rb
index 85fd53023cf..fe656cd6efb 100644
--- a/app/contracts/custom_fields/hierarchy/insert_item_contract.rb
+++ b/app/contracts/custom_fields/hierarchy/insert_item_contract.rb
@@ -51,7 +51,7 @@ module CustomFields
rule(:label) do
if CustomField::Hierarchy::Item.exists?(parent_id: values[:parent], label: value)
- key.failure(:duplicate)
+ key.failure(:not_unique)
end
end
end
diff --git a/app/forms/custom_fields/details_form.rb b/app/forms/custom_fields/details_form.rb
index b626e49dcfe..0ad82ccba63 100644
--- a/app/forms/custom_fields/details_form.rb
+++ b/app/forms/custom_fields/details_form.rb
@@ -39,7 +39,8 @@ module CustomFields
details_form.check_box(
name: :multi_value,
- label: I18n.t("activerecord.attributes.custom_field.multi_value")
+ label: I18n.t("activerecord.attributes.custom_field.multi_value"),
+ caption: I18n.t("custom_fields.instructions.multi_select")
)
details_form.check_box(
diff --git a/app/forms/custom_fields/hierarchy/new_item_form.rb b/app/forms/custom_fields/hierarchy/new_item_form.rb
index a9990722dd7..5541b8b1f36 100644
--- a/app/forms/custom_fields/hierarchy/new_item_form.rb
+++ b/app/forms/custom_fields/hierarchy/new_item_form.rb
@@ -51,7 +51,7 @@ module CustomFields
)
end
- new_item_form.group(layout: :horizontal, align_self: :end) do |button_group|
+ new_item_form.group(layout: :horizontal) do |button_group|
button_group.button(name: :cancel,
tag: :a,
label: I18n.t(:button_cancel),
diff --git a/config/locales/en.yml b/config/locales/en.yml
index c10d610584e..fec1287ebfe 100644
--- a/config/locales/en.yml
+++ b/config/locales/en.yml
@@ -238,6 +238,7 @@ en:
blankslate:
title: "Your list of items is empty"
description: "Start by adding items to the custom field of type hierarchy. Each item can be used to create a hierarchy bellow it. To navigate and create sub-items inside a hierarchy click on the created item."
+ more_actions: "More actions"
placeholder:
label: "Item label"
short: "Short name"
@@ -257,6 +258,7 @@ en:
is_required: "Mark the custom field as required. This will make it mandatory to fill in the field when creating new or updating existing resources."
is_required_for_project: "Check to enable this attribute and make it required in all projects. It cannot be deactived for individual projects."
is_for_all: "Mark the custom field as available in all existing and new projects."
+ multi_select: "Allows the user to assign multiple values to this custom field."
searchable: "Include the field values when using the global search functionality."
searchable_for_project: "Check to make this attribute available as a filter in project lists."
editable: "Allow the field to be editable by users themselves."
@@ -276,7 +278,8 @@ en:
errors:
rules:
label:
- duplicate: "must be unique within the same hierarchy level."
+ filled?: "must be filled"
+ not_unique: "must be unique within the same hierarchy level"
rules:
label: "Label"