Sha256: b6ae37c0a4bf83a007b48af72a956c1df652ae2134aa57f72cd7ad235420e1c2
Contents?: true
Size: 1.7 KB
Versions: 3
Compression:
Stored size: 1.7 KB
Contents
<div class="cbac"> <h1>Generic roles</h1> <table> <tr> <th class="medium">Name</th> <th class="large">Remarks</th> <th class="small"> </th> </tr> <% Cbac::GenericRole.find(:all).each do |role| %> <tr class="row"> <% form_for role do |r| %> <td class="medium"><%= r.text_field :name %></td> <td class="large"><%= r.text_field :remarks, :rows => 1 %></td> <td class="small"><%= r.submit "OK" %></td> <% end %> </tr> <% end%> </table> <div class="linebreak"></div> <table> <% form_for(Cbac::GenericRole.new) do |new_role| %> <tr class="row"> <th colspan="2">New generic role</th> </tr> <tr class="row"> <td class="medium">Name</td> <td class="medium"><%= new_role.text_field :name %></td> </tr> <tr class="row"> <td class="medium">Remarks</td> <td class="large"><%= new_role.text_field :remarks %></td> </tr> <tr class="row"> <td colspan="2" class="submit"><%= new_role.submit "Create" %></td> </tr> <% end %> </table> <div class="linebreak"></div> <table> <% form_tag(:controller => "cbac/generic_roles", :action => "delete") do |f| %> <tr> <th colspan="2">Delete generic role</th> </tr> <tr> <td class="medium">Select role</td> <td class="medium"><%= select_tag "id", Cbac::GenericRole.find(:all).collect{|role|"<option value='#{role.id}'>#{role.name}</option>"} %> </td> </tr> <tr> <td colspan="2" class="submit"><%= submit_tag "Delete" %></td> </tr> <% end %> </table> </div>
Version data entries
3 entries across 3 versions & 1 rubygems