To check out this repository please hg clone the following URL, or open the URL using EasyMercurial or your preferred Mercurial client.
root / .svn / pristine / 0c / 0c3d44b905a542240e7c616a63f74580e8cbbb9d.svn-base @ 912:5e80956cc792
History | View | Annotate | Download (1.73 KB)
| 1 | 909:cbb26bc654de | Chris | <% diff = Redmine::UnifiedDiff.new( |
|---|---|---|---|
| 2 | diff, :type => diff_type, |
||
| 3 | :max_lines => Setting.diff_max_lines_displayed.to_i) -%> |
||
| 4 | |||
| 5 | <% diff.each do |table_file| -%> |
||
| 6 | <div class="autoscroll"> |
||
| 7 | <% if diff.diff_type == 'sbs' -%> |
||
| 8 | <table class="filecontent"> |
||
| 9 | <thead> |
||
| 10 | <tr> |
||
| 11 | <th colspan="4" class="filename"> |
||
| 12 | <%= h(Redmine::CodesetUtil.to_utf8_by_setting(table_file.file_name)) %> |
||
| 13 | </th> |
||
| 14 | </tr> |
||
| 15 | </thead> |
||
| 16 | <tbody> |
||
| 17 | <% table_file.each_line do |spacing, line| -%> |
||
| 18 | <% if spacing -%> |
||
| 19 | <tr class="spacing"> |
||
| 20 | <th class="line-num">...</th><td></td><th class="line-num">...</th><td></td> |
||
| 21 | </tr> |
||
| 22 | <% end -%> |
||
| 23 | <tr> |
||
| 24 | <th class="line-num"><%= line.nb_line_left %></th> |
||
| 25 | <td class="line-code <%= line.type_diff_left %>"> |
||
| 26 | <pre><%= Redmine::CodesetUtil.to_utf8_by_setting(line.html_line_left) %></pre> |
||
| 27 | </td> |
||
| 28 | <th class="line-num"><%= line.nb_line_right %></th> |
||
| 29 | <td class="line-code <%= line.type_diff_right %>"> |
||
| 30 | <pre><%= Redmine::CodesetUtil.to_utf8_by_setting(line.html_line_right) %></pre> |
||
| 31 | </td> |
||
| 32 | </tr> |
||
| 33 | <% end -%> |
||
| 34 | </tbody> |
||
| 35 | </table> |
||
| 36 | |||
| 37 | <% else -%> |
||
| 38 | <table class="filecontent"> |
||
| 39 | <thead> |
||
| 40 | <tr> |
||
| 41 | <th colspan="3" class="filename"> |
||
| 42 | <%= h(Redmine::CodesetUtil.to_utf8_by_setting(table_file.file_name)) %> |
||
| 43 | </th> |
||
| 44 | </tr> |
||
| 45 | </thead> |
||
| 46 | <tbody> |
||
| 47 | <% table_file.each_line do |spacing, line| %> |
||
| 48 | <% if spacing -%> |
||
| 49 | <tr class="spacing"> |
||
| 50 | <th class="line-num">...</th><th class="line-num">...</th><td></td> |
||
| 51 | </tr> |
||
| 52 | <% end -%> |
||
| 53 | <tr> |
||
| 54 | <th class="line-num"><%= line.nb_line_left %></th> |
||
| 55 | <th class="line-num"><%= line.nb_line_right %></th> |
||
| 56 | <td class="line-code <%= line.type_diff %>"> |
||
| 57 | <pre><%= Redmine::CodesetUtil.to_utf8_by_setting(line.html_line) %></pre> |
||
| 58 | </td> |
||
| 59 | </tr> |
||
| 60 | <% end -%> |
||
| 61 | </tbody> |
||
| 62 | </table> |
||
| 63 | <% end -%> |
||
| 64 | </div> |
||
| 65 | <% end -%> |
||
| 66 | |||
| 67 | <%= l(:text_diff_truncated) if diff.truncated? %> |