llega a pasarelas de pago
This commit is contained in:
parent
8b6d913cd7
commit
56e3baa656
|
@ -26,7 +26,7 @@ class PaymentServices {
|
|||
}
|
||||
|
||||
let priceIntial = 0
|
||||
let price = productsFilter.reduce((accumulator, curValue) => accumulator + Number(curValue.price), priceIntial)
|
||||
let price = productsFilter[0][0].reduce((accumulator, curValue) => accumulator + Number(curValue.price), priceIntial)
|
||||
|
||||
let productsIds = ''
|
||||
for (let i = 0; i < products.length; i++) {
|
||||
|
@ -45,7 +45,9 @@ class PaymentServices {
|
|||
})
|
||||
const order = await db.orderData_put(jsonOrderData);
|
||||
//const orderFk = order[0][0].catalogueFk;
|
||||
const orderFk = jsonOrderData.customer.customerData.products[0].id;
|
||||
//const orderFk = jsonOrderData.customer.customerData.products[0].id;
|
||||
const orderFk = productsFilter[0][0][0].id;
|
||||
console.log(`${orderFk} ${price}` )
|
||||
|
||||
if (type === "paypal") {
|
||||
const data = await payPalProviders.New(orderFk, price)
|
||||
|
|
Loading…
Reference in New Issue