File: _show.html.haml

package info (click to toggle)
gitlab 17.6.5-19
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 629,368 kB
  • sloc: ruby: 1,915,304; javascript: 557,307; sql: 60,639; xml: 6,509; sh: 4,567; makefile: 1,239; python: 406
file content (18 lines) | stat: -rw-r--r-- 1,283 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
- expanded = expanded_by_default?
- show_code_owners = @project.licensed_feature_available?(:code_owner_approval_required)
- show_status_checks = @project.licensed_feature_available?(:external_status_checks)
- show_approvers = @project.licensed_feature_available?(:merge_request_approvers)
- show_enterprise_access_levels = @project.licensed_feature_available?(:protected_refs_for_users)

= render ::Layouts::SettingsBlockComponent.new(_('Branch rules'),
  id: 'branch-rules',
  testid: 'branch-rules-content',
  expanded: expanded) do |c|
  - c.with_callout do
    - if Feature.enabled?(:edit_branch_rules, @project)
      = render 'projects/settings/branch_rules_callout'
  - c.with_description do
    = _('Define rules for who can push, merge, and the required approvals for each branch.')
    = link_to(_('Leave feedback.'), 'https://gitlab.com/gitlab-org/gitlab/-/issues/388149', target: '_blank', rel: 'noopener noreferrer')
  - c.with_body do
    #js-branch-rules{ data: { project_path: @project.full_path, branch_rules_path: project_settings_repository_branch_rules_path(@project), show_code_owners: show_code_owners.to_s, show_status_checks: show_status_checks.to_s, show_approvers: show_approvers.to_s, show_enterprise_access_levels: show_enterprise_access_levels.to_s } }