<%= submit_tag "Save" %>
<%= submit_tag "Save and continue", :name => "commit_and_continue" %> or
<%= link_to "cancel", [:admin, @model] %>

<script type="text/javascript">
  $(function () {
    $('form').submit(function () {
      $(this).find('input[type=submit]').attr('disabled', 'disabled');
    });
  });
</script>
<%= submit_tag "Save" %>
<%= submit_tag "Save and continue", :name => "commit_and_continue" %> or
<%= link_to "cancel", [:admin, @model] %>

<script type="text/javascript">
  $(function () {
    $('form').submit(function () {
      var form = this;
      setTimeout(function () {
        $(form).find('input[type=submit]').attr('disabled', 'disabled');
      }, 1);
    });
  });
</script>
Fix issue with 'save' / 'save and continue' buttons
Fix issue with 'save' / 'save and continue' buttons
