English
md.batchAdd.end
About 147 wordsLess than 1 minute
2025-12-15
This hook is triggered after selecting data during batch creation of child-object data and after UI events/calculation logic have finished executing. It allows extra business actions, including but not limited to data validation.
- Validate data
Parameters
| Parameter | Description | Type |
|---|---|---|
| Common parameters | See details | -- |
| objApiName | Child object apiName | String |
| recordType | Child object record type | String |
| lookupField | Field metadata of the lookup field used when creating the child object | Object |
| newDataIndexs | Row IDs of the newly added child-object data | Array |
| lookupDatas | Related object data selected to create child-object data | Array |
Basic Example
Basic Usage
export default class Plugin {
apply() {
return [{
event: 'md.batchAdd.end',
functional: this.mdBatchAddEnd.bind(this)
}]
}
// If this is a middleware plugin in a vcrm project, swap the interaction parameter positions
// mdBatchAddEnd(plugin, context)
mdBatchAddEnd(context, plugin) {
// todo what you want
}
}