In the define part, we should specify the path of the NetSuite library you are going to access.
define([ ‘../Common Library/JJ Transaction Library.js’],
@param transLib
(transLib) => {
The above part is mandatory to initialize the library we are going to access.
Using the custom module, you can access function inside the library at any part of your code.
let salesOrder = transLib.performSOSearch();
let purchaseOrder = transLib.performPOSearch();
//Assume that this is the library we are going to access.
JJ Transaction sync Library.js
The library contains multiple function
function performSOSearch(){ };
function performPOSearch(){};