diff --git a/functions/src/index.ts b/functions/src/index.ts index 30eaf25..032aa81 100644 --- a/functions/src/index.ts +++ b/functions/src/index.ts @@ -19,8 +19,8 @@ export const checkout = functions.https.onRequest((request, response) => { intent: 'sale', payer: {payment_method: 'paypal'}, redirect_urls: { - return_url: 'https://fhsons.zakscode.com/success', - cancel_url: 'https://fhsons.zakscode.com/cart' + return_url: 'https://fhsons.zakscode.com/cart/success', + cancel_url: 'https://fhsons.zakscode.com/cart/cancelled' }, transactions: [ { @@ -52,6 +52,8 @@ export const checkout = functions.https.onRequest((request, response) => { return acc + row.price * row.quantity; }, 0); + console.info(req); + // Send request to PayPal let create = new Promise((res, rej) => { paypal.payment.create(req, (error, payment) => { diff --git a/src/app/store/cart/cart.component.html b/src/app/store/cart/cart.component.html index 1f00a2d..fd9a30f 100644 --- a/src/app/store/cart/cart.component.html +++ b/src/app/store/cart/cart.component.html @@ -33,7 +33,7 @@ {{total() | currency}} - + \ No newline at end of file