Add Button in Email Template and Update the Record Field Value

Create an email template using the navigation Documents > Templates > Email Templates > New. Add a variable in the email template, which can be replaced using script. For example: Click JJ_YES to confirm. Click JJ_NO to reject. Here, JJ_YES and JJ_NO can be replaced using replace() in the script. Using script, this variable can… Continue reading Add Button in Email Template and Update the Record Field Value

Use Currency Symbol in Advanced PDF Template

The total amount can be divided into symbol and integer parts in order to display the currency symbol in the Advanced PDF Template while calculating the amount using arithmetic operations. Once a variable has been assigned the symbol, print the currency symbol using that variable. <#assign currencySymbol = record.total?substring(0, 1)> // This will store the… Continue reading Use Currency Symbol in Advanced PDF Template

Phone Number and Name Validation using Client Script

 It performs field validation for specific fields and displays alerts if the entered data does not meet the specified criteria. /**  * @NApiVersion 2.1  * @NScriptType ClientScript  */ define([‘N/record’, ‘N/log’, ‘N/format’], function (record, log, format) {   function validateField(context) {     let currentRecord = context.currentRecord;     let fieldId = context.fieldId;     if (fieldId === ‘custrecord_jj_phone_no_otp_5805’) {       const phone =… Continue reading Phone Number and Name Validation using Client Script

Mass Update Script is used to update the invoice’s due date.

The script is designed to find open invoices that are past due by 7 days and then update the due date for each of those invoices. /**  /**  * @NApiVersion 2.1  * @NScriptType MassUpdateScript  */  define([‘N/record’, ‘N/log’, ‘N/search’, ‘N/format’],   (record, log, search, format) => {           const each = (params) => {       var currentDate =… Continue reading Mass Update Script is used to update the invoice’s due date.

Delete Record using RESTlet Script

The doDelete function is executed when a DELETE request is sent to the RESTlet. It takes requestParams as a parameter, which contains parameters from the HTTP request URL. The doDelete function handles DELETE requests. It extracts the id parameter from the requestParams. It uses the record.load function to load a Vendor record based on the… Continue reading Delete Record using RESTlet Script

Map/Reduce Script to Create CSV File and Send Email

Script to generate a monthly sales report for sales representatives, including customer details and sales order information, and sends it via email. If there is no assigned sales representative, the report is sent to the administrator for further action. getInputData Function: The getInputData function creates a search to retrieve sales orders created within the last… Continue reading Map/Reduce Script to Create CSV File and Send Email

Assembly Work Orders

The status of assembly work orders can be, Planned – No components are committed regardless of commit option settings.​ Released – No transaction has posted, and no activities have been recorded. Components can be committed based on commit option settings.​ In Process – A transaction has been posted.​ Built – The quantity built is equal… Continue reading Assembly Work Orders

Advanced Billing Management

With advanced billing, business may make billing schedules that allow business to bill sales over a certain period of time or the duration of the contract. A billing schedule can be made and applied to the entire sales order, or users can choose a different billing schedule for each line item in an order. An… Continue reading Advanced Billing Management