commits_helper.rb 565 字节
Newer Older
G
gitlabhq 已提交
1
module CommitsHelper
2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
  def old_line_number(line, i)

  end

  def new_line_number(line, i)

  end

  def diff_line_class(line)
    if line[0] == "+"
      "new"
    elsif line[0] == "-"
      "old"
    else
      nil
    end
G
gitlabhq 已提交
18 19 20 21 22 23 24 25 26
  end

  def more_commits_link
    offset = params[:offset] || 0
    limit = params[:limit] || 100
    link_to "More", project_commits_path(@project, :offset =>  offset.to_i + limit.to_i, :limit => limit),
      :remote => true, :class => "lite_button vm", :style => "text-align:center; width:930px; ", :id => "more-commits-link"
  end
end