English
md.tile.before
About 177 wordsLess than 1 minute
2025-12-15
This hook is triggered before the child-object tiled page expands. It can be used to customize the expanded child object.
- Specify the number of columns displayed on the page
- Specify the display size of image fields
- Hide the close button
- Hide certain fields
Parameters
| Parameter | Description | Type |
|---|---|---|
| Common parameters | See details | -- |
| objApiName | Child object apiName | String |
| recordType | Child object record type | String |
Return Value
| Parameter | Description | Type | Default |
|---|---|---|---|
| viewColumns | Default number of columns displayed on the expanded page | Number | adaptive |
| imageSize | Display size of image fields on the expanded page | Object | -- |
| hideColse | Hide the close button | Boolean | -- |
| hideFields | Hide certain fields | Array | -- |
Basic Example
Hide specific fields / specify displayed columns
export default class Plugin {
apply() {
return [{
event: 'md.tile.before',
functional: this.mdTileBefore.bind(this)
}]
}
// If this is a middleware plugin in a vcrm project, swap the interaction parameter positions
// mdTileBefore(plugin, context)
mdTileBefore(context, plugin) {
return Promise.resolve({
hideFields: ['name'],
viewColumns: 1 // display in a single column; can pass 1, 2, 3, 4
})
}
}