SHARE
TWEET

Untitled

a guest Jul 22nd, 2019 61 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. placeOrder: function (data, event) {
  2.     var self = this;
  3.  
  4.     if (event) {
  5.         event.preventDefault();
  6.     }
  7.  
  8.     if (this.validate() && additionalValidators.validate()) {
  9.         this.isPlaceOrderActionAllowed(false);
  10.  
  11.         this.getPlaceOrderDeferredObject()
  12.             .fail(
  13.                 function () {
  14.                     self.isPlaceOrderActionAllowed(true);
  15.                 }
  16.             ).done(
  17.                 function () {
  18.                     self.afterPlaceOrder();
  19.  
  20.                     if (self.redirectAfterPlaceOrder) {
  21.                         redirectOnSuccessAction.execute();
  22.                     }
  23.                 }
  24.             );
  25.         return true;
  26.     }
  27.  
  28.     return false;
  29. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top