Standardize project-level MR approval rule input
Facts
- At the instance level there is a setting for "Prevent users from modifying MR approval rules"
disable_overriding_approvers_per_merge_request
- Appears in _merge_request_approvals_settings_form.html.haml
- This value gets inverted on the client side.
- At the project level there is a setting for "Allow overrides to approval lists per merge request (MR)"
disable_overriding_approvers_per_merge_request
- Appears in _merge_request_approvals_fields.html.haml
- When the instance-level box is checked, the project-level box is disabled but NOT checked. (Watch video demo.)
Problems to solve
The project-level input seems to have 2 problems:
- The label says the opposite of what it should say. The label should say "Prevent" like at the instance level, not "Allow" (per #263275 (comment 489093878)).
- The checkbox is disabled but NOT checked when the instance-level box is checked, so it is not clear if the instance-level setting is being enforced. If the instance-level box is checked, the project-level box should be disabled and checked.
Proposal
-
Change the project-level setting label to "Prevent user from modifying MR Approval rules" (per #263275 (comment 489093878)). -
Change the project-level behavior so the box is checked and disabled (not just disabled) when the instance-level box is checked.
Edited by Dan Jensen