Welcome to mirror list, hosted at ThFree Co, Russian Federation.

_nav_btns.html.haml « service_desk « issues « projects « views « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 3b7b3f57abd797c678ad8ecc5799966614f1e8e7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
- show_feed_buttons = local_assigns.fetch(:show_feed_buttons, true)
- show_import_button = local_assigns.fetch(:show_import_button, true) && can?(current_user, :import_issues, @project)
- show_export_button = local_assigns.fetch(:show_export_button, true)
- issuable_type = 'issue'
- can_edit = can?(current_user, :admin_project, @project)
- notification_email = @current_user.present? ? @current_user.notification_email_or_default : nil

.nav-controls.issues-nav-controls.gl-font-size-0
  - if @can_bulk_update
    = render Pajamas::ButtonComponent.new(button_options: { class: 'gl-mr-3 js-bulk-update-toggle' }) do
      = _("Bulk edit")
  - if show_new_issue_link?(@project)
    = render Pajamas::ButtonComponent.new(variant: :confirm,
                                          href: new_project_issue_path(@project, issue: { milestone_id: finder.milestones.first.try(:id) }),
                                          button_options: { id: 'new_issue_link', class: 'gl-mr-3' }) do
      = _("New issue")

.dropdown.gl-dropdown
  = button_tag type: 'button', class: "btn dropdown-toggle btn-default btn-md gl-button gl-dropdown gl-dropdown-toggle btn-default-tertiary dropdown-icon-only dropdown-toggle-no-caret has-tooltip gl-display-none! gl-md-display-inline-flex!", data: { toggle: 'dropdown', title: _('Actions') } do
    = sprite_icon "ellipsis_v", size: 16, css_class: "dropdown-icon gl-icon"
    %span.gl-sr-only
      = _('Actions')
  = button_tag type: 'button', class: "btn dropdown-toggle btn-default btn-md btn-block gl-button gl-dropdown-toggle gl-md-display-none!", data: { 'toggle' => 'dropdown' } do
    %span.gl-dropdown-button-text= _('Actions')
    = sprite_icon "chevron-down", size: 16, css_class: "dropdown-icon gl-icon"
  .dropdown-menu.dropdown-menu-right
    .gl-dropdown-inner
      .gl-dropdown-contents
        %ul
          .js-csv-import-export-buttons{ data: { show_export_button: show_export_button.to_s, show_import_button: show_import_button.to_s, issuable_type: issuable_type, issuable_count: issuables_count_for_state(issuable_type.to_sym, params[:state]), email: notification_email, export_csv_path: export_csv_project_issues_path(@project, request.query_parameters), import_csv_issues_path: import_csv_namespace_project_issues_path, can_edit: can_edit.to_s, project_import_jira_path: project_import_jira_path(@project), max_attachment_size: number_to_human_size(Gitlab::CurrentSettings.max_attachment_size.megabytes) } }
          %li.gl-dropdown-divider
            %hr.dropdown-divider
          %li.gl-dropdown-item
            - if show_feed_buttons
              = render 'shared/issuable/feed_buttons'