Promise
Deletes the Record from the module specified.
Kind: global function
Returns: Promise
- A promise that resolves to the recordId deleted.
See: getRecord
Since: v0.0.1
Param | Type | Description |
---|---|---|
options | ||
options.recordId | string |
The Id of the record to be deleted. |
options.moduleName | string |
optional Default value is the current Module of the context. The moduleName from which record needs to be deleted. |
Example
await deleteRecord({ recordId:'xyz' }); // Deletes the record from the current Module.
(or)
await deleteRecord({ recordId: "xyz", moduleName: 'Accounts' }); // Deletes the record from the module name passed.