English
form.render.after
About 156 wordsLess than 1 minute
2025-11-24
This hook is triggered after the form is rendered in the lifecycle. It allows extra actions after rendering, including but not limited to the following capabilities:
- Modify form state: field read-only, required, field data, etc.
- Initialize other business data that the current plugin depends on, where the business data depends on form field data
Parameters
| Parameter | Description | Type |
|---|---|---|
| Common parameters | See details | -- |
| objApiName | Main object apiName | String |
| recordType | Main object record type | String |
Return Value
| Parameter | Description | Type | Default |
|---|---|---|---|
| hideNoDatasDetails | Hide child-object tables that have no data (example) | Boolean | false |
Basic Example
Hide child-object tables without data
export default class Plugin {
apply() {
return [{
event: 'form.render.after',
functional: this.formRenderAfter.bind(this)
}]
}
// If this is a middleware plugin in a vcrm project, swap the interaction parameter positions
// formRenderAfter(plugin, context)
formRenderAfter(context, plugin) {
return {
hideNoDatasDetails: true
}
}
}