Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

one_to_many mapping - repeat source value based on count of fieldPath… #2049

Closed
wants to merge 1 commit into from

Conversation

shanthi4647
Copy link
Collaborator

one_to_many mapping - repeat source value based on count of fieldPath and do the target transformation. eg : for below mapping, where simple source field is mapped to array field, today there is a limitation, source field value gets copied to only first element of target array transformed data
image

In the example, selected fieldPath = "/data<>"
If i send source file which has 'namespace' field value = 'test'
and count of 'data' field is 2, then 'repeat action' gives source transformed data as = ["test", "test"]
this source transformed data is further passed to target action transformation execution

For above mapping, source.json is
{
"namespace": "iiot.schneider.mct.andon",
"version": "1.0.0",
"data": [
{
"Shift": 3,
"ANDON Type": "Facility"
},
{
"Shift": 100,
"ANDON Type": "Quality-IQC"
}
]
}

and transformed data is below, where 'iiot.schneider.mct.andon' repeated for all target array elements
{
"Site-Array" : "[{"ExternalReference":"Facility","ExternalReferenceSource":"iiot.schneider.mct.andon"},{"ExternalReference":"Quality-IQC"}]",
"ATLAS_DEFAULT_TARGET_DOC" : "[{"ExternalReference":"Facility","ExternalReferenceSource":"iiot.schneider.mct.andon"},{"ExternalReference":"Quality-IQC"}]"
}

@netlify
Copy link

netlify bot commented May 11, 2020

Deploy preview for atlasmap canceled.

Built with commit d4b5f5c

https://app.netlify.com/sites/atlasmap/deploys/5eb97b88bb0ba500064ccc95

@igarashitm
Copy link
Member

We migrated to React version of UI and Angular version was removed.

@rkorytkowski
Copy link
Contributor

rkorytkowski commented Aug 10, 2020

TODO:

  1. Rewrite UI part to React
  2. Add tests
  3. Find a way to get rid of a dropdown for selecting a field in mapping details.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants