2006-07-29 23:54:22 +04:00
|
|
|
<h2><%=l(:label_enumerations)%></h2>
|
2007-10-04 21:04:50 +04:00
|
|
|
|
2009-05-31 03:30:36 +04:00
|
|
|
<% Enumeration.get_subclasses.each do |klass| %>
|
|
|
|
<h3><%= l(klass::OptionName) %></h3>
|
2007-10-04 21:04:50 +04:00
|
|
|
|
2009-05-31 03:30:36 +04:00
|
|
|
<% enumerations = klass.all %>
|
2007-10-04 21:04:50 +04:00
|
|
|
<% if enumerations.any? %>
|
|
|
|
<table class="list">
|
|
|
|
<% enumerations.each do |enumeration| %>
|
|
|
|
<tr class="<%= cycle('odd', 'even') %>">
|
2008-06-07 19:08:59 +04:00
|
|
|
<td><%= link_to h(enumeration), :action => 'edit', :id => enumeration %></td>
|
2007-10-05 21:44:15 +04:00
|
|
|
<td style="width:15%;"><%= image_tag('true.png') if enumeration.is_default? %></td>
|
2009-03-01 15:03:48 +03:00
|
|
|
<td style="width:15%;"><%= reorder_links('enumeration', {:action => 'update', :id => enumeration}) %></td>
|
2008-06-17 23:10:54 +04:00
|
|
|
<td align="center" style="width:10%;">
|
|
|
|
<%= link_to l(:button_delete), { :action => 'destroy', :id => enumeration }, :method => :post, :confirm => l(:text_are_you_sure), :class => "icon icon-del" %>
|
|
|
|
</td>
|
2007-10-04 21:04:50 +04:00
|
|
|
</tr>
|
|
|
|
<% end %>
|
|
|
|
</table>
|
|
|
|
<% reset_cycle %>
|
|
|
|
<% end %>
|
2007-03-12 20:59:02 +03:00
|
|
|
|
2009-05-31 03:30:36 +04:00
|
|
|
<p><%= link_to l(:label_enumeration_new), { :action => 'new', :type => klass.name } %></p>
|
2007-10-04 21:04:50 +04:00
|
|
|
<% end %>
|
2007-12-07 21:42:40 +03:00
|
|
|
|
2008-01-03 01:41:53 +03:00
|
|
|
<% html_title(l(:label_enumerations)) -%>
|