YASSER
03/02/2025, 11:03 PMCeligo AI
03/02/2025, 11:03 PMAI generated answer (using internal Slack threads):Based on the conversations, it seems like you want to create a field in the Credit Memo that shows the Invoice number from which the Credit Memo was created. In NetSuite, when you create a Credit Memo from an Invoice, the Invoice number is automatically linked to the Credit Memo in the
createdfrom
field. However, this field might not be visible on your form. You can make it visible by customizing your form and checking the 'Show' box for the createdfrom
field.
If the createdfrom
field is not showing the Invoice number even after making it visible, it might be due to some customizations or scripts running on your form that are affecting this field.
In the provided conversations, a user mentioned a similar issue where the createdfrom
field was not showing the Invoice number after running a script that transforms an Invoice into a Credit Memo. The issue was not resolved in the conversation, but it was suggested that the problem might be a bug in NetSuite.
If you're using SuiteScript to create the Credit Memo from an Invoice, make sure that you're not doing anything that could break the link to the Invoice, such as changing the customer or the form used for the Credit Memo.
Here's a sample code snippet from the conversation that transforms an Invoice into a Credit Memo:
javascript
generateCmRecord(cmData) {
var cmRecord = record.transform({
fromType: record.Type.INVOICE,
fromId: cmData.fromInvId,
toType: record.Type.CREDIT_MEMO,
isDynamic: true,
defaultValues: {
customform: <http://cmData.useForm.cm|cmData.useForm.cm>,
},
})
return cmRecord
}
In this code, cmData.fromInvId
is the ID of the Invoice that you're creating the Credit Memo from, and <http://cmData.useForm.cm|cmData.useForm.cm>
is the ID of the form that you're using for the Credit Memo.
******
Disclaimer:
This response was generated by an artificial intelligence assistant based on previous conversations from multiple Slack channels, and may contain inaccuracies or mistakes.
******Celigo AI
03/02/2025, 11:03 PMSlack thread 1: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.836142302
Slack thread 2: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.835881531
Slack thread 3: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.833284855
Celigo AI
03/02/2025, 11:03 PM