Reputation: 473
We have a Sales Order and it has related Purchase Order and Invoice. All the records have the same PO UNIT COST field on them and the PO UNIT COST value should be the same.
I tried to develop a function to update the PO UNIT COST on Invoice once the value on PO is updated.
I know the related records can be found in the "Related Records" sublist on SO. Thus I must find out which SO is related to the PO, and then which Invoices are related to the SO as the following picture:
I know the id for the records are named tranid, and my idea is use code as follows to get the tranid:
var trainID= so_record.getSublistValue({
sublistId: related_record_tab,
fieldId: 'tranid',
line: 1
});
But I don't know what the id (related_record_tab) of "Related Record" tab is.
Is there any id for "Related Records" tab just as the 'item' is the id of "Items" tab? How to find it?
Upvotes: 1
Views: 2412
Reputation: 1
in your related_record_tab , instead write "links" and it'll work , all you have to do is right click on the related record subfields example "types" and go to inspect, in the inspect tab you will find the related ids present.
Upvotes: 0
Reputation: 46
Try 'links' as the tab ID.
If you're not familiar with it, appending '&xml=T' to the end of a URL in NetSuite can be helpful for finding out IDs for some of the more obscure references to objects in NS.
Upvotes: 3