Display Compliance Framework disabled field for Maintainers (FE)

Problem to solve

Starting with !50441 (merged), the Compliance framework field is no longer displayed for project maintainers. It was decided to ship this change in %13.8 and revisit the refactoring work in 13.9%

Proposal

  • Display the Compliance framework field as disabled for Maintainers.
  • Add help text Customizable by owners. linking to documentation.

Design

Text

selected empty
image image

Implementation plan

frontend - 1

  1. Update ee/app/views/compliance_management/compliance_framework/_project_settings.html.haml to remove the instant return and move to the wrapping - else and inside the Feature.enabled?(:ff_custom_compliance_frameworks) block
  2. If current_user.can?(:admin_compliance_framework, @project) then show the dropdown
  3. Otherwise, show a disabled input field without the description and (optional) suffix
  4. If no framework has been chosen already for this project, show None where a value would be
  5. Update tests to check the right field is shown (with the right values) depending on each scenario

Separate MR:

  1. Limit the total length to 80 characters with an ellipsis (for disabled and enabled fields)
Edited by Dan Jensen