Email Us

Our team will answer your enquiry shortly.

Your Name (required)

Company Name (required)

Your Email (required)

Your Phone Number (required)

Subject

Your Message

Please leave this field empty.

Converting Netsuite Scripts from Suitescript 1.0 to 2.0 - Cloud Coders
567
post-template-default,single,single-post,postid-567,single-format-image,ajax_fade,page_not_loaded,,side_menu_slide_with_content,width_470,columns-4,qode-theme-ver-10.1.2,wpb-js-composer js-comp-ver-5.1,vc_responsive
 

Converting Netsuite Scripts from Suitescript 1.0 to 2.0

Help for Converting Netsuite Scripts

Converting Netsuite Scripts from Suitescript 1.0 to 2.0

We have recently been busy converting netsuite scripts and have converted quite a few of our modules from SuiteScript 1.0 to SuiteScript 2.0. and continue to do so. If you haven’t had a play with suitescript 2.0, I definitely recommend getting into it as soon as possible.

Some of the advantages we have found so far are:

  1. Easier to use custom modules than attaching script library files to script records (or plugins for that matter).
  2. Easier to read code
  3. Easier for non-Netsuite programmers to pick up
  4. No more nlapi calls to wrap for testing purposes

So in this article I’ll concentrate on the above issues, that prompted us into converting netsuite scripts, so that you can understand our point of view on this process and the benefits of it. There are also a couple of projects that we haven’t started as yet, because they are massive, and in subsequent articles, we’ll look at why we haven’t started those as yet.

Modules make it easier and faster.

Probably the main advantage for us is moving our Netsuite hosted integration platform onto Suitescript 2.0. The challenge in SuiteScript 1.0 was always about how to enable a base implementation, and then extend that as different customers had different requirements. We tried all sorts of things including Netsuite Custom Plugins, and the solutions were always difficult to explain to anyone new, and, because everything was loaded at the beginning, of any process, always really heavy on the performance side. So suitescript to allowed use standard OO programming conventions, and create separate modules to be loaded as required. Just as important, it enforced a consistent file structure across the modules.

Easier to read, and easier for non-Netsuite programmers to pickup

So these two things go hand-in-hand. Because Suitescript 2 follows javascript standards, it’s much easier to follow for non-Netsuite experience programmers. All the object elements are explicitly defined, so it is clear to see what is being used in the code. Netsuite’s documentation is excellent in this area, and to help, Netsuite have included these excellent reference pages in the help guide to assist with trying to find things. In the Help Centre search for: SuiteScript 1.0 to SuiteScript 2.0 API Map

No more nlapi calls to wrap for testing

So I’ll explain a little more here about one of the things that we did here to assist our automated system testing, which reduced our development time, and also improved our testing. As the nlapi calls made it extremely difficult to do any system testing, we invested a lot of time in building a robust Data Abstraction Layer (DAL) that wrapped a lot of the Netsuite api’s that we used in Server Side development. So whilst we still use this for two of our major products, it’s future is limited because new functionality will only be released in SuiteScript 2, and also because some of the functionality has been addressed in SuiteScript, for example making all the indices of lines and search results consistent.

Summary

Suitescript 2.0 is in no doubt a huge leap ahead of SuiteScript 1.0. There are of course gotchas and things to look out for, but overall, we highly recommend moving what you’ve got over.

If you can see a need for the converting netsuite scripts in your business, we would love to chat to you. In fact, if you have a conversion requirement for NetSuite or any specific integration requirements for your business and NetSuite contact us today and find out how we can make your life simpler and help you work smarter.

No Comments

Post A Comment