项目得分更新
This commit is contained in:
parent
eb02a3d34a
commit
8a53978d23
|
@ -22,7 +22,9 @@ module ProjectScoreHelper
|
|||
|
||||
#代码提交数量
|
||||
def changesets_num project
|
||||
# commit_count(project)
|
||||
# g = Gitlab.client
|
||||
# project.gpid.nil? ? 0 : g.commits_total_count(project.gpid)
|
||||
# commits_total_count(project.gpid)
|
||||
project.changesets.count
|
||||
end
|
||||
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
<div class="fl mt5 ml15"><a href="javascript:void(0);" class="vl_btn fb" onclick="zip()"><span class="vl_zip"></span>ZIP</a> </div>
|
||||
<%# 针对公开项目:用户必须创建了项目,否则用户无法同步 %>
|
||||
<% if User.current.id != @project.user_id %>
|
||||
<div class="fr mt5"><%= link_to "<span class='vl_fork'></span>".html_safe+"Fork", {:controller => 'repositories', :action => 'forked'}, :class=>"vl_btn", :confirm=>"确认要fork该项目吗?" %>
|
||||
<div class="fr mt5"><%= link_to "<span class='vl_fork'></span>".html_safe+"Fork", {:controller => 'repositories', :action => 'forked'}, :class=>"vl_btn", :confirm=>"平台将为您创建一个新的同名项目和版本库,请问是否继续?" %>
|
||||
<span href="javascript:void(0);" class="vl_btn_2 fb"><%= @project.forked_count.to_i %></span>
|
||||
</div>
|
||||
<% end %>
|
||||
|
|
Loading…
Reference in New Issue