form_for @<%= singular_table_name %>, html: {class: 'form-horizontal'} do |f|¶ ↑
= error_messages_for @<%= singular_table_name %> %fieldset{disabled: @readonly} <% for attribute in attributes -%> .form-group = f.label :<%= attribute.name %>, class: 'col-sm-2 control-label' .col-sm-10 = f.<%= attribute.field_type %> :<%= attribute.name %>, class: 'form-control' <% end -%>
.form-group
.col-sm-offset-2.col-sm-10 = link_to_back <%= index_helper %>_path = submit_or_edit_button f, edit_url_for(@<%= singular_table_name %>), @readonly