<div class="row">
  <div class="col-xs-12">
    <div class="form-group">
      <%= render partial: "status_buttons", locals: { order: order } %>

      <% if order.pending? || order.approved? || order.shipped? %>
        <button class="btn btn-primary">Save</button>
      <% end %>

      <%= link_to "Cancel", orders_path, type: "button", class: "btn btn-default" %>

      <% if current_user.can_cancel_order? order.organization %>
        <button type="submit" name="order[status]" value="cancel" class="btn btn-danger pull-right"
          data="<%= confirm(title: "Cancel this order?") %>">
          <i class="glyphicon glyphicon-remove"></i>
          Cancel Order
        </button>
      <% end %>
    </div>
  </div>
</div>

<div class="row">
  <div class="col-xs-12">
    <div class="form-group">
      <%= render partial: "status_buttons", locals: { order: order } %>

      <% if order.pending? || order.approved? || order.shipped? %>
        <button class="btn btn-primary">Save</button>
      <% end %>

      <%= link_to "Cancel", orders_path, type: "button", class: "btn btn-default" %>

      <% if !order.canceled? && current_user.can_cancel_order?(order.organization) %>
        <%= button_tag name: "order[status]", value: "cancel", type: :submit,
            class: 'btn btn-danger pull-right', data: confirm(title: "Canceling Order") do %>
          Cancel Order
          <i class="glyphicon glyphicon-remove"></i>
        <% end %>
      <% end %>
    </div>
  </div>
</div>

Fix cancel button confirmation logic
Fix cancel button confirmation logic
