PatchChange

Reports a completed change back to Lucid


Constructors

new PatchChange()

new PatchChange(
   patchId, 
   syncId, 
   collections, 
   creationPermission?): PatchChange

Parameters

ParameterType
patchIdstring
syncIdstring
collectionsPatchChangeCollection[]
creationPermission?"DataSource" | "Collection" | "Item" | "None"

Returns

PatchChange


Properties

collections

collections: PatchChangeCollection[];

creationPermission?

optional creationPermission: "DataSource" | "Collection" | "Item" | "None";

patchId

patchId: string;

syncId

syncId: string;

Methods

getErrors()

getErrors(): Record<string, Record<string, DetailedPatchError>>

Returns

Record<string, Record<string, DetailedPatchError>>


setError()

setError(
   primaryKey, 
   fieldName, 
   error, 
   type): void

Parameters

ParameterTypeDefault value
primaryKeystringundefined
fieldNamestringundefined
errorstringundefined
typePatchErrorTypePatchErrorType.Default

Returns

void

Deprecated

  • use setFieldErrorOrDefaultToTooltip() instead.

setFieldErrorOrDefaultToTooltip()

setFieldErrorOrDefaultToTooltip(
   primaryKey, 
   error, 
   fieldName?, 
   type?): void

Set the error message for a specific field on a specific item. If fieldName is provided, will have field-specific
error resolution. Otherwise, will default to PatchErrorTooltipField.

Parameters

ParameterTypeDefault value
primaryKeystringundefined
errorstringundefined
fieldName?stringundefined
type?PatchErrorTypePatchErrorType.Default

Returns

void


setTooltipError()

setTooltipError(
   primaryKey, 
   error, 
   fieldName?, 
   type?): void

Parameters

ParameterTypeDefault value
primaryKeystringundefined
errorstringundefined
fieldName?stringundefined
type?PatchErrorTypePatchErrorType.Default

Returns

void

Deprecated

  • use setFieldErrorOrDefaultToTooltip() instead.