Skip to content
代码片段 群组 项目
未验证 提交 324e5c44 编辑于 作者: Aboobacker MK's avatar Aboobacker MK 提交者: GitLab
浏览文件

Merge branch '413783-be-update-url-param-to-approval-policy' into 'master'

Update policy type param for editing to use approval_policy

See merge request https://gitlab.com/gitlab-org/gitlab/-/merge_requests/143062



Merged-by: default avatarAboobacker MK <akarakath@gitlab.com>
Approved-by: default avatarMarcos Rocha <mrocha@gitlab.com>
Approved-by: default avatarAboobacker MK <akarakath@gitlab.com>
Co-authored-by: default avatarMartin Čavoj <mcavoj@gitlab.com>
No related branches found
No related tags found
无相关合并请求
......@@ -29,7 +29,7 @@ def construct_scan_result_policies(policies)
{
name: policy[:name],
description: policy[:description],
edit_path: edit_path(policy, :scan_result_policy),
edit_path: edit_path(policy, :approval_policy),
enabled: policy[:enabled],
yaml: YAML.dump(policy.slice(*POLICY_YAML_ATTRIBUTES).deep_stringify_keys),
updated_at: policy[:config].policy_last_updated_at,
......
......@@ -41,7 +41,7 @@
name: policy[:name],
description: policy[:description],
edit_path: Gitlab::Routing.url_helpers.edit_project_security_policy_url(
project, id: CGI.escape(policy[:name]), type: 'scan_result_policy'
project, id: CGI.escape(policy[:name]), type: 'approval_policy'
),
enabled: policy[:enabled],
yaml: YAML.dump(policy.deep_stringify_keys),
......
......@@ -15,7 +15,7 @@
name: 'Require security approvals',
description: 'This policy considers only container scanning and critical severities',
edit_path: Gitlab::Routing.url_helpers.edit_project_security_policy_url(
project, id: CGI.escape(policy[:name]), type: 'scan_result_policy'
project, id: CGI.escape(policy[:name]), type: 'approval_policy'
),
enabled: true,
yaml: YAML.dump(policy.deep_stringify_keys),
......
0% 加载中 .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册