@@ -12,17 +12,19 | |||||
12 | <% scm_class = "Repository::#{choice}".constantize %> |
|
12 | <% scm_class = "Repository::#{choice}".constantize %> | |
13 | <% text, value = (choice.is_a?(Array) ? choice : [choice, choice]) %> |
|
13 | <% text, value = (choice.is_a?(Array) ? choice : [choice, choice]) %> | |
14 | <% setting = :enabled_scm %> |
|
14 | <% setting = :enabled_scm %> | |
|
15 | <% enabled = Setting.send(setting).include?(value) %> | |||
15 | <tr> |
|
16 | <tr> | |
16 | <td class="scm_name"> |
|
17 | <td class="scm_name"> | |
17 | <%= |
|
18 | <%= | |
18 | check_box_tag( |
|
19 | check_box_tag( | |
19 | "settings[#{setting}][]", |
|
20 | "settings[#{setting}][]", | |
20 | value, |
|
21 | value, | |
21 | Setting.send(setting).include?(value)) |
|
22 | enabled) | |
22 | %> |
|
23 | %> | |
23 | <%= text.to_s %> |
|
24 | <%= text.to_s %> | |
24 | </td> |
|
25 | </td> | |
25 | <td> |
|
26 | <td> | |
|
27 | <% if enabled %> | |||
26 | <%= |
|
28 | <%= | |
27 | image_tag( |
|
29 | image_tag( | |
28 | (scm_class.scm_available ? 'true.png' : 'exclamation.png'), |
|
30 | (scm_class.scm_available ? 'true.png' : 'exclamation.png'), | |
@@ -30,9 +32,10 | |||||
30 | ) |
|
32 | ) | |
31 | %> |
|
33 | %> | |
32 | <%= scm_class.scm_command %> |
|
34 | <%= scm_class.scm_command %> | |
|
35 | <% end %> | |||
33 | </td> |
|
36 | </td> | |
34 | <td> |
|
37 | <td> | |
35 | <%= scm_class.scm_version_string %> |
|
38 | <%= scm_class.scm_version_string if enabled %> | |
36 | </td> |
|
39 | </td> | |
37 | </tr> |
|
40 | </tr> | |
38 | <% end %> |
|
41 | <% end %> |
General Comments 0
You need to be logged in to leave comments.
Login now