Hey folks, anyone had a problem with the resolveRe...
# suitescript
n
Hey folks, anyone had a problem with the resolveRecord part of the N/url module? I’m trying to get a record URL with the following code:
Copy code
const returnData = url.resolveRecord({
                    recordType: record.Type.CUSTOMER_PAYMENT,
                    id: 87900,
                    isEditMode: false
                });
But all I get in return is the general URL to the Create Customer payment form: https://system.netsuite.com/app/accounting/transactions/custpymt.nl?compid=********_SB3 If I use the internal ID to do a transaction search, I can find the customer payment without any problems so it does exist.. and the code above is in a Suitelet that is executed as Administrator so shouldn’t be a permission issue.. any ideas?
s
try making id a string instead?
n
@Sandii tried that too 😕
s
wait isnt it
recordId
n
@Sandii you’re absolutely right… sometimes I wonder how I don’t notice these things.. I also wonder why it doesn’t throw an error when getting a param it doesn’t use, anyways.. thanks a lot!