Skip to content

[Data Mapper] Display all the output type fields available in the source #460

Open
@madushajg

Description

@madushajg

Description:
Screenshot 2023-04-11 at 10 26 20

Currently the DM only shows the output fields that are specified in the type descriptor. However there can be some additional fields in the output types when,

  • the output record is an open record
  • the user mistakenly add some extra fields

In both of these cases, it is important to show the additional fields in the DM diagram as well so that it will sync with the source and users can take actions by only using the DM.

Sample source:

type Car record {
    SUV vehicle;
};

type SUV record {
    string model;
    int year;
};

type HighEndCar record {|
    Model model;
    int year;
|};

type Model record {
    string transmission;
    string engine;
};

function tnf(Car car) returns HighEndCar => {
    year: 0,
    model: {
        transmission: "",
        engine: ""
    },
    "additionalField1": 10,
    additionalField2: 10
};

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    📋 Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions