How to create a csv file of saved search using script

Use the task module    //Create a task for saved search             let searchTask = task.create({                    taskType: task.TaskType.SEARCH                });                searchTask.savedSearchId = saved search internal id;searchTask.filePath = filePath//where the… Continue reading How to create a csv file of saved search using script

How to check condition in PDF template

In the PDF template, we can check the condition using <#if>. Here we are showing an image only if the sales order location is ‘Outlet Center’. <#if record.custbody_aha_sales_location=”Outlet Center”> <#if companyInformation.logoUrl?length != 0> Airport Home Appliance –Builder Division${record.location.address1}${record.location.city} ${record.location.state} ${record.location.zip}${record.custbody_aha_sales_location.phone} Sales Invoice #${record.tranid} ${record.trandate} The source code is metioned below. <#if record.custbody_aha_sales_location=”Outlet Center”> <img src=”src… Continue reading How to check condition in PDF template

How to create a task with dependent script using map/reduce script.

The scheduled or map/reduce script only used as a dependent script. Here we used the saved search to convert the search result as a csv file and stored in the file cabinet. // Specify a file for the search results                let asyncSearchResultItemFile = ‘file path need to give… Continue reading How to create a task with dependent script using map/reduce script.