Skip to main content

mogli@0.5.8

This adaptor exports the following namespaced functions:

sourceHelpers.lookup(relationshipName, externalID, path)
sourceHelpers.relationship(relationshipName, externalID, dataSource)

This adaptor exports the following from common:

alterState()
arrayToString()
beta
combine()
dataPath()
dataValue()
each()
field()
fields()
fn()
fnIf()
index()
join()
lastReferenceValue()
map()
merge()
referencePath()
source()
sourceValue()
toArray()

sourceHelpers

These functions belong to the sourceHelpers namespace.

sourceHelpers.lookup

lookup(relationshipName, externalID, path) ⇒ object

Adds a lookup or 'dome insert' to a record.

ParamTypeDescription
relationshipNamestring__r relationship field on the record.
externalIDstringSalesforce ExternalID field.
pathstringJSONPath to data source.

Example: Example

lookup("relationship_name__r", "externalID on related object", "$.path")

sourceHelpers.relationship

relationship(relationshipName, externalID, dataSource) ⇒ object

Adds a lookup or 'dome insert' to a record.

ParamTypeDescription
relationshipNamestring__r relationship field on the record.
externalIDstringSalesforce ExternalID field.
dataSourcestringresolvable source.

Example: Data Sourced Value

relationship("relationship_name__r", "externalID on related object", dataSource("path"))

Example: Fixed Value

relationship("relationship_name__r", "externalID on related object", "hello world")