Viraj Shinde
05/04/2021, 12:51 PMvar cart = container.getComponent("Cart");
cart.addPayment({
payment_method: {
internalid: 3
}
});
But is there no way we can remove payments?
I couldn't find any such method in the documentation: https://system.netsuite.com/help/helpcenter/en_US/APIs/SuiteCommerce/Extensibility/Frontend/Cart.html
Same for the events: I could find beforeAddPayment and afterAddPayment, but not beforeRemovePayment and afterRemovePayment
(We're trying to add/remove Gift Certificates using Extensibility API.)
Using SC 2020.2.7 and SCEM 2020.2.4Viraj Shinde
05/04/2021, 1:06 PMCart.addPayment({
type: "giftcertificate",
giftcertificate: {
code: "ABCDEF123"
}
});
Is there something wrong with the PaymentMethod object?Viraj Shinde
05/04/2021, 4:06 PMCard.addPayment({
payment_method: {
type: "giftcertificate",
giftcertificate: {
code: "ABCD123
}
}
});
Still cannot find a way to remove gift certificates via Extensibility API though. It will be great if someone can help.Viraj Shinde
05/04/2021, 4:13 PMViraj Shinde
05/04/2021, 5:05 PM