erictgrubaugh
11/17/2016, 4:33 PMdefine(['N/search'], function (s) {
function beforeLoad(context) {
var newRecord = context.newRecord;
var parentFields = s.lookupFields({
"type": s.Type.ENTITY,
"id": newRecord.getValue({"fieldId": "parent"}),
"columns": ["isjob"]
});
// Not sure if this will be a Boolean or "T"/"F"
(parentFields.isjob === "T") ? doX() : doY();
}
function doX() { ... }
function doY() { ... }
});