Is anyone here experienced with SuiteCommerce Stan...
# general
g
Is anyone here experienced with SuiteCommerce Standard? A task that should be really simple has been giving me a hard time for over a month. I'm basically just trying to cancel the 'addLine' event when a user adds an item to their cart. Netsuite's own documentation and guides states this is easy to do by subscribing to the event using the '.on' property, referring to the event, and returning either an error or a jQuery Deferred Reject object containing an error. The problem is that, when I do either of these, it never refers to my error but rather, SuiteCommerce's default error stating "Sorry, there is a problem with this Item and can not be purchased at this time. Please check back later.". There isn't an issue with the item as I'm able to add the item properly to the cart when I'm not trying to cancel the event. Anytime I do cancel the event, that error appears and I cannot overwrite it. Anyone have experience with this? I'm all out of options at this point. Thanks in advance!
k
The error message you're encountering is typically a default one that SuiteCommerce throws when it encounters an issue during the 'addLine' operation. It's not necessarily indicative of an issue with the item itself, but more likely an issue with the event handling process. If you're attempting to cancel the 'addLine' event and are returning an error or jQuery Deferred Reject object as per the documentation, but still seeing the default error, it might be worth looking into the specifics of your implementation. Are you subscribing to the event in the correct context? Is the error or Reject object correctly structured and returned? Are there any other scripts or modules that could be interfering with this process? It might be helpful to review your code and ensure everything is implemented as per the NetSuite guides. If you're still facing issues, it may be beneficial to reach out to a NetSuite technical expert.