clarion/app/views/management/users/edit.html.slim
Andrew Radev 454f18dd2f A user has many profiles now
Still need to change controllers quite a lot.
2015-05-30 18:53:14 +03:00

43 lines
1.4 KiB
Plaintext

- content_for :title
=> t 'actions.edit.title', model: User.model_name.human
= @profile.name
.row
.col-lg-12
= simple_nested_form_for [:management, @user], wrapper: :horizontal_form, html: { class: 'form-horizontal' } do |f|
.panel.panel-primary
.panel-heading
h1.panel-title
= t 'views.user.info'
= link_to icon(:eye), [:management, @user], class: 'btn btn-xs btn-info pull-right'
.panel-body
.row
.col-lg-12
= f.input :email
hr
.row
.col-lg-12
-# TODO we have many personal_profiles now
= f.simple_fields_for :personal_profile do |ff|
- if @profile.picture.present?
.col-sm-offset-3.col-sm-9
= image_tag @profile.picture.medium.url, class: 'img-thumbnail'
= ff.input :picture, wrapper: :horizontal_file_input
-# Required
= ff.input :first_name
= ff.input :last_name
= ff.input :mobile_phone
= ff.input :biography
-# Optional
= ff.input :organisation
= ff.input :public_email
= ff.input :github
= ff.input :twitter
.panel-footer.text-right
= f.submit class: 'btn btn-primary'