Create shared haml files for Usage Quotas pages
What does this MR do and why?
This MR improves and DRY up the haml
files for Usage Quotas Pages. Changes involve:
- Create a shared
usage_quotas
view inapp/views/shared/usage_quotas/
: Solves #458218 (closed)- Use this shared view in the pages specific views:
Group
,Project
,Profile
- Page specific content using
yield
andcontent_for
. Three keys:usage_quotas_alerts
,:usage_quotas_subtitle
,:usage_quotas_tabs
- Use this shared view in the pages specific views:
- Deduplicate
Group
usage quotas- Rely only on
app/views/groups/usage_quotas/index.html.haml
- Delete
ee/app/views/groups/usage_quotas/index.html.haml
- All the
EE
specific content is moved into partials underee/app/views/shared/usage_quotas/
- Rely only on
- Add License check for
pipelines
tab. Solves: #455101 (closed)- Add
:admin_ci_minutes
toee/app/policies/ee/namespaces/user_namespace_policy.rb
- Add
MR acceptance checklist
Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Screenshots or screen recordings
No UI changes
Before | After |
---|---|
all_usage_quotas_pages_master | all_usage_quotas_pages_150164 |
How to set up and validate locally
Visit Usage Quotas pages and compare the screenshots:
-
Group Usage Quotas:
https://gitlab.com/groups/<group-id>/-/usage_quotas
-
Project Usage Quotas:
https://gitlab.com/<group-id>/<project-id>/-/usage_quotas
- Profile/User Namespace Usage Quotas: https://gitlab.com/-/profile/usage_quotas
Edited by Sheldon Led