Retire semantic_form_for

Also a buttload of form cleanups...
This commit is contained in:
Henne Vogelsang 2022-02-23 17:52:16 +01:00
parent 350b1ebbbe
commit 81853d1ef9
No known key found for this signature in database
GPG key ID: 97DDB66BDAF8D4D6
136 changed files with 1825 additions and 1441 deletions

View file

@ -3,17 +3,21 @@
.col-md-6.col-md-offset-3
.panel.panel-default
.panel-heading
%h3.panel-title
Sign in (TEST MODE)
%h3 Sign In (TEST MODE)
%p.text-muted
Just fill out all the details and you're logged in.
.panel-body
= semantic_form_for "", method: :post, enctype: 'application/x-www-form-urlencoded', url: @login_url do |f|
= f.input :username, input_html: { autofocus: true }
- if ::Devise.ichain_force_test_attributes.blank?
= form_tag(@login_url, method: :post, enctype: 'application/x-www-form-urlencoded', id: 'session') do
.form-group
= label_tag :username, "Username"
= text_field_tag :username, "", :autofocus => true, :placeholder => 'Username', :class => 'form-control', :required => "required"
.form-group
- @fields.each do |field|
= f.input "attributes[#{field}]", label: field.to_s.humanize
= label_tag "attributes[#{field}]", field.to_s.humanize
= text_field_tag "attributes[#{field}]", nil, :class => 'form-control', :required => "required"
%p.text-right
= f.action :submit, as: :button, label: 'Sign In', button_html: { class: 'btn btn-success' }
%button{type: 'submit', class: 'btn btn-success'}
Sign In
= render partial: 'devise/shared/help'
- if devise_mapping.ichain_registerable?
= link_to "Sign up", new_ichain_registration_path(resource_name)