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

network_controller.rb « projects « controllers « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: e4a84f80787027fd899169e30557556e6cdbd01c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
class Projects::NetworkController < Projects::ApplicationController
  include ExtractsPath
  include ApplicationHelper

  # Authorize
  before_filter :authorize_read_project!
  before_filter :authorize_code_access!
  before_filter :require_non_empty_project

  def show
    if @options[:q]
      @commit = @project.repository.commit(@options[:q]) || @commit
    end

    respond_to do |format|
      format.html

      format.json do
        @graph = Network::Graph.new(project, @ref, @commit, @options[:filter_ref])
      end
    end
  end
end