Create a Custom Module for Your CCT

Your CCT module must include the following files at a minimum:

The following procedures use a fictitious CCT named SC.CCT.ImageViewer as an example. This CCT introduces a simple image viewer that gets data from either a custom record (as set up in SMT) or from certain data previously made available in the browser.

Note:

You can create a custom CCT module to retrieve, create, and update data stored in NetSuite records using services and models. To do this, you must implement these files as you would any custom module. See SCA Feature Modules for details.

To create a CCT Module:

  1. Create a custom module to contain your CCT files.

    As a best practice, use the following format when naming your CCT Module: SC.CCT.cctName@x.y.z, where cctName is the name of your CCT and x.y.z is the version number.

    For example:

    SC.CCT.ImageViewer@0.0.1

  2. In your new module, create the following subdirectories at a minimum:

    • JavaScript – contains the entry point JavaScript or TypeScript file and all views.

    • Templates – contains the HTML template that will render your CCT.

    Note:

    If your CCT introduces any new Sass, SuiteScript, or Configuration files, add subdirectories for these files as well.

Related Topics

Create Custom Content Types for SMT
Create an Entry Point File
Create a View File
Create a Template File
Set Up Your ns.package.json and distro.json Files

General Notices