BigW Consortium Gitlab

Commit d4059ac9 by randx

Move graph_commit under gitlab module

parent 05c86fb0
require File.join(Rails.root, 'lib', 'graph_commit') require Rails.root.join('lib', 'gitlab', 'graph_commit')
class ProjectsController < ApplicationController class ProjectsController < ApplicationController
before_filter :project, except: [:index, :new, :create] before_filter :project, except: [:index, :new, :create]
...@@ -78,7 +78,7 @@ class ProjectsController < ApplicationController ...@@ -78,7 +78,7 @@ class ProjectsController < ApplicationController
end end
def graph def graph
@days_json, @commits_json = GraphCommit.to_graph(project) @days_json, @commits_json = Gitlab::GraphCommit.to_graph(project)
end end
def destroy def destroy
......
require "grit" require "grit"
class GraphCommit module Gitlab
class GraphCommit
attr_accessor :time, :space attr_accessor :time, :space
attr_accessor :refs attr_accessor :refs
...@@ -178,4 +179,5 @@ class GraphCommit ...@@ -178,4 +179,5 @@ class GraphCommit
@refs = ref_cache[@_commit.id] if ref_cache.include?(@_commit.id) @refs = ref_cache[@_commit.id] if ref_cache.include?(@_commit.id)
@refs ||= [] @refs ||= []
end end
end
end end
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment