FE: Add ability to have multiple actions
Why are we doing this work
- Users want to be able to select a combination of roles, individual users, and groups to be approvers
Relevant links
Implementation plan
MR 1
-
frontend in scan_result_policy_editor.vue -
Conditionally render a + Add new approver
button to add an additional action based on the:scan_result_role_action
feature flag (similar to in scan_execution_policy_editor.vue
-
-
frontend in .../security_orchestration/components/policy_editor/scan_result_policy/policy_action_builder_v2.vue
-
frontend update the action builder to take the action index and make changes on the correct action -
frontend add a remove button (similar to scan_execution_policy/policy_action_builder.vue#L147) -
frontend only allow one action per type (one role action, one user action, one group action) -
frontend ensure that when a user changes the type selection, the selection is cleared
-
Verification steps
- Upload a GitLab Ultimate license
- Enable the
:scan_result_role_action
feature flag with the below command
echo "Feature.enable(:scan_result_role_action)" | rails c
- Navigate to a project/group => Security & Compliance => Policies => New policy => Scan Result Policy
- Verify a user can add multiple actions and modify individual actions that do not affect the other actions
Edited by Alexander Turinske