Move common views to partial
This commit is contained in:
parent
b15c1abd2e
commit
969c24c091
16 changed files with 101 additions and 120 deletions
|
|
@ -19,9 +19,8 @@
|
|||
.tab-content
|
||||
.tab-pane.active{role: 'tabpanel', id: 'signup'}
|
||||
= semantic_form_for(@registration, url: conference_conference_registrations_path(@conference.short_title)) do |f|
|
||||
- if !current_user
|
||||
= f.fields_for :user do |u|
|
||||
= render partial: 'devise/shared/sign_up_fields', locals: { u: u}
|
||||
= render partial: 'devise/shared/sign_up_form_embedded'
|
||||
|
||||
- if @conference.questions.any?
|
||||
= render partial: 'questions', locals: { f: f }
|
||||
- if @conference.events.workshops.any?
|
||||
|
|
@ -38,29 +37,4 @@
|
|||
- else
|
||||
=f.action :submit, button_html: { value: 'Register', class: 'btn btn-primary', id: 'register' }
|
||||
.tab-pane{role: 'tabpanel', id: 'signin'}
|
||||
- if !CONFIG['authentication']['ichain']['enabled']
|
||||
= form_tag(new_user_session_path, class: 'form-horizontal') do
|
||||
%legend
|
||||
%span
|
||||
Sign In
|
||||
.form-group
|
||||
%label{for: "user[login]", class: 'col-sm-2 control-label'}
|
||||
Username
|
||||
.col-sm-10
|
||||
= text_field_tag 'user[login]', nil, placeholder: 'Username', class: 'form-control', required: 'required'
|
||||
.form-group
|
||||
%label{for: "user[password]", class: 'col-sm-2 control-label'}
|
||||
Password
|
||||
.col-sm-10
|
||||
= password_field_tag 'user[password]', nil, placeholder: 'Password', class: 'form-control', required: 'required'
|
||||
.form-group
|
||||
.col-sm-12
|
||||
%button.btn.btn-success.pull-right
|
||||
Sign in
|
||||
- unless omniauth_configured.empty?
|
||||
.form-group
|
||||
%hr
|
||||
%p.text-center
|
||||
or sign in using
|
||||
.text-center
|
||||
= render 'devise/shared/openid'
|
||||
= render partial: 'devise/shared/sign_in_form_embedded'
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue