I am using `resolveTaskLink` to create a sales ord...
# suitescript
p
I am using
resolveTaskLink
to create a sales order via a button and am noticing that I am not able to use custom fields in the params section. Is there maybe something I am doing wrong or a way to be able to fill in those custom fields.
Copy code
/**
 * @NApiVersion 2.1
 * @NScriptType ClientScript
 * @NModuleScope SameAccount
 */
 
    define(['N/currentRecord','N/url'], (currentRecord, url) => {


     function additionalSalesOrder(clientId, subId, showId){
        var clientName = clientId;
        var subName = subId;
        var showName = showId;
        var standName = "Test Stand";
        console.log("Client Id is " + clientName);
        console.log("Subsidiary Id is " + subName);
            var redirectUrl = url.resolveTaskLink({
                id: 'EDIT_TRAN_SALESORD',
                isEditMode: true,
                    params: {
                      'entity': clientId,
                      'subsidiary': subId,
                      'custbody_standname': standName
                    }
              
              });
              
              window.open(redirectUrl);
            }
            function pageInit(context) {}
        return {
            additionalSalesOrder: additionalSalesOrder,
            pageInit: pageInit
        };

    });
b
redirect.toRecordTransform documents how to set fields in the method description