A "record" is 1 (one) row of data in the import / sheet.
record.get(field: string)
record.get("foo")
where "foo" is the name of the internal key in your template.
Access the value of field.
record.set(field: string, value: string)
record.set("foo", "new value")
where "foo" is the name of the internal key in your template you want to update.
Update the value of field in the row
record.addInfo(fields: string | string[], message: string)
record.addInfo("foo", "This field is not required, but is highly recommended")
Present the field value with a blue underline, and display a message in an "Info" popup when you hover over the field. (functionally the same as addComment
)
record.addComment(fields: string | string[], message: string)
record.addComment("foo", "This field is not required, but is highly recommended")
Present the field value with a blue underline in the field, and display a message in an "Info" popup when you hover over the field. (functionally the same as addInfo
)
record.addError(fields: string | string[], message: string)
record.addError("foo", "This field is required")
Present the field with red text in a red highlighted box, and display a message in an "Error" popup when you hover over the field.
record.addWarning(fields: string | string[], message: string)
record.addWarning("foo", "This field is not required, but is highly recommended")
Present the field with orange text in a yellow highlighted box, and display a message in an "Warning" popup when you hover over the field.
logger.info(value)
logger.info("hello world")
Output a value in the browser console (helpful for debugging)