【发布时间】:2019-10-25 14:34:12
【问题描述】:
I have a drop down that, when a particular option is selected a hidden field will be displayed and that field which have a new value.我能够显示该字段,但无法使用该值填充该字段。脚本如下:
function fieldChanged(context) {
var records = context.currentRecord;
if (context.fieldId == 'custbody_data') {
var note = context.currentRecord.getField({ fieldId: 'custbody_note' });
var type = records.getValue({
fieldId: 'custbody_data'
});
if (type == "2") {
note.isDisplay = true;
note.setValue = "test";
} else if (type == "1") {
note.isDisplay = false;
note.setValue = "";
}
}
}
return {
fieldChanged: fieldChanged
}
【问题讨论】: