English
add
About 150 wordsLess than 1 minute
2025-09-22
Batch add child object data.
Parameters
| Parameter | Description | Type |
|---|---|---|
| object_datas | One or more standard child object data records (object_data) | Object|Array |
Required Properties of object_data
If the following properties are missing, the add operation will fail.
| Property | Description | Type |
|---|---|---|
| object_describe_api_name | Object apiName | String |
| record_type | Record type | String |
Return Value
object_datas: the successfully added data. If the original data does not contain dataIndex, the returned data will include a supplemented dataIndex.
Code Example
{
event: "form.render.end",
functional: function (pluginExecResult, options) {
console.log("custom plugin: form.render.end exec");
let {dataUpdater}=options;
// Add one row of data
let datas1 = dataUpdater.add({
object_describe_api_name: "SalesOrderProductObj",
record_type:"default__c",
name:"1"
})
// Batch add multiple rows of data
let datas2 = dataUpdater.add([{
object_describe_api_name: "SalesOrderProductObj",
record_type:"default__c",
name:"2"
},{
object_describe_api_name: "SalesOrderProductObj",
record_type:"default__c",
name:"3"
}])
}
},Notes
- This method only contains logic for adding child object data. It does not trigger calculations or UI events.
