Sha256: d4f7ea1d03dcc189dab769e29b83d6a86d3a90b8399c463b982cd9fd9b26408c
Contents?: true
Size: 790 Bytes
Versions: 4
Compression:
Stored size: 790 Bytes
Contents
<div class="page-header"> <h1>New <%= human_name.titleize %></h1> </div> <%%= form_tag(<%= plural_name %>_url, method: 'post', class: 'form-horizontal') do %> <% attributes.each do |attribute| -%> <div class="form-group"> <%%= label_tag :<%= attribute.name %>, nil, class: 'col-md-2 control-label' %> <% colsize = 6 colsize = 2 if attribute.type == :integer %> <div class="col-md-<%= colsize %>"> <%%= <%= attribute.field_type %>_tag :<%= attribute.name %><%= "?" if attribute.type == :boolean %>, nil, class: 'form-control' %> </div> </div> <% end -%> <div class="form-group"> <div class="col-md-offset-2 col-md-6"> <%%= submit_tag "Create <%= human_name.titleize %>", class: 'btn btn-primary' %> </div> </div> <%% end %>
Version data entries
4 entries across 4 versions & 1 rubygems