How to fetch data from MicroSite Records from the Item Records.

Fetching data from MicroSite Records from the Item Records. In website page we have to show the detailed description of the product in the Product detail page.
1. First we have to fetch those data from item records in suite script with the help of saved search.
2. Then with the help of suite script in extension we can transfer the data to java script file through service controller using get method.

For example: Sample Suite script

var loadMicroSiteRecords = nlapiSearchRecord("customrecord_tag_product_description", null,               
[                    
["custrecord_prod_desc_item","anyof", itemID]                
]);               
var microSiteRec = nlapiLoadRecord("customrecord_tag_product_description", customrecord_tag_product_descriptionSearch[0].id);                
var finalRecordLoad = microSiteRec.getFieldValue('custrecord_detailed_description');                           
 return finalRecordLoad;

In this we can get the item detailed description by passing the item internal id and Microsite Id for getting the value.

Leave a comment

Your email address will not be published. Required fields are marked *