LearnNewsExamplesServices
Frontmatter
id8403
titlePass record instance to Model field convert method
stateClosed
labels
enhancementaicore
assigneestobiu
createdAtJan 8, 2026, 12:47 AM
updatedAtJan 8, 2026, 1:31 AM
githubUrlhttps://github.com/neomjs/neo/issues/8403
authortobiu
commentsCount1
parentIssue8362
subIssues[]
subIssuesCompleted0
subIssuesTotal0
contentTrust
projected
quarantined0
signals[]
blockedBy[]
blocking[]
closedAtJan 8, 2026, 1:06 AM

Pass record instance to Model field convert method

tobiu
tobiu commented on Jan 8, 2026, 12:47 AM

Update src/data/RecordFactory.mjs method parseRecordValue to pass the record instance as the second argument to field.convert().

Current: value = field.convert(value) New: value = field.convert(value, record)

This allows convert functions to access sibling fields for more complex transformations, similar to calculate.

tobiu
tobiu Jan 8, 2026, 1:05 AM

Input from Gemini 3 Pro:

✦ Implemented in c64cc8ebb. Updated src/data/RecordFactory.mjs to pass record as the second argument to field.convert().