MobileCRM.UI.EntityForm.enableCommand - Resconet/JSBridge GitHub Wiki
Enables or disables the form command.
Arguments
Argument | Type | Description |
---|---|---|
command | String | The name of the command. |
enable | Boolean | Determines whether to enable or disable the command. |
iParam | Number | [v9.1] Optional parameter defining the additional command parameter (like status code value for "ChangeStatus" command). |
This example demonstrates how to enable/disable a custom command by name appended to the entity form via Woodford.
MobileCRM.UI.EntityForm.enableCommand("custom_MyCommand", false);
This example demonstrates how to enable/disable specific status command - in our case it disables the "Disqualified - Cannot Contact" status on Lead form.
MobileCRM.UI.EntityForm.enableCommand("ChangeStatus", false, 5); // The value "5" is the status code for "Disqualified - Cannot Contact" status on Lead entity