alien4u
01/14/2021, 7:09 PMSantiago
01/14/2021, 7:15 PMSantiago
01/14/2021, 7:16 PMalien4u
01/14/2021, 7:26 PMSantiago
01/14/2021, 7:30 PMvar shipaddressSearch = search.create({
type: recordtype,
filters: [['internalid', 'is', recordid]],
columns: [
search.createColumn({
name: "internalid",
join: "Address",
label: "Internal ID"
}),
search.createColumn({
name: "addressinternalid"
})
]
})
var shipipingAddressResults = shipaddressSearch.run().getRange({
start: 0,
end: 1000
})
debugger;
// var warehouseLocation = ""
shipipingAddressResults.forEach(function (shipaddress) {
console.log("EXTRENAL IDDDD", shipaddress.getValue("addressinternalid"));
//log.debug({ title: "EXTERNAL ID ADDRESS", details: });
if (shipaddress.getValue("addressinternalid") == warehouseLocation) {
warehouseLocation = shipaddress.getValue({ name: 'internalid', join: 'Address' });
}
})