Skip to content

Commit

Permalink
Disable buttons on submit.
Browse files Browse the repository at this point in the history
  • Loading branch information
skyriverbend committed Nov 14, 2012
1 parent d19a7ca commit 7a4d700
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion app/views/groups/_add_members.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
= devise_error_messages!
= f.input :group_id, as: :hidden, label: false, input_html: { value: group.id }
= f.input :email, placeholder: "Email address", label: false
= f.submit "Invite", class: "btn btn-small", id: 'invite'
= f.submit "Invite", class: "btn btn-small", id: 'invite', :disable_with => "Invite"
= link_to "Cancel", "#", id: 'cancel-add-members'
%input#group_id{ type: "hidden", value: group.id }
- else
Expand Down
2 changes: 1 addition & 1 deletion app/views/groups/_subgroup_add_members.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,4 @@
= check_box_tag "user_#{member.id}", 1, is_member, disabled: is_member
= label_tag "user_#{member.id}", member.name
.modal-footer
= submit_tag "Invite members", class: "btn btn-small btn-info"
= submit_tag "Invite members", class: "btn btn-small btn-info", disable_with: "Invite members"
2 changes: 1 addition & 1 deletion app/views/users/invitations/edit.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@
= f.password_field :password
= f.label :password_confirmation, "Password confirmation"
= f.password_field :password_confirmation
= f.submit "Create my account", class: "btn btn-info"
= f.submit "Create my account", class: "btn btn-info", :disable_with => "Creating account"

0 comments on commit 7a4d700

Please sign in to comment.