Select Class


Methods of the Record class

Guides

Welcome to class reference

Class: Record
NameTypeComment
RecordClassThis class is to help the user interact with Records.

Note: Remember to add Roles to Groups
and add Groups to Users that will be a part of the workflow.

Method: update
NameTypeComment
updateMethodUpdate a Record from a Table
ReturnRequirements
The updated Record or an error message.none

Parameters
NameCommentType
tableApiNameThe Table api name.string
recordIdIdentifier for the record.string
dataA table with fields and values that needs an update.any



Examples

Example case:
Update record

Description:
Use this method to update any field of a record. Simply replace the values in 'data'

// Variables const tableApiName = "business_mate_task_list"; const recordId = "ba384680-859c-4bab-917b-d78d7ab3d7dc"; const data = { "f_title": "task01", "f_description": "Prepare the test environment", "f_priority": "2", "f_assigned_to": [ { "id": "332ed86a-4375-41fb-979b-a42d1971cdae", } ], "f_deadline": "2021-12-19T22:00:00.000Z" }; // Run the method and store the results in a variable const result = await Record.update(tableApiName, recordId, data); // Test print the result console.log(result);