Setting Up Custom Transaction Line and Transaction Item Option Fields

Set up custom transaction line fields to appear in your PDP, Cart, Checkout, and My Account. This requires setting up the custom fields in NetSuite. Commerce websites include a set of default templates (listed below) to render these fields, but you can override these as required.

Note:

Transaction line fields and transaction item options render in the same locations on your site. To set up these fields, follow the same set up and configuration procedures and customize the same template file.

To set up a Custom Transaction Line and Transaction Item Option:

  1. In NetSuite, set up the transaction line field or transaction item option. See Creating Custom Transaction Line Fields and Creating Custom Transaction Item Options for details.

    For a custom transaction line or transaction item option to render in your Commerce website, note the following:

    • Enter a label and ID for your custom item. If you do not specify an ID, NetSuite will create one for you. Use these when customizing templates to render the field.

    • To enable a custom transaction line field to render in the PDP, check Sale Item and Store Item (Applies To subtab).

    • To enable a custom transaction item option to render in the PDP, check Sale and Web Store (Applies To subtab).

    • SCA supports the Mandatory option in the Validation & Defaulting subtab. Some of these fields are validated in the frontend (client side). Others are validated in the backend.

    • SCA does not support all transaction item option types.

    • All the transaction line fields and item options are displayed automatically if the Show Only Items Listed in: ItemOptions and Custom Transaction Line fields property is unchecked. Enabling this property only displays fields with the ID specified in the item options and custom transaction line field’s Item options and custom transaction line fields property.

  2. In NetSuite, go to Commerce > Websites > Configuration.

  3. In the Shopping Catalog tab and Item Options subtab, check the Show Only Items Listed in: Item Options and Custom Transaction Line Fields property and set up your item options fields to display. See Item Options Templates Subtab for more information.

Supported Field Types

Commerce websites support transaction line fields and transaction item options of the following Type:

Note:

Some of these fields are validated on the frontend (client side). Others are validated on the backend (NetSuite). Invalid fields in the frontend result in error messages displayed at the field where the error occurred. Invalid fields in the backend result in error messages at the top of the page.

Type

Validation

Example HTML5 Elements Used to Render the Field

Check Box

Backend

checkbox

Currency

Frontend

text

Date

Backend

date, datepicker (Bootstrap)

Date/Time

Backend

text

Decimal Number

Frontend

number

Email Address

Frontend

email

Free Form Text

Frontend

text

Hyperlink

Frontend

url

Integer Number

Frontend

number

List/Record

Frontend

input, select

Password

Backend

password

Percent

Frontend

text

Phone Number

Frontend

tel

Text Area

Frontend

textarea

Time of Day

Backend

text

Related Topics

General Notices