diff --git a/app/views/admin/groups/show.html.haml b/app/views/admin/groups/show.html.haml index ebed558f11b29644638ad751e8f388a4777d3adb..e105091e773033ad23939168ebca61838ed197a2 100644 --- a/app/views/admin/groups/show.html.haml +++ b/app/views/admin/groups/show.html.haml @@ -59,6 +59,8 @@ = render_if_exists 'namespaces/shared_runner_status', namespace: @group + = render 'shared/custom_attributes', custom_attributes: @group.custom_attributes + = render_if_exists 'ldap_group_links/ldap_group_links_show', group: @group .card diff --git a/app/views/admin/projects/show.html.haml b/app/views/admin/projects/show.html.haml index 8abc4c37e706a3b93a2123f390e8e0ccfd81363a..f9d42d3f53b913f5bae563f0df99bc1b5ae04334 100644 --- a/app/views/admin/projects/show.html.haml +++ b/app/views/admin/projects/show.html.haml @@ -108,6 +108,8 @@ = visibility_level_icon(@project.visibility_level) = visibility_level_label(@project.visibility_level) + = render 'shared/custom_attributes', custom_attributes: @project.custom_attributes + = render_if_exists 'admin/projects/geo_status_widget', locals: { project: @project } .card diff --git a/app/views/admin/users/show.html.haml b/app/views/admin/users/show.html.haml index 54cbed87bd542db458bbacc12cfe903d4b0710ad..e76f1f6444c3b05c7557cfb2abaaf50499af0152 100644 --- a/app/views/admin/users/show.html.haml +++ b/app/views/admin/users/show.html.haml @@ -141,6 +141,8 @@ = render_if_exists 'namespaces/shared_runner_status', namespace: @user.namespace + = render 'shared/custom_attributes', custom_attributes: @user.custom_attributes + .col-md-6 - unless @user == current_user - unless @user.confirmed? diff --git a/app/views/shared/_custom_attributes.html.haml b/app/views/shared/_custom_attributes.html.haml new file mode 100644 index 0000000000000000000000000000000000000000..966ab8e3cb1fa6d39ee260ec8a8e84e9701ad9b7 --- /dev/null +++ b/app/views/shared/_custom_attributes.html.haml @@ -0,0 +1,12 @@ +- return unless custom_attributes.present? + +.card + .card-header + = link_to(_('Custom Attributes'), help_page_path('api/custom_attributes.md')) + %ul.content-list + - custom_attributes.each do |custom_attribute| + %li + %span.light + = custom_attribute.key + %strong + = custom_attribute.value diff --git a/changelogs/unreleased/feat-admin-pages-show-custom-attributes.yml b/changelogs/unreleased/feat-admin-pages-show-custom-attributes.yml new file mode 100644 index 0000000000000000000000000000000000000000..6a9efcff17235e376131488687660a0b219ea6aa --- /dev/null +++ b/changelogs/unreleased/feat-admin-pages-show-custom-attributes.yml @@ -0,0 +1,5 @@ +--- +title: Show custom attributes within Admin Pages +merge_request: 34017 +author: Roger Meier +type: added diff --git a/locale/gitlab.pot b/locale/gitlab.pot index a7d14088692922c146b66b3d67ce986ab603651f..36b854f73dbdbf08cf163a670707b5a78c8cb0b0 100644 --- a/locale/gitlab.pot +++ b/locale/gitlab.pot @@ -6675,6 +6675,9 @@ msgstr "" msgid "CurrentUser|Upgrade" msgstr "" +msgid "Custom Attributes" +msgstr "" + msgid "Custom CI configuration path" msgstr ""