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

work_items_helper.rb « helpers « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: d2e3d41377a04dd2ff09a4358395f78c8b51534c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
# frozen_string_literal: true

module WorkItemsHelper
  def work_items_index_data(resource_parent)
    {
      full_path: resource_parent.full_path,
      issues_list_path:
        resource_parent.is_a?(Group) ? issues_group_path(resource_parent) : project_issues_path(resource_parent),
      register_path: new_user_registration_path(redirect_to_referer: 'yes'),
      sign_in_path: new_session_path(:user, redirect_to_referer: 'yes'),
      new_comment_template_path: profile_comment_templates_path,
      report_abuse_path: add_category_abuse_reports_path
    }
  end

  def work_items_list_data(group)
    {
      full_path: group.full_path
    }
  end
end