annotate app/views/enumerations/index.html.erb @ 1298:4f746d8966dd redmine_2.3_integration

Merge from redmine-2.3 branch to create new branch redmine-2.3-integration
author Chris Cannam
date Fri, 14 Jun 2013 09:28:30 +0100
parents 433d4f72a19b
children 261b3d9a4903
rev   line source
Chris@909 1 <h2><%=l(:label_enumerations)%></h2>
Chris@909 2
Chris@909 3 <% Enumeration.get_subclasses.each do |klass| %>
Chris@909 4 <h3><%= l(klass::OptionName) %></h3>
Chris@909 5
Chris@909 6 <% enumerations = klass.shared %>
Chris@909 7 <% if enumerations.any? %>
Chris@909 8 <table class="list"><thead>
Chris@909 9 <tr>
Chris@909 10 <th><%= l(:field_name) %></th>
Chris@909 11 <th style="width:15%;"><%= l(:field_is_default) %></th>
Chris@909 12 <th style="width:15%;"><%= l(:field_active) %></th>
Chris@909 13 <th style="width:15%;"></th>
Chris@909 14 <th align="center" style="width:10%;"> </th>
Chris@909 15 </tr></thead>
Chris@909 16 <% enumerations.each do |enumeration| %>
Chris@909 17 <tr class="<%= cycle('odd', 'even') %>">
Chris@1115 18 <td><%= link_to h(enumeration), edit_enumeration_path(enumeration) %></td>
Chris@909 19 <td class="center" style="width:15%;"><%= checked_image enumeration.is_default? %></td>
Chris@909 20 <td class="center" style="width:15%;"><%= checked_image enumeration.active? %></td>
Chris@1115 21 <td style="width:15%;"><%= reorder_links('enumeration', {:action => 'update', :id => enumeration}, :put) %></td>
Chris@909 22 <td class="buttons">
Chris@1115 23 <%= delete_link enumeration_path(enumeration) %>
Chris@909 24 </td>
Chris@909 25 </tr>
Chris@909 26 <% end %>
Chris@909 27 </table>
Chris@909 28 <% reset_cycle %>
Chris@909 29 <% end %>
Chris@909 30
Chris@1115 31 <p><%= link_to l(:label_enumeration_new), new_enumeration_path(:type => klass.name) %></p>
Chris@909 32 <% end %>
Chris@909 33
Chris@909 34 <% html_title(l(:label_enumerations)) -%>