JacksonP
11/06/2020, 6:58 PMSandii
11/06/2020, 7:01 PMTodd Grimm
11/06/2020, 7:01 PMJacksonP
11/06/2020, 7:02 PMTodd Grimm
11/06/2020, 7:03 PMericbirdsall
11/06/2020, 7:05 PMTodd Grimm
11/06/2020, 7:16 PMvar OLDVALS = {
entity: '',
trandate: '',
status: '',
location: ''
};
/**
* @param {ClientScriptContext.pageInit} context
*/
function pageInit(context) {
var rec = context.currentRecord;
Object.keys(OLDVALS).forEach(function (fieldId) {
OLDVALS[fieldId] = rec.getValue(fieldId);
});
}
/**
* @param {ClientScriptContext.fieldChanged} context
*/
function fieldChanged(context) {
var fieldId = context.fieldId;
var rec = context.currentRecord;
if (Object.keys(OLDVALS).indexOf(fieldId) > -1 && rec.getValue(fieldId) !== OLDVALS[fieldId]) {
// Do stuff
}
}
Todd Grimm
11/06/2020, 7:17 PMJacksonP
11/06/2020, 7:45 PM