English
Location Field
About 177 wordsLess than 1 minute
2025-09-22
Location fields are triggered in the field.edit.before stage, before the address-picker control is opened.
Parameters
| Parameter | Description | Type |
|---|---|---|
| fieldName | api_name of the field that triggered the event | String |
| objApiName | api_name of the object that triggered the event | String |
| dataIndex | dataIndex of the record that triggered the event, used for detail-object data | String |
| selectParams | Parameters that will be used to open the address-picker control. These can be modified in the hook | Object |
Key properties of selectParams
| Parameter | Description | Type |
|---|---|---|
| latitude | Latitude | String |
| longitude | Longitude | String |
| radius | Radius of the allowed area | Number |
| editable | Whether the center point can be moved | Boolean |
Return Value
| Parameter | Description | Type |
|---|---|---|
| consumed | true means subsequent logic will not continue | Boolean |
| selectParams | Parameters that will be used to open the address-picker control | Object |
Code Example
Modify the parameters used to open the address-picker control:
{
event: "field.edit.before",
functional: function (pluginExecResult, options) {
let {selectParams}=options;
selectParams.arg1="1";
selectParams.arg2="2";
return {selectParams}
}
}Notes
- Calling
dataUpdaterto update data in this event is not suitable.
