diff options
Diffstat (limited to 'users/app/views/users/_form.html.haml')
-rw-r--r-- | users/app/views/users/_form.html.haml | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/users/app/views/users/_form.html.haml b/users/app/views/users/_form.html.haml new file mode 100644 index 0000000..39e26a6 --- /dev/null +++ b/users/app/views/users/_form.html.haml @@ -0,0 +1,15 @@ +- only = local_assigns[:only] +- html = {:class => 'form-horizontal user form ' + (@user.new_record? ? 'new' : 'edit')} += simple_form_for @user, :validate => true, :format => :json, :html => html do |f| + %legend + = t(only || :signup_message) + - if !only || only == :change_login + = f.input :login, :input_html => { :id => :srp_username } + - if !only || only == :change_password + = f.input :password, :required => true, :validate => true, :input_html => { :id => :srp_password } + = f.input :password_confirmation, :required => true, :input_html => { :id => :srp_password_confirmation } + .pull-right + = f.button :submit, :class => 'btn-primary' + - unless only + = link_to t(:cancel), root_url, :class => :btn + .clearfix |