1.1 https://www.eclipse.org/downloads/packages/release/mars/2/eclipse-ide-java-ee-developers.
1.2 Updating Eclipse for Use with SuiteCloud IDE
1.3 Enable NS Features, SDF,
Setup > Company > Enable Features > SuiteCloud > SUITECLOUD DEVELOPMENT FRAMEWORK
2. Create SuiteCloud IDE, Project
File > New > SuiteCloud Project,
Account Customization
Project Name
3. NETSUITE UI, Assign Current Employee Record with “SDF Developer – 2FA Off” role
Create an custom role, make sure the 2FA is off(mandatory uncheck and ‘Not required’) in: Setup > Users/Roles > Two-Factor Authentication Roles
4. Configure SuiteCloud IDE to connect with NS (One-Time Setup)
NetSuite
Manage Account
Add Account(s)
Setup > Company > Company Information
Issue Token (Token has been issued)
5. Eclipse, Right click, NetSuite > Change Project Setting.
If you find your JAVA JDK version is not yet 11, you can download it from: https://www.oracle.com/java/technologies/javase-jdk11-downloads.html
Node.js — CLI for Node.js requires Node.js version 12.14.0 LTS or greater.
If you find your Node version is not yet 12.14.0, you can install it by Terminal: npm install -g @oracle/suitecloud-cli.
Notes:
This package has installed: • Node.js v12.14.0 to /usr/local/bin/node • npm v6.13.4 to /usr/local/bin/npm Make sure that /usr/local/bin is in your $PATH.
How to run SDF CLI for Node.js
MacOS tools
Terminal (Mac build-in)
iTerm2
CLI for Node.js Commands
suitecloud
Command
Description
account:ci
Set up an account to use with the SuiteCloud CLI for Node.js.
Generate a local server of your SuiteCommerce extensions and themes.
Sample
suitecloud account:setup
Application SuiteCloud IDE & CLI would like to access your account XXX (DEV) as Administrator carl.zeng@.com
The authentication process will continue in your SuiteCloud SDK application. Close this window and go to your application to check the progress of the process.
suitecloud object:import -i
The following objects have been imported:
– customrecordtype:
– usereventscript:
– Referenced SuiteScript files:
suitecloud project:adddependencies
Added dependencies to profile
suitecloud account:setup
Setup login, 2FA, Token, for target NetSuite Account
suitecloudproject:deploy
Deploy imported elements to target NetSuite Account
Practice
—–DOWNLOAD—–
(mkdir SDF_Top)
cd SDF_Top
suitecloud project:create -i
– Created new project(SDF_Test1), it will create new folder under SDF_Top with project name: SDF_Test1.
cd SDF_Test1
suitecloud account:setup
Now this folder is the main project folder
suitecloud object:import -i
? Do you want to import all object types? Yes
? Do you want to enter a script ID to filter your list? Yes
An error occurred during file validation.
Details: Resource files can only be uploaded into the /SuiteScripts/,
/Templates/E-mail Templates/,
/Templates/Marketing Templates/,
/Web Site Hosting Files/ folder.
File: ~/FileCabinet/.DS_Store
For Mac, you might need to: rm ~/FileCabinet/.DS_Store and rm ~/FileCabinet/Templates/.DS_Store
Since suitecloud project:deploy is trying to deploy those hidden files and trigger error: An error occurred during file validation. Details: Resource files can only be uploaded into the /SuiteScripts/, /Templates/E-mail Templates/, /Templates/Marketing Templates/, /Web Site Hosting Files/ folder.
2. Error Message:
An error occurred during account settings validation.
Details: The manifest contains a dependency on /SuiteScripts/Project_Name/ScriptFileName.js file, but it is not in the account.
When we saw this, it means we need to deploy the script file first. We can upload them in filecabinet OR deploy like this:
1. Deploy Files
1.1 Comment out Dependencies files in manifest.xml. I.e. <!-/SuiteScripts/Project_Name/ScriptFileName.js –>
1.2 Comment out whole section in deploy.xml. I.e. <!- ../Objects/* –>
1.3 suitecloud project:deploy
3. Error Message:
An error occurred during deploy file validation.
Details: The deploy file is invalid at line 2, column(s) 20 – cvc-complex-type.2.4.a: Invalid content was found starting with element ‘configuration’. One of ‘{configurations, objects, files, translationimports}’ is expected..
File: ~/deploy.xml
We must comment out no need deployment section/context by <!- –>. I.e.
4. Error Message: (When we deploy Script Record Object, we might facing error)
Validation failed.
An error occurred during custom object validation. (customscript_scriptinternalid)
Details: The file reference /SuiteScripts/Project_Name/ScriptFileName.js is missing in the project and also not included in the dependencies list.
File: ~/Objects/customscript_ScriptFileName.xml
We need to add(or uncomment) the dependencies in manifest.xml for script record object deployment; so usually we deploy by below sequences:
1. Deploy Files(upload the files)
1.1 Comment out Dependencies files in manifest.xml. I.e. <!-/SuiteScripts/Project_Name/ABC_UE_SalesOrder.js –>
1.2 Comment out whole section in deploy.xml. I.e. <!- ../Objects/* –>
1.3 suitecloud project:deploy
2. Deploy Script Records
2.1 Update manifest.xml to enable the dependency for all files section.
2.2 Update deploy.xml to enable the objects section and comment out the section.
2.3 suitecloud project:deploy
更新到2025.2
#必需要用管理员模式
sudo npm i g --acceptSuiteCloudSDKLicense @oracle/suitecloud-cli
#更新好后的版本
suitecloud --version
3.1.0
suitecloud
创建项目
suitecloud project:create -i
设置登陆和授权 suitecloud account:setup
suitecloud account:setup
✔ Enter an authentication ID: ****_SB1
/ Continue the authentication process in the prompted browser.
The account has been authenticated for the following company and role: **** [Administrator]. This project will use the authentication ID "****_SB1" as default. If you want to change your default credentials, run "suitecloud account:setup" again.
The account has been successfully set up.
SuiteCloud IDE plug-in for WebStorm is an integrated development environment for NetSuite platform development. It provides a user interface for SuiteCloud Development Framework (SDF), which is a development framework and deployment mechanism.
Since the latest SuiteCloud Plugin http://system.netsuite.com/download/suitecloud-sdk/ideplugin/webstorm/24.1/com.netsuite.ide.webstorm.app-2024.1.0.zip is not compatible.
从官方网站下载最新版
插件 com.netsuite.ide.webstorm.app-2024.1.0.zip
2024年5月中旬 Notes
下载最新的IntelliJ IDEA 2024.1.1
Buy the tool (or…. 下载 IDEA-jetbra.zip 存放在特定目录后, 替换原先的jetbra目录其中含ja-netfilter.jar,运行uninstall.sh,然后 sh install.sh)
重启启动Mac
填写注册码
发现重启MAC后,之前的PJ会失效。怎么办?
打开Terminal cd /Users/carlzeng/jetbra/scripts
sudo sh install.sh
显示成功的命令行信息:done. the “kill Dock” command can fix the crash issue.
The latest version of SuiteCloud IDE plugin from NetSuite is incompatible with WebStorm 2021 or Intellij IDEA; the key to resolve this is: using the old version’s plugin. copy the plugin file(com.netsuite.ide.webstorm) to editor’s plugins folder. Steps:
unzip file com.netsuite.ide.webstorm.app-2020.2.0.zip, got a file call: com.netsuite.ide.webstorm
Copy this com.netsuite.ide.webstorm to plugins folder on Mac: /Users/{username}/Library/Application Support/JetBrains/WebStorm2020.1/plugins
There are all other versions of WebStorm under JetBrains folder. I.e. IntelliJIdea2020.1, WebStorm2020.1 etc…
Make sure copy the plugin file com.netsuite.ide.webstorm to the plugins folder, restart your IDE, the NetSuite menu and feature is available.
Please note: these are only for research, don’t use for other purpose.
1. Download the old version 2020.1 in https://www.jetbrains.com/idea/download
2. Purchase the license or Download https://www.macfz.com/a/Jetbrainscrack.html or https://www.lanzoux.com/iGI7kfzyy6j
1. Registry a API key throw https://ocr.space/OCRAPI
There are limitations for Free Plan
2. Save the email attachment(PDF file) to NetSuite FileCabinet, set it to available without login, get the full url address, encode it.
var importFile = attachments[indexAtt];importFile.setIsOnline(true);
var intFileId = nlapiSubmitFile(importFile);
var strInvFileUrl = “https://” + nlapiGetContext().getCompany() + “.app.netsuite.com”+ objInvoiceFileRec.getURL();
strInvFileUrl = encodeURIComponent(strInvFileUrl);
3. Send Request to https://api.ocr.space/parse/imageurl?apikey=abcAPIKEYabc&filetype=PDF&isTable=true&url=
var response = nlapiRequestURL(strReqUrl, null, a);
There are varience of parameters for this API, in my case, it’s invoice formated as table, that’s why I send isTable=true to identify it; then it will help me to locate the expected cell and values.
4. Got and parsed the Response, we will get the Text messages on the PDF or Images.
var arrParsedLines = (objOcrRes[‘ParsedResults’] && objOcrRes[‘ParsedResults’][0]) ? objOcrRes[‘ParsedResults’][0][‘TextOverlay’][‘Lines’]: null;
var objVndBillData = parseDataFromInvPdf(arrParsedLines);
NetSuite’s javascript engine is Rhino(I.e. Rhino 1.7), we can not run node-based code on NetSuite, however,
write your code as, say, an npm module, and run npm scripts from the command line. I have done this in the past for unit testing, doc generation, eslint, etc. In order to actually run code in NetSuite, though, it must be in a plain .js file that NetSuite can interpret and load as a Library on your Script record.