parent
449bdf2225
commit
e8048f8eb7
|
@ -52,6 +52,12 @@ module RepositoriesHelper
|
|||
end
|
||||
end
|
||||
|
||||
def translate_time time
|
||||
case time
|
||||
when time.include("")
|
||||
end
|
||||
end
|
||||
|
||||
# 获取diff内容行号
|
||||
def diff_line_num content
|
||||
content.scan(/@@ -(\d+),\d+ \+\d+,\d+ @@/).first.join("").to_i
|
||||
|
|
|
@ -43,7 +43,11 @@
|
|||
</div>
|
||||
</td>
|
||||
<td class="tree-age c_grey">
|
||||
<div class="hidden" title="<%= distance_of_time_in_words(latest_changes.time, Time.now) if latest_changes && latest_changes.time %>"><%= distance_of_time_in_words(latest_changes.time, Time.now) if latest_changes && latest_changes.time %></div>
|
||||
<div class="hidden" title="<%= distance_of_time_in_words(latest_changes.time, Time.now + 8.hours) if latest_changes && latest_changes.time %>">
|
||||
<%# 为了转换UTC时间,时差8小时 %>
|
||||
<%= distance_of_time_in_words(latest_changes.time, Time.now + 8.hours) if latest_changes && latest_changes.time %>
|
||||
<%#= latest_changes.time if latest_changes && latest_changes.time %>
|
||||
</div>
|
||||
</td>
|
||||
</div>
|
||||
<%# end %>
|
||||
|
|
Loading…
Reference in New Issue